Batch Add permissions issue Batch Add permissions issue
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Batch Add permissions issue

Started by amerkfan, June 17, 2014, 08:08:11 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

amerkfan

I have a clean install of CPG15x v 1.5.28. I had been running an older version with no issues. I deleted that version and database to start over (it was just a test site so no need to migrate). Now I am serious about getting the gallery up and running. I am using a self hosted server (Ubuntu 12.04) and have the flexibility to make what changes I need. That said, I am trying to add files to an album, and get the following:

/include/functions.inc.php
Notice line 3600: Undefined index: url_prefix
Notice line 3600: Undefined index:
Notice line 3606: Undefined index: url_prefix
Notice line 3606: Undefined index:

/include/logger.inc.php
Warning line 62: fopen(logs/global.log.php): failed to open stream: Permission denied
Warning line 63: fwrite() expects parameter 1 to be resource, boolean given
Warning line 64: fwrite() expects parameter 1 to be resource, boolean given
Warning line 65: fclose() expects parameter 1 to be resource, boolean given

I should add that the files are on another (local) Ubuntu server and mounted to the albums folder using fstab. The folders and files are displayed correctly and the permissions are all set to RW.

I tried copying a file to a folder I created in albums, with the same result (not added) except, no error logs were created.

Attached is the debug info for the batch add and PHP version info

Thanks for your help.

Αndré

Unfortunately I don't know at which point the batch-add fails. Please describe the process more detailed and attach screenshots of the issue.


Additionally, you should check the permissions of
Quote from: amerkfan on June 17, 2014, 08:08:11 PM
fopen(logs/global.log.php): failed to open stream: Permission denied

amerkfan

The process I follow is:

Open CPG
Select Batch add files
Select Folder (see 01_Select_Folder.png)
Select 'OK' (See 02_Select_OK.png)
Select  Insert Selected File (See 03_Selectect_Insert_Selected_File.png)
The process runs and then displays as shown in 04_Result_of_Insert_Attempt.png and the error messages as described before appear.

Αndré

Please hover over the radar icon to get some more information. The debug output isn't relevant at this point.

amerkfan

Okay, hovering over the radar icon it says Error executing ImageMagick - Return value 1

I did another clean install, this time with no extra plugins. As before, since CPG couldn't read/find the path (/usr/bin/) to ImageMagick during the install, I created a folder under cpg15x, called bin, and copied convert to the folder.

Αndré

Alternatively use GD2 as resize method (you can choose that in the installer and also later in the config - admin.php).

phill104

Out of interest, how are you installing Coppermine? Out of the box it selects GD2 unless you are using your hosts installer?
It is a mistake to think you can solve any major problems just with potatoes.

amerkfan

I downloaded the zip file off the coppermine web site and uploaded it to my server. When I got to the step for selecting the editor, imagemagick was the default choice with /usr/bin as the location for convert. when I tried to test that, it told me that the path wasn't valid. That's when I figured that the web page didn't have access outside of /var/www/myweb.com/web/cpg15x. That's why I copied convert into the cpg15x folder

amerkfan

update:

the radar screen now shows:
Error executing ImageMagick - Return value 1 CMD line: /var/www/clients/client1/web1/web/cpg15x/bin/convert -quality 80 -geometry 128x96 'albums/california_june_2006/S5000063.jpg' 'albums/thumb_california_june_2006.jpg'. The convert program said:convert unable to open image 'albums/california_june_2006/thumb_S5000063.jpg': @error/blob.c/OpenBlob/2587.

Αndré

Please try GD2 instead of IM as resize method.

amerkfan

okay, will do. I prefer to use im but will change

Αndré

Feel free to search for the error message
Quoteerror/blob.c/OpenBlob/2587

I assume it's a file system permission issue. The test with GD2 will probably help us to identify the cause.

amerkfan

Another fresh install with GD2 as the editor. now the error reads "Unable to create thumbnail or reduced size image"

When I try upload the error is "Impossible to move"

phill104

Again, that points to file permissions on your server. Speak to your host with the exact time of the error message and they can look in their logs. Hopefully they will be able to see exactly what needs changing.
It is a mistake to think you can solve any major problems just with potatoes.

amerkfan

I'm self hosted, what logs should I be looking at?

phill104

Apache Error logs, I've no idea which as I do not know your setup.
It is a mistake to think you can solve any major problems just with potatoes.

Αndré

This thread is marked as solved. If it's solved, please post the solution. If not, please double check if the albums directory and all sub-directories are set to 777.

amerkfan

Final update:

Thinking about the permissions issue, the solution I came up with was to move/mount the RAID drives to the server that is hosting cpg15x, then I mounted the folder I needed to the albums folder in cpg15x using /path/to/RAID/mount/folder    /var/www/web_page_location/web/cpg15x/albums    none    bind

This allows the correct permissions to access the files I need.

Thanks for your help and mental prodding to get me to this solution.