Announcement

#1 2016-05-21 20:14:44

Mark O'Shea
Member
2013-05-27
26

Problem changing photos sort order of large album

Hello,

I've noticed a problem with my Pwigo gallery.

If I try to change the sort order of an album with 996 pictures or greater, Piwigo does not save the changes and there is no green confirmation message displayed above the thumbnails. When I look at the sort order box (at the bottom of the page) it does not show the changes submitted previously.

If I try it with an album of 995 images or less, the changes are saved as expected.

I did my testing to find the above numbers with a SmartAlbum filtered with the max number of photos set. The issue seems to effect every large album in my gallery, whether it be a SmartAlbum or a standard album.

Any idea what's causing this?

Cheers
Mark

Piwigo version: Piwigo 2.8.1
PHP version: PHP: 5.3.3-7+squeeze19
MySQL version: MySQL: 5.1.73-1
Active Plugins:

Additional Pages
Admin Tools
Advanced Menu Manager
AStat.2
Autocomplete
Crypto Captcha
Extended Description
Grum Plugin Classes
Header Manager
LocalFiles Editor
PWG Stuffs
SmartAlbums
Statistics
Take a Tour
UserAdvManager

Offline

 

#2 2019-06-12 21:59:13

kos
Member
2019-06-12
10

Re: Problem changing photos sort order of large album

Thanks for finding out the numbers!
"Glad" that I'm not the only one with the same issue.
I have it with my largest album containing 1950 pictures.
Second largest album only contains 911 pics and does not have that problem.
So kind of confirming your numbers.

Offline

 

#3 2019-10-05 19:02:56

wreck
Member
2019-10-05
1

Re: Problem changing photos sort order of large album

I was running into this and spotted the following error in my nginx error logs:

Code:

[error] 12698#12698: *55483 FastCGI sent in stderr: "PHP message: PHP Warning:  Unknown: Input variables exceeded 1000. To increase the limit change max_input_vars in php.ini. in Unknown on line 0"

adding the value

Code:

max_input_vars = 5000

to php.ini (or a variant of it, depending on how your php and webserver is configured) ought to resolve the issue.

Offline

 

#4 2021-05-05 03:58:10

Mark O'Shea
Member
2013-05-27
26

Re: Problem changing photos sort order of large album

Thanks for the suggestion Wreck. You were spot on!

I upped the value on my server to 10,000 and I can now save the automatic order of my larger galleries.

I've not noticed any side effects in making this change. I will report back if any come to light.

I did come across a thread on stackoverflow.com where there is a question about max_input_vars and possible issues you might need to be aware of when changing this value.

Here's what I had to do make the change...

I've got quite unique set-up so I had to edit this php.ini file:

/etc/php/7.3/fpm/php.ini

I added this line:

max_input_vars = 10000

To make the system reload the php configuration file, I had to run this:

systemctl restart php7.3-fpm.service

To check my configuration change had gone though, I created a php page with this code:

<?php phpinfo(); ?>

That page shows all the php configuration values and on there I could see the newly updated setting.

I can now successfully save the automatic sort order for galleries of up to 10,000 images!

Offline

 

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact