Hello, On Fri, Feb 18, 2005 at 05:01:04PM +0100, Matías Costa wrote: > Package: mldonkey-server > Version: 2.5.28-2 > Severity: wishlist > Tags: patch > > The pid file stays after some unusual ocasions not related to mldonkey, i.e: > a > hard crash (really unusual :) . Next time mldonkey does not start because the > pid file exists, but no message is provided to the user, who has to guess the > issue and remove it manually. > > Adding this to /etc/init.d/mldonkey_server solves the problem. > > # Clean lost pid file > if [ -f "$PIDFILE" ]; then > MLDONKEY_PID=`cat $PIDFILE` > [ -f "/proc/${MLDONKEY_PID}/exe" ] && \ > MLDONKEY_PID_EXE=`readlink /proc/${MLDONKEY_PID}/exe` > if [ "$MLDONKEY_PID_EXE" != $WRAPPER ]; then > echo "Removing $DESC lost pid file: $PIDFILE." > rm $PIDFILE > fi > fi > > Please note this is not the same that removing .tmp files. These .tmp files > stop mlnet but a) user can see this in /var/log/messages, and b) the .tmp > files can store sensible info about mlnet state before its unusual stop. >
I am ok with your patch... I will try to include it in my next upload. Kind regard Sylvain Le Gall -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]