Hello everyone,
I'm getting complaints from my ISP about both NPROC faults and memory faults.
First, I've seen past threads that are terminated by the comment "cheap hosting service". My ISP likes to encourage a dedicated VPS for the Piwigo app.
The issue "seems to be" too many thumbnail generation threads being created simultaneously.
I read that one way to resolve this might be to add the following line to local/config/config.inc.php:
$conf['sync_max_representative_generations'] = 1;
I had previously attempted to generate the thumbnails offline using imagemagick and uploaded them but I either named them incorrectly, placed them incorrectly, or some other problem is still causing thumbnail threads to be created.
For a while, and to ensure it was Piwigo generating the faults, I moved to local hosting on a reverse proxy nginx setup which got my isp off my back.
I'm running wikimedia, phpbb, and some other custom apps on the same service, but none of them are high traffic sites.
Any other insights are appreciated, I recognize the era of $20/month cheap hosting might be going away but it since this is a family project and not a commercial site, I can accept some tradeoff in speed for keeping costs down.
Using 15.3.0.
Thanks
Offline
Hi,
to create the thumbnails in one fly I use the following script (I run it every time after uploading some pictures).
This works on my Linux machine. If you are on Windows use a similar approach.
------------------------------
#!/usr/bin/bash
wget --keep-session-cookies --save-cookies cookies.txt --delete-after --post-data="username=XXXXX&password=YYYYYYY" "https://<your-URL>/ws.php?format=json&method=pwg.session.login"
wget --load-cookies cookies.txt -nv -O missing.json "https://<your-URL>/ws.php?format=json&method=pwg.getMissingDerivatives"; wc -c missing.json | awk '{print $1}'
while [ `wc -c missing.json | awk '{print $1}'` -gt 50 ]
do
sed -e 's/[\\\"]//g' \
-e 's/{stat:ok,result:{next_page:[0-9]*,urls:\[//' \
-e 's/{stat:ok,result:{urls:\[//' \
-e 's/\]}}/\n/' \
-e 's/,/\n/g' \
-e 's/\&b=[0-9]*//g' missing.json | \
while read line ; do
wget -nv -O /dev/null $line
done
wget --load-cookies cookies.txt -nv -O missing.json "https://<your-URL>/ws.php?format=json&method=pwg.getMissingDerivatives"
done
Offline