ErrorException [ Warning Message ]:
file(/proc/loadavg) [function.file]: failed to open stream: Permission denied
MODPATH/gallery/helpers/gallery_block.php[ 75 ]
70 $block->css_id = "g-platform";
71 $block->title = t("Platform information");
72 $block->content = new View("admin_block_platform.html");
73 if (@is_readable("/proc/loadavg")) {
74 $block->content->load_average =
75 join(" ", array_slice(explode(" ", current(file("/proc/loadavg"))), 0, 3));
76 } else {
77 $block->content->load_average = t("Unavailable");
78 }
79 break;
80
{PHP internal call} » gallery_error_Core::error_handler()
MODPATH/gallery/helpers/gallery_block.php[ 75 ] » file( arguments )
{PHP internal call} » gallery_block_Core::get( arguments )
MODPATH/gallery/helpers/block_manager.php[ 106 ] » call_user_func( arguments )
MODPATH/gallery/controllers/admin_dashboard.php[ 26 ] » block_manager_Core::get_html( arguments )
{PHP internal call} » Admin_Dashboard_Controller->index()
MODPATH/gallery/controllers/admin.php[ 57 ] » call_user_func_array( arguments )
{PHP internal call} » Admin_Controller->__call( arguments )
SYSPATH/core/Kohana.php[ 330 ] » ReflectionMethod->invokeArgs( arguments )
{PHP internal call} » Kohana_Core::instance( arguments )
SYSPATH/core/Event.php[ 208 ] » call_user_func_array( arguments )
APPPATH/Bootstrap.php[ 67 ] » Event_Core::run( arguments )
DOCROOT/index.php[ 91 ] » require( arguments )
Posts: 121
I can get to any of the sub areas of the admin sections, just not the initial dashboard page.
Posts: 16503
Try upgrading to the latest experimental code.
Get it here:
http://github.com/gallery/gallery3/zipball/master
Upgrade instructions here:
http://codex.gallery2.org/Gallery3:Upgrading
Looks like your host doesn't allow access to read the loadavg on the server. I don't know about the RC1 code, but in the current code I'm running G3 checks to see if /proc/loadavg is readable. If not, then it doesn't do anything if so, then it grabs that info and displays it.
Oh wait, looks like code you posted is the same as what I have. I just set my /proc/loadavg to 400 so that the webserver can't read it and I get the expected behavior, the dashboard loads and just displays "Unavailable" for that.
Could you contact your host and see if they can think of why this would be failing?
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here
Posts: 121
The odd thing is I have two instances of Gallery3 running with the same host. Both are setup as www.MyURL.com/gallery and are running on the same web server. The other one is working with no issues but this one (G2 imported one) is failing.
Posts: 16503
Ah, try going to the Maintenance page and running the Fix Album/Photo hierarchy task.
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here
Posts: 121
I don't have that option in either of my G3 installs on the Maintenance page. The options I have are;
Update Search Index
Import from Gallery 2
Rebuild Images
Update translations
Remove old files
Posts: 16503
Then that was added after RC1 was released, try upgrading to the latest experimental code.
Get it here:
http://github.com/gallery/gallery3/zipball/master
Upgrade instructions here:
http://codex.gallery2.org/Gallery3:Upgrading
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here
Posts: 121
Ok, I installed the latest copy and ran the upgrader. Afterwards the option you suggested was available and I ran it. Still no dice though, the Dashboard page bombs with the same error message.
Posts: 16503
I have no idea then how you can have 2 installs of G3 on the same host and one works and one doesn't. Ask your host to see if they can see anything.
Do these 2 installs happen to be on different servers, still at the same host, but on different servers?
I'd also compare the code bases to see if there are differences, especially in that file:
gallery/helpers/gallery_block.php
As well as differences between your PHP environments.
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here
Posts: 121
Hmmm they do load balancing so maybe they are on different running http servers. I'll check the PHPinfo from the other one as well and compare their files.
Posts: 121
They are running on different cluster machines.
The gallery_block.php file is nearly the same between the RC1 and night build (there's a slight difference in case "language" where this is case "platform_info").
I logged into my other admin after figuring out exactly what info this is returning. On that install in the Platform Information block the "Server load:" output is blank.
So I changed the code for that section as follows and it works now because it ignores that item no matter what. It seems it has access to read /proc/loadavg but it does not have access to execute it. This then results in epic fail!
Posts: 121
So this could be because /proc/loadavg has different permissions, the different servers have mismatching versions, etc. Either way in some sort of case even if the file is readable it can result in both no information returned and the system showing it as blank or an error being returned resulting in the page failing.
Posts: 25945
brentil,
Thanks for the detective work!
Please file a bug report so we can do a better job of detecting this issue.
https://sourceforge.net/apps/trac/gallery/newticket
So we don't loose track of this issue.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 121
Ticket made!
Posts: 25945
Thanks.
For the benefit of others:
https://sourceforge.net/apps/trac/gallery/ticket/1149
Posts: 25945
Fixed:
http://github.com/gallery/gallery3/commit/ab0bef14be78701aedd647dd4eaccab641b6d01d
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 121
FYI this has creeped back into Gallery 3.0 final again. I hardly ever use the dashboard and just recently upgraded so I'm just now noticing this.
Posts: 7985
This is https://sourceforge.net/apps/trac/gallery/ticket/1491 -- fixed in 3.0.1
---
Problems? Check gallery3/var/logs
file a bug/feature ticket | upgrade to the latest code! | hacking G3? join us on IRC!