Gallery URL (optional but very useful): testgallery.webhop.net
Gallery version: gallery-1.5.9-svn-b27.tar.bz2
Apache version: N/A -> IIS 6
PHP version (don't just say PHP 4, please): PHP Version 5.2.8
Graphics Toolkit: ImageMagick-6.4.8-Q16
Operating system: Windows Server 2003
Web browser/version (if applicable): IE 6/7
=============
Sorry to post another "no thumbnails" - but this one is most perplexing. I know that IIS is not supported, so I'm hoping another IIS user will have encountered this issue and offer some ideas.
My galleries (yes more than one) have been working fine for many months until recently. Sadly something has changed on my server (Win 2003) and my image processing no longer works.
Specifically during upload of an image, the call to the image processor (can be either ImageMagick or Netpbm - both exhibit the same problem) does not appear to work. Yet the exec command is working since jhead works. Here is a debug=3 output:
----------
save_photos.php::358 -> Now we start processing the given Files. (If they were given)
Processing 1 element.
albumItem.php::506 -> Entering function: 'processNewImage'
albumItem.php::508 -> Processing file: C:\WINDOWS\Temp\PHPUploadFolder\phpC02.tmp
albumItem.php::628 -> Start processing single file (image/movie not archive).
albumItem.php::631 -> Extension is accepted.
albumItem.php::633 -> Filename processing.
albumItem.php::682 -> No caption given, generating it.
albumItem.php::479 -> Generated caption. Type: filename
Adding fujiapple.jpg
Album.php::1313 -> Doing the naming of the physical file.
Album.php::1351 -> Image preprocessing
Album.php::1356 -> Resizing/compressing original file
imageManipulation.php::36 -> Resizing Image: C:/inetpub/wwwroot/TestPics/albums/album01/fujiapple.jpg.
filesystem.php::109 -> extension of file fujiapple.jpg is jpg
util.php::236 -> Getting Dimension of file: C:/inetpub/wwwroot/TestPics/albums/album01/fujiapple.jpg
util.php::246 -> Dimensions: x: 233 y: 213
imageManipulation.php::69 -> No resizing required.
imageManipulation.php::672 -> File C:/inetpub/wwwroot/TestPics/albums/album01/fujiapple.jpg type 2.
util.php::236 -> Getting Dimension of file: C:/inetpub/wwwroot/TestPics/albums/album01/fujiapple.jpg
util.php::246 -> Dimensions: x: 233 y: 213
AlbumItem.php::697 -> Generating thumbnail.
AlbumItem.php::700 -> Saved dimensions: width:233 ; height:213
AlbumItem.php::778 -> Generating normal thumbs.
imageManipulation.php::36 -> Resizing Image: C:/inetpub/wwwroot/TestPics/albums/album01/fujiapple.jpg.
filesystem.php::109 -> extension of file fujiapple.jpg is jpg
util.php::236 -> Getting Dimension of file: C:/inetpub/wwwroot/TestPics/albums/album01/fujiapple.jpg
util.php::246 -> Dimensions: x: 233 y: 213
imageManipulation.php::793 -> Compressing image: C:/inetpub/wwwroot/TestPics/albums/album01/fujiapple.jpg
util.php::182 -> Executing: C:\ProgramFiles\ImageMagick-6.4.8-Q16\convert.exe -size 150x150 C:\inetpub\wwwroot\TestPics\albums\album01\fujiapple.jpg -quality 50 -thumbnail 150x150 C:\inetpub\wwwroot\TestPics\albums\album01\fujiapple.thumb.jpg
Results:
none
Debug messages:
Status: 1 (expected 0)
filesystem.php::278 -> Getting Exif from: C:/inetpub/wwwroot/TestPics/albums/album01/fujiapple.jpg
util.php::182 -> Executing: C:\ProgramFiles\Jhead\jhead.exe C:\inetpub\wwwroot\TestPics\albums\album01\fujiapple.jpg
Results:
File name : C:\inetpub\wwwroot\TestPics\albums\album01\fujiapple.jpg
File size : 6792 bytes
File date : 2008:12:28 11:34:10
Resolution : 233 x 213
Debug messages:
Status: 0 (expected 0)
util.php::620 -> Got no capture date. Using file modification time.
util.php::631 -> Item Capture Date: 12/28/08 11:34:10
Album.php::881 -> Setting highlight
imageManipulation.php::36 -> Resizing Image: C:/inetpub/wwwroot/TestPics/albums/album01/fujiapple.jpg.
filesystem.php::109 -> extension of file fujiapple.jpg is jpg
util.php::236 -> Getting Dimension of file: C:/inetpub/wwwroot/TestPics/albums/album01/fujiapple.jpg
util.php::246 -> Dimensions: x: 233 y: 213
imageManipulation.php::793 -> Compressing image: C:/inetpub/wwwroot/TestPics/albums/album01/fujiapple.jpg
util.php::182 -> Executing: C:\ProgramFiles\ImageMagick-6.4.8-Q16\convert.exe -size 200x200 C:\inetpub\wwwroot\TestPics\albums\album01\fujiapple.jpg -quality 70 -thumbnail 200x200 C:\inetpub\wwwroot\TestPics\albums\album01\fujiapple.highlight.jpg
Results:
none
Debug messages:
Status: 1 (expected 0)
Album.php::1442 -> Check if image needs to be rotated
filesystem.php::278 -> Getting Exif from: C:\inetpub\wwwroot\TestPics\PHPUploadFolder\galC05.tmp
util.php::182 -> Executing: C:\ProgramFiles\Jhead\jhead.exe C:\inetpub\wwwroot\TestPics\PHPUploadFolder\galC05.tmp
Results:
none
Debug messages:
Status: 1 (expected 0)
Album.php::1460 -> Orientation:
- Photo NOT auto-rotated/transformed
Item successfully added.
==============
In the above case, I'm using ImageMagick. But the same issue occurs with Netpbm as well.
I've double checked all of my folder permissions as well as the permission on cmd.exe. All enable IUSR_<MachineName> Read/Execute for executables and Modify for folder.
Just for reference, here is the diagnostic on ImageMagick:
----------
Gallery ImageMagick Check
This script is designed to examine your ImageMagick installation to see if it is ok to be used by Gallery.You should run this script after you have run the config wizard, if you have had problems with your ImageMagick installation that the wizard did not detect.
Loading configuration files. If you see an error here, it is probably because you have not successfully run the config wizard. OK
Let us see if we can figure out what operating system you are using.
This is what your system reports:
WindowsNT GOOD6 2 5 x86
This is the type of system on which PHP was compiled:
Windows NT GOOD6 5.2 build 3790
Make sure that the values above make sense to you.
Look for keywords like "Linux", "Windows", "FreeBSD" etc. in the output above.If both the attempts above failed, you should ask your ISP what operating system you are using.You can check via Netcraft, they can often tell you.
You told the config wizard that your ImageMagick binaries live here:
C:\ProgramFiles\ImageMagick-6.4.8-Q16
If that is not right (or if it is blank), re-run the configuration wizard and enter a location for ImageMagick.
We are going to test each ImageMagick binary individually.
Checking: C:\ProgramFiles\ImageMagick-6.4.8-Q16\identify.exe Expected status: 0, but actually received status 1.
Checking: C:\ProgramFiles\ImageMagick-6.4.8-Q16\convert.exe Expected status: 0, but actually received status 1.
Checking: C:\ProgramFiles\ImageMagick-6.4.8-Q16\composite.exe OK! Version: can't detect version on Windows.
If you see an error above complaining about reading or writing to C:\inetpub\wwwroot\TestPics\PHPUploadFolder\galC0A.tmp then this is likely a permission/configuration issue on your system. If it mentions open_basedir then it's because your system is configured with open_basedir enabled. You should talk to your system administrator about this, or see the Gallery Help Page.
For other errors, please refer to the list of possible responses in FAQ C.2 to get more information.
Return to Configuration Wizard.
==========
The image processor output files (thumbnail, highlight, etc) are NOT appearing in the album directory - as if the exec call does not find the convert.exe file. However when I run the exec from my own command prompt, the command completes and the files are created (hence the exec command appears to be correctly formed).
If anyone has any ideas, I would be greatly interested. Just to reiterate, I do not believe this to be a configuration issue since I have set up a number of successful galleries. I believe this to be a server issue beyond the typical permissions.
Thanks!
Posts: 6
Can you post an image of 1MB max to your gallery?
Posts: 7
I can post images of any size (up to the PHP max). Size does not appear to be an issue. Thanks!
Posts: 7
Found the problem. It was folder/file permissions on the gallery albums.
Due to a recent security audit, we removed the "Users" group security permission on wwwroot and propogated that change to all subfolders (specific user access is now granted on an as needed basis to individual folders/sites). When that happened, the application pool permission (Network Services) was no longer able to access the albums folders.
The solution was to add "Network Services" with Modify access to the gallery folder/subfolders. This is also true for the Temp directory!
Hope this helps other IIS folks.