Hi.. Before post i had search any problem related with my problem (http://galleryproject.org/node/112064) but it's does not solve for my problem.
Here the problem until change the code
Quote:
Task Rebuild Images started (task id 13)
Unable to rebuild images for title '926'
exception 'Exception' with message '@todo EMPTY_INPUT_FILE' in /Data/foto/modules/gallery/helpers/gallery_graphics.php:79
Stack trace:
#0 [internal function]: gallery_graphics_Core::resize('/Data/foto/...', '/Data/foto/...', Array, Object(Item_Model))
#1 /Data/foto/modules/gallery/helpers/graphics.php(171): call_user_func_array('gallery_graphic...', Array)
#2 /Data/foto/modules/gallery/helpers/gallery_task.php(111): graphics_Core::generate(Object(Item_Model))
#3 [internal function]: gallery_task_Core::rebuild_dirty_images(Object(Task_Model))
#4 /Data/foto/modules/gallery/helpers/task.php(90): call_user_func_array('gallery_task::r...', Array)
#5 /Data/foto/modules/gallery/controllers/admin_maintenance.php(195): task_Core::run('13')
#6 [internal function]: Admin_Maintenance_Controller->run('13')
#7 /Data/foto/modules/gallery/controllers/admin.php(62): call_user_func_array(Array, Array)
#8 [internal function]: Admin_Controller->__call('maintenance', Array)
#9 /Data/foto/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Object(Admin_Controller), Array)
#10 [internal function]: Kohana_Core::instance(NULL)
#11 /Data/foto/system/core/Event.php(208): call_user_func_array(Array, Array)
#12 /Data/foto/application/Bootstrap.php(67): Event_Core::run('system.execute')
#13 /Data/foto/index.php(116): require('/Data/foto/...')
#14 {main}
Updated: 0 images. Total: 1.
And the next problem i dont't know it's related with Rebuilt Image or not, coz the problem when i see the error Rebuild Images. My thumbnail folder is missing, here my structure of gallery..
/...
/picbydate/
........../YEAR/
................/MONTH/
......................./DAY/
.........................../title of album
And the problem all folder in DAY folder eg (oct 10) all files is missing, no thumbnail but when click the detail of picture it's show. I try install module Rebuild items and mark to rebuild image but it don't work and got error
Quote:
Task Rebuild Images started (task id 15)
Unable to rebuild images for '59661'
exception 'Exception' with message '@todo UNREADABLE_FILE' in /Data/foto/modules/gallery/helpers/photo.php:104
Stack trace:
#0 /Data/foto/modules/gallery/helpers/graphics.php(252): photo_Core::get_file_metadata('/Data/foto/...')
#1 /Data/foto/modules/gallery/helpers/graphics.php(235): graphics_Core::_update_item_dimensions(Object(Item_Model))
#2 /Data/foto/modules/gallery/helpers/gallery_task.php(111): graphics_Core::generate(Object(Item_Model))
#3 [internal function]: gallery_task_Core::rebuild_dirty_images(Object(Task_Model))
#4 /Data/foto/modules/gallery/helpers/task.php(90): call_user_func_array('gallery_task::r...', Array)
#5 /Data/foto/modules/gallery/controllers/admin_maintenance.php(195): task_Core::run('15')
#6 [internal function]: Admin_Maintenance_Controller->run('15')
#7 /Data/foto/modules/gallery/controllers/admin.php(62): call_user_func_array(Array, Array)
#8 [internal function]: Admin_Controller->__call('maintenance', Array)
#9 /Data/foto/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Object(Admin_Controller), Array)
#10 [internal function]: Kohana_Core::instance(NULL)
#11 /Data/foto/system/core/Event.php(208): call_user_func_array(Array, Array)
#12 /Data/foto/application/Bootstrap.php(67): Event_Core::run('system.execute')
#13 /Data/foto/index.php(116): require('/Data/foto/...')
#14 {main}
Unable to rebuild images for '59674'
exception 'Exception' with message '@todo UNREADABLE_FILE' in /Data/foto/modules/gallery/helpers/photo.php:104
Stack trace:
#0 /Data/foto/modules/gallery/helpers/graphics.php(255): photo_Core::get_file_metadata('/Data/foto/...')
#1 /Data/foto/modules/gallery/helpers/graphics.php(235): graphics_Core::_update_item_dimensions(Object(Item_Model))
#2 /Data/foto/modules/gallery/helpers/gallery_task.php(111): graphics_Core::generate(Object(Item_Model))
#3 [internal function]: gallery_task_Core::rebuild_dirty_images(Object(Task_Model))
#4 /Data/foto/modules/gallery/helpers/task.php(90): call_user_func_array('gallery_task::r...', Array)
#5 /Data/foto/modules/gallery/controllers/admin_maintenance.php(195): task_Core::run('15')
#6 [internal function]: Admin_Maintenance_Controller->run('15')
#7 /Data/foto/modules/gallery/controllers/admin.php(62): call_user_func_array(Array, Array)
#8 [internal function]: Admin_Controller->__call('maintenance', Array)
#9 /Data/foto/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Object(Admin_Controller), Array)
#10 [internal function]: Kohana_Core::instance(NULL)
#11 /Data/foto/system/core/Event.php(208): call_user_func_array(Array, Array)
#12 /Data/foto/application/Bootstrap.php(67): Event_Core::run('system.execute')
#13 /Data/foto/index.php(116): require('/Data/foto/...')
#14 {main}
Unable to rebuild images for '59664'
exception 'Exception' with message '@todo UNREADABLE_FILE' in /Data/foto/modules/gallery/helpers/photo.php:104
Stack trace:
#0 /Data/foto/modules/gallery/helpers/graphics.php(252): photo_Core::get_file_metadata('/Data/foto/...')
#1 /Data/foto/modules/gallery/helpers/graphics.php(235): graphics_Core::_update_item_dimensions(Object(Item_Model))
#2 /Data/foto/modules/gallery/helpers/gallery_task.php(111): graphics_Core::generate(Object(Item_Model))
#3 [internal function]: gallery_task_Core::rebuild_dirty_images(Object(Task_Model))
#4 /Data/foto/modules/gallery/helpers/task.php(90): call_user_func_array('gallery_task::r...', Array)
#5 /Data/foto/modules/gallery/controllers/admin_maintenance.php(195): task_Core::run('15')
#6 [internal function]: Admin_Maintenance_Controller->run('15')
#7 /Data/foto/modules/gallery/controllers/admin.php(62): call_user_func_array(Array, Array)
#8 [internal function]: Admin_Controller->__call('maintenance', Array)
#9 /Data/foto/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Object(Admin_Controller), Array)
#10 [internal function]: Kohana_Core::instance(NULL)
#11 /Data/foto/system/core/Event.php(208): call_user_func_array(Array, Array)
#12 /Data/foto/application/Bootstrap.php(67): Event_Core::run('system.execute')
#13 /Data/foto/index.php(116): require('/Data/foto/...')
#14 {main}
Unable to rebuild images for '59665'
exception 'Exception' with message '@todo UNREADABLE_FILE' in /Data/foto/modules/gallery/helpers/photo.php:104
Stack trace:
#0 /Data/foto/modules/gallery/helpers/graphics.php(252): photo_Core::get_file_metadata('/Data/foto/...')
#1 /Data/foto/modules/gallery/helpers/graphics.php(235): graphics_Core::_update_item_dimensions(Object(Item_Model))
#2 /Data/foto/modules/gallery/helpers/gallery_task.php(111): graphics_Core::generate(Object(Item_Model))
#3 [internal function]: gallery_task_Core::rebuild_dirty_images(Object(Task_Model))
#4 /Data/foto/modules/gallery/helpers/task.php(90): call_user_func_array('gallery_task::r...', Array)
#5 /Data/foto/modules/gallery/controllers/admin_maintenance.php(195): task_Core::run('15')
#6 [internal function]: Admin_Maintenance_Controller->run('15')
#7 /Data/foto/modules/gallery/controllers/admin.php(62): call_user_func_array(Array, Array)
#8 [internal function]: Admin_Controller->__call('maintenance', Array)
#9 /Data/foto/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Object(Admin_Controller), Array)
#10 [internal function]: Kohana_Core::instance(NULL)
#11 /Data/foto/system/core/Event.php(208): call_user_func_array(Array, Array)
#12 /Data/foto/application/Bootstrap.php(67): Event_Core::run('system.execute')
#13 /Data/foto/index.php(116): require('/Data/foto/...')
#14 {main}
Unable to rebuild images for '59666'
exception 'Exception' with message '@todo UNREADABLE_FILE' in /Data/foto/modules/gallery/helpers/photo.php:104
Stack trace:
#0 /Data/foto/modules/gallery/helpers/graphics.php(252): photo_Core::get_file_metadata('/Data/foto/...')
#1 /Data/foto/modules/gallery/helpers/graphics.php(235): graphics_Core::_update_item_dimensions(Object(Item_Model))
#2 /Data/foto/modules/gallery/helpers/gallery_task.php(111): graphics_Core::generate(Object(Item_Model))
#3 [internal function]: gallery_task_Core::rebuild_dirty_images(Object(Task_Model))
#4 /Data/foto/modules/gallery/helpers/task.php(90): call_user_func_array('gallery_task::r...', Array)
#5 /Data/foto/modules/gallery/controllers/admin_maintenance.php(195): task_Core::run('15')
#6 [internal function]: Admin_Maintenance_Controller->run('15')
#7 /Data/foto/modules/gallery/controllers/admin.php(62): call_user_func_array(Array, Array)
#8 [internal function]: Admin_Controller->__call('maintenance', Array)
#9 /Data/foto/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Object(Admin_Controller), Array)
#10 [internal function]: Kohana_Core::instance(NULL)
#11 /Data/foto/system/core/Event.php(208): call_user_func_array(Array, Array)
#12 /Data/foto/application/Bootstrap.php(67): Event_Core::run('system.execute')
#13 /Data/foto/index.php(116): require('/Data/foto/...')
#14 {main}
Unable to rebuild images for '59663'
exception 'Exception' with message '@todo UNREADABLE_FILE' in /Data/foto/modules/gallery/helpers/photo.php:104
Stack trace:
#0 /Data/foto/modules/gallery/helpers/graphics.php(252): photo_Core::get_file_metadata('/Data/foto/...')
#1 /Data/foto/modules/gallery/helpers/graphics.php(235): graphics_Core::_update_item_dimensions(Object(Item_Model))
#2 /Data/foto/modules/gallery/helpers/gallery_task.php(111): graphics_Core::generate(Object(Item_Model))
#3 [internal function]: gallery_task_Core::rebuild_dirty_images(Object(Task_Model))
#4 /Data/foto/modules/gallery/helpers/task.php(90): call_user_func_array('gallery_task::r...', Array)
#5 /Data/foto/modules/gallery/controllers/admin_maintenance.php(195): task_Core::run('15')
#6 [internal function]: Admin_Maintenance_Controller->run('15')
#7 /Data/foto/modules/gallery/controllers/admin.php(62): call_user_func_array(Array, Array)
#8 [internal function]: Admin_Controller->__call('maintenance', Array)
#9 /Data/foto/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Object(Admin_Controller), Array)
#10 [internal function]: Kohana_Core::instance(NULL)
#11 /Data/foto/system/core/Event.php(208): call_user_func_array(Array, Array)
#12 /Data/foto/application/Bootstrap.php(67): Event_Core::run('system.execute')
#13 /Data/foto/index.php(116): require('/Data/foto/...')
#14 {main}
Unable to rebuild images for '59662'
exception 'Exception' with message '@todo UNREADABLE_FILE' in /Data/foto/modules/gallery/helpers/photo.php:104
Stack trace:
#0 /Data/foto/modules/gallery/helpers/graphics.php(252): photo_Core::get_file_metadata('/Data/foto/...')
#1 /Data/foto/modules/gallery/helpers/graphics.php(235): graphics_Core::_update_item_dimensions(Object(Item_Model))
#2 /Data/foto/modules/gallery/helpers/gallery_task.php(111): graphics_Core::generate(Object(Item_Model))
#3 [internal function]: gallery_task_Core::rebuild_dirty_images(Object(Task_Model))
#4 /Data/foto/modules/gallery/helpers/task.php(90): call_user_func_array('gallery_task::r...', Array)
#5 /Data/foto/modules/gallery/controllers/admin_maintenance.php(195): task_Core::run('15')
#6 [internal function]: Admin_Maintenance_Controller->run('15')
#7 /Data/foto/modules/gallery/controllers/admin.php(62): call_user_func_array(Array, Array)
#8 [internal function]: Admin_Controller->__call('maintenance', Array)
#9 /Data/foto/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Object(Admin_Controller), Array)
#10 [internal function]: Kohana_Core::instance(NULL)
#11 /Data/foto/system/core/Event.php(208): call_user_func_array(Array, Array)
#12 /Data/foto/application/Bootstrap.php(67): Event_Core::run('system.execute')
#13 /Data/foto/index.php(116): require('/Data/foto/...')
#14 {main}
Unable to rebuild images for '926'
exception 'Exception' with message '@todo EMPTY_INPUT_FILE' in /Data/foto/modules/gallery/helpers/gallery_graphics.php:79
Stack trace:
#0 [internal function]: gallery_graphics_Core::resize('/Data/foto/...', '/Data/foto/...', Array, Object(Item_Model))
#1 /Data/foto/modules/gallery/helpers/graphics.php(171): call_user_func_array('gallery_graphic...', Array)
#2 /Data/foto/modules/gallery/helpers/gallery_task.php(111): graphics_Core::generate(Object(Item_Model))
#3 [internal function]: gallery_task_Core::rebuild_dirty_images(Object(Task_Model))
#4 /Data/foto/modules/gallery/helpers/task.php(90): call_user_func_array('gallery_task::r...', Array)
#5 /Data/foto/modules/gallery/controllers/admin_maintenance.php(195): task_Core::run('15')
#6 [internal function]: Admin_Maintenance_Controller->run('15')
#7 /Data/foto/modules/gallery/controllers/admin.php(62): call_user_func_array(Array, Array)
#8 [internal function]: Admin_Controller->__call('maintenance', Array)
#9 /Data/foto/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Object(Admin_Controller), Array)
#10 [internal function]: Kohana_Core::instance(NULL)
#11 /Data/foto/system/core/Event.php(208): call_user_func_array(Array, Array)
#12 /Data/foto/application/Bootstrap.php(67): Event_Core::run('system.execute')
#13 /Data/foto/index.php(116): require('/Data/foto/...')
#14 {main}
Updated: 0 images. Total: 8.
|
Posts: 27300
This is the code it is trying to execute:
So it would seem that the file is not readable by the server/user that php runs as.
Keep in mind that PHP may be accessing the file as the user id that the web server runs as (often 'nobody'). Perhaps that user does not have permissions to the gallery3/var/ directory.
Ask you host to verify permissions of that directory for PHP to read and write.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 4
My web server using apache and running with user apache, and all file and directory permission as apache, i think no issue about about permission.
If issue about permission no new photo uploaded. This issue only one folder problem with sub folder missing the thumbnail.
Henry
Posts: 27300
Then I would suspect that there is something different about the one folder.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 4
I see a similar issue but limited to just Album Covers. All was working fine until I upgraded to 3.0.9 (from 3.0.4). I've confirmed that the entire gallery3 directory is owned by apache.apache (CentOS 5.9) by running chown -R apache.apache /var/www/html/gallery3. The G3 log shows:
2013-10-31 16:21:12 -07:00 --- error: Caught exception rebuilding images: Berkwood Hedge Halloween 2013
@todo UNREADABLE_FILE
#0 /var/www/html/gallery3/modules/gallery/helpers/graphics.php(255): photo_Core::get_file_metadata('/var/www/html/g...')
#1 /var/www/html/gallery3/modules/gallery/helpers/graphics.php(223): graphics_Core::_update_item_dimensions(Object(Item_Model))
#2 /var/www/html/gallery3/modules/gallery/helpers/item.php(84): graphics_Core::generate(Object(Item_Model))
#3 /var/www/html/gallery3/modules/gallery/controllers/quick.php(69): item_Core::make_album_cover(Object(Item_Model))
#4 [internal function]: Quick_Controller->make_album_cover('13978')
#5 /var/www/html/gallery3/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Object(Quick_Controller), Array)
#6 [internal function]: Kohana_Core::instance(NULL)
#7 /var/www/html/gallery3/system/core/Event.php(208): call_user_func_array(Array, Array)
#8 /var/www/html/gallery3/application/Bootstrap.php(67): Event_Core::run('system.execute')
#9 /var/www/html/gallery3/index.php(116): require('/var/www/html/g...')
#10 {main}
2013-10-31 16:21:12 -07:00 --- error: Exception [ 0 ]: @todo UNREADABLE_FILE
/var/www/html/gallery3/modules/gallery/helpers/photo.php [ 104 ]
#0 /var/www/html/gallery3/modules/gallery/helpers/graphics.php(255): photo_Core::get_file_metadata('/var/www/html/g...')
#1 /var/www/html/gallery3/modules/gallery/helpers/graphics.php(223): graphics_Core::_update_item_dimensions(Object(Item_Model))
#2 /var/www/html/gallery3/modules/gallery/helpers/item.php(84): graphics_Core::generate(Object(Item_Model))
#3 /var/www/html/gallery3/modules/gallery/controllers/quick.php(69): item_Core::make_album_cover(Object(Item_Model))
#4 [internal function]: Quick_Controller->make_album_cover('13978')
#5 /var/www/html/gallery3/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Object(Quick_Controller), Array)
#6 [internal function]: Kohana_Core::instance(NULL)
#7 /var/www/html/gallery3/system/core/Event.php(208): call_user_func_array(Array, Array)
#8 /var/www/html/gallery3/application/Bootstrap.php(67): Event_Core::run('system.execute')
#9 /var/www/html/gallery3/index.php(116): require('/var/www/html/g...')
#10 {main}
The files upload fine (into a new sub-album and thumbnails look okay). Manually choosing an album cover doesn't seem to do anything either. I was able to generate the above backtrace by deleting .album.jpg from the sub-album's directory and then manually choosing a new album cover. Any ideas where to look?
TIA
Posts: 27300
This is what it is trying to run:
so it can't read the file.
Is is a php function not a gallery function:
is_readable — Tells whether a file exists and is readable.
Still sounds like a permissions issue to me.
Dave
____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 4
Okay so the exception I was referring to was because G3 couldn't read the .album.jpg file that I deleted in the hopes that the Album Cover image would be regenerated when I manually selected a new Album Cover from the G3 UI. I proved this out by modifying the throw to include the $file_path:
And now a snippet of the exception:
@todo UNREADABLE_FILE (/var/www/html/gallery3/var/thumbs/My-Album/.album.jpg)
So I guess ultimately my problem is that G3 is creating what I'd call a "place holder" instead of actual Album Covers neither during Album import nor when an image is manually selected from the G3 UI. MoreoverI don't see any errors in the G3 log.
So instead of seeing a thumbnail of one of my pictures that appears normally inside the album I see this: http://picpaste.com/Screen_Shot_2013-11-01_at_1.58.30_AM-GWzYFsZX.png And like I mentioned before I did not have this problem prior to upgrading to 3.0.9 (from 3.0.4).
Thanks again for any insight that you can provide!
Posts: 27300
Glad you where able to get more detail from the exception.
Still seems to be a permission issue on the server. It is a php function that is failing.
I suspect it will be fixed once this bug: http://sourceforge.net/apps/trac/gallery/ticket/1443 is addressed. But the suggestions in the bug tracker most likley will not help you.
I don't know what to say. I'm not a server permissions guy.
Just create a temporary one and see if it works since get_file_metadata will fail with a missing file as well.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 4
So just to be clear: after deleting .album.jpg--G3 shows in the browser for that particular album cover as a broken image (i.e. the browser displays a broken image and not the placeholder image). The G3 exception is only logged the first time that a.) the .album.jpg is missing and b.) when you tell G3 to create a new album cover from the G3 UI. So I think your suggestion to create a temporary one falls into this category.
So assuming those two conditions are met (you select a new album cover with the original/previous .album.jpg deleted from the file system) G3 then throws the exception but it still then creates .album.jpg nonetheless. The challenge is that rather than actually creating the desired Album Cover thumbnail with thumbnail image as selected from the G3 UI, G3 instead creates a placeholder image (it is created as .album.jpg) Here's an example of the placeholder image that G3 generated: http://picpaste.com/Screen_Shot_2013-11-01_at_10.30.59_AM-4imXAPUH.png
So then without ever deleting .album.jpg subsequent attempts to change Album Covers from the G3 UI do not cause the exception and the album cover image remains the place holder. The G3 UI indicates "<green checkmark>Made XXXX this album's cover". So at this point G3 thinks that it actually created the album cover (it grays out that particular image's option to make it an Album Cover". Moreover you can select other images as the Album Cover and G3 happily displays "<green checkmark>Made XXXX this album's cover" but the new Album Cover image is never created as I can see the .album.jpg timestamp never changes from the original time that the file was created. So it's almost as if G3 is silently failing or is unaware that what ever it does to create an Album Cover thumbnail is failing as I don't see any exceptions logged.
Maybe if I could understand or figure out how/when these various placeholders are used when .album.jpg is created I could figure out what's going wrong . . . With regard to [link] http://sourceforge.net/apps/trac/gallery/ticket/1443[/link] I think my particular problem is different in the sense that my web server (apache/mod_php) is not preventing the album cover from being retrieved (HTTP GET) by the client browser as I don't see broken image links (broken links as displayed by the browser) instead I see these "place holder" images. I've separately retrieved one of these .album.jpg files (by just copying it into my home directory and downloading) and viewed them natively on my local machine as JPEGs and they look just the same on my local machine as they do through the web browser (as the place holder images that I keep referring to).
Any thoughts on how/where/why these placeholders are created/substituted for real album cover thumbnail images? I was hoping to avoid learning the guts of G3 just to resolve this--but I'm open to suggestion and direction
Thanks again.
Posts: 27300
http://picpaste.com/Screen_Shot_2013-11-01_at_10.30.59_AM-4imXAPUH.png would be a placeholder image of a failed image toolkit creation. I the creation it done by the respective toolkit and we don't get debug info from it if it fails on any of the tasks we send it.
In some cases, if a image is just too big or takes too long to process the host will just terminate the process and it just dies. Gallery does not get any indication on this failure. That is just an example, not necessarily your issue.
Here is what I would try:
Add a small image (just slightly larger then the resized image) to a test album.
Add a couple of more.
Use the G3 UI to make album highlight of one of those images. If that works then we know that smaller images work. If not:
Change image toolkits (admin -> graphics) and repeat the above with small images.
As for why only album highlights, I have no clue why.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 4
@floridave: So it seems that if I add
$parent->thumb_dirty = TRUE;
to make_album_cover (in modules/gallery/helpers/item.php) my problem is resolved.Here's the function:
I don't really have any insight as to what $item->thumb_dirty is supposed to do (other than guessing by the name) so I'm not certain whether or not this is a hammer when a screw driver would be more appropriate but in any case it works for me. Please let me know if you think I should open a bug for this? I haven't yet tried your suggestions as I found my fix before you posted . . .
Posts: 4
Thanks Jamuel, it had try add you code but problem is same, currently my gallery still blank thumbnail but it's a anomaly problem.