-
Notifications
You must be signed in to change notification settings - Fork 182
Post Processing Hangs
The nZEDb post-processing scripts perform analysis using various in-built routines and 3rd party applications. Given the variety of content posted (some of it totally encrypted) it does occur that some posts cause post-processing to hang or crash, often within an external application not managed directly by the nZEDb team.
There are several ways to reduce this happening. Firstly ensure all 3rd party applications are updated to their latest versions. The version shipped with your distribution is often not robust enough. Check all those defined in Site-Edit->3rd Party Applications. Also configure the timeout application in that section.
Below example commands for *nix users finding hung post-processing scripts. These examples assume you're using the PHP versions of the multi-threaded PP scripts. They're recommended over the python versions.
Note: Not every command outputs the release ID in process.
List PHP PP-Additional processes
ps aux | grep -v grep | grep -i nzedb | sed -e 's/:/ /g' | sort -nk9,10 | grep ProcessAdditional.php
PID of first PHP PP-Additional process running longer than 5 minutes
ps aux | grep -v grep | grep -i nzedb | sed -e 's/:/ /g' | sort -nk9,10 | grep -m1 ProcessAdditional.php | awk -v min=$( date +%M ) -v hour=$( date +%H ) '{if (hour > $9) min=min+60} {if ((min - $10) > 5) print $2}'
List PHP NFO processes active
ps aux | grep -v grep | grep -i nzedb | sed -e 's/:/ /g' | sort -nk9,10 | grep "switch.php php pp_nfo"
PID of first PHP PP-NFO process running longer than 5 minutes
ps aux | grep -v grep | grep -i nzedb | sed -e 's/:/ /g' | sort -nk9,10 | grep -m1 "switch.php php pp_nfo" | awk -v min=$( date +%M ) -v hour=$( date +%H ) '{if (hour > $9) min=min+60} {if ((min - $10) > 5) print $2}'
PID of first 7ZA PP process running longer than 5 minutes
ps aux | grep -v grep | grep nzedb | sed -e 's/:/ /g' | sort -nk9,10 | grep -m1 7za | awk -v min=$( date +%M ) -v hour=$( date +%H ) '{if (hour > $9) min=min+60} {if ((min - $10) > 5) print $2}'
PID of first amazon/XXX PP process running longer than 5 minutes
ps aux | grep -v grep | grep nzedb | sed -e 's/:/ /g' | sort -nk9,10 | grep -m1 "postprocess.php amazon" | awk -v min=$( date +%M ) -v hour=$( date +%H ) '{if (hour > $9) min=min+60} {if ((min - $10) > 5) print $2}'
Displaying details about a particular release
An example SQL query
> SELECT ID,passwordstatus,guid,fromname,name,searchname FROM releases WHERE ID = nnnnnnn;
The GUID output here can be used below.
Deleting a single release
To delete a particular release, use the delete_releases.php script to remove the release from the database along with its related meta objects.
php ~/misc/testing/Release/delete_releases.php guid=equals=NNNNNNNNNNNNNNNNNNNNNNNNN