ZenphotoCMS Forum
Admin.php using too much CPU - Printable Version

+- ZenphotoCMS Forum (https://forum.zenphoto.org)
+-- Forum: Support (https://forum.zenphoto.org/forum-1.html)
+--- Forum: General support (https://forum.zenphoto.org/forum-4.html)
+--- Thread: Admin.php using too much CPU (/thread-9519.html)

Pages: 1 2


Admin.php using too much CPU - JerryG - 2012-01-24

I have a gallery with over 30,000 images. My SQL file is only about 30mb though. Every time I add new galleries I usually do it by creating a folder in FTP, as the ACP just doesn't work for me. It goes incredibly slow and sometimes does not load at all.

I was trying to get into one of my folders today to re-arrange the order of its subalbums, but it wouldn't load. It stops half way. Looking at my process manager, I saw that /zp-core/admin.php was using up 74.1 percent of the CPU load and 2.1 percent of the memory.

Why?




Admin.php using too much CPU - acrylian - 2012-01-24

Please see this current and similar topic: http://www.zenphoto.org/support/topic.php?id=10292

Also there is info on the user guide's troubleshooting how Zenphoto works regarding images. What you see is most likely your server not being able to process the images you uploaded
http://www.zenphoto.org/news/troubleshooting-guide




Admin.php using too much CPU - JerryG - 2012-01-24

But its processed every image on the actual gallery pages. Its just the ACP that's slow. A lot of the times, I'll get 500 Internal Server Errors trying to edit a gallery.




Admin.php using too much CPU - acrylian - 2012-01-24

No, it does not process all, it goes randomly through all to set an album thumb. If it has not been cached for the display it will be. The more images in the more albums you have the more it might need to cache. And if the image dimensions are quite big your server might not be able to process that. (see the troubleshooting to understand how Zenphoto being filesystem based works please).

On the images tab of course the display for the images on the left need to be generated as well.

So, either set a fixed album thumb for each album or use the option to show a stand-in replacement image for the albums list. For the images try using less images per page.

Additionally you might want to consider to use smaller images.




Admin.php using too much CPU - JerryG - 2012-01-24

All of my images are cached, though.




Admin.php using too much CPU - acrylian - 2012-01-24

How do you know that all images are cached with 30000 of them? If you use any of the pre cache tools older Zenphoto releases have, these don't apply to the backend.




Admin.php using too much CPU - JerryG - 2012-01-24

I'm talking about editing specific galleries. i.e. http://domain.com/zenphoto/zp-core/admin.php?page=edit&album=album-name-here

It either loads verrrry slowly or the page stops loading halfway or I get a 500 error.

I know all the images are cached because I have accessed that gallery on the main page and have look at all the images inside. I have 30,000 images, but they're not all in one gallery.




Admin.php using too much CPU - sbillard - 2012-01-24

Quote:I know all the images are cached because I have accessed that gallery on the main page and have look at all the images inside
Which of course has nothing to do with caching images for the back-end. But most likely the problem is with your thumbnail selection. See the thread pointed to by acrylian.




Admin.php using too much CPU - JerryG - 2012-01-24

The thread doesn't really tell me much. =(




Admin.php using too much CPU - sbillard - 2012-01-25

Sorry, I meant the post here by acrylian with regard to album thumbnail selection.




Admin.php using too much CPU - JerryG - 2012-01-26

I can't edit the default album thumbnail because I cannot get into an album and edit it.




Admin.php using too much CPU - acrylian - 2012-01-26

So you can't access the mail albums tab at all? Then your only chance is to access the album(s) via the admin toolbox from the front end only.

You probably might need to consider to upgrade your server so it is able to do the task especially if these images are quite big dimension wise.




Admin.php using too much CPU - JerryG - 2012-01-26

Is there any way to implement album sorting in the front end?




Admin.php using too much CPU - sbillard - 2012-01-26

That is a back-end function. It is accessable by appropriately permissioned users via the admin toolbox which will show on the front end.

You ask if there is any way to implement it for the front end and of course the answer is yes since the technique used on the back end could also be used on the front end. However we have no intention of doing this as it seems unnecessary and would present all sorts of security risks.




Admin.php using too much CPU - JerryG - 2012-01-26

So what do I do? I can't edit my albums and my server is already pretty top notch as it is.




Admin.php using too much CPU - sbillard - 2012-01-26

Did you try clicking on the button to use thumb standins?




Admin.php using too much CPU - JerryG - 2012-01-27

Where do I find that option?




Admin.php using too much CPU - acrylian - 2012-01-27

Well, that one is on the albums tab you cannot access actually... You probably need to set that via a MySQL query in this case I fear (sorry, don't know how it is called there right now).

If you can access Options > Gallery see also if these options are not checked:
Gallery behaviour > visual thumb selection
Gallery behaviour > show subalbum thumbs




Admin.php using too much CPU - sbillard - 2012-01-28

Your first post said that the page loads partly. If so, then the button is at the top of the list of albums. If your page is not loading at least that far, then the problem is entirely different.




Admin.php using too much CPU - JerryG - 2012-01-28

I am able to access the options page and while I already have Visual Thumb checked, there is no option for "Show Subalbum Thumbs." Perhaps that was added in a later version. I'm running on 1.2.1, I believe.