Debian Bug report logs - #295854
mldonkey-server: Remove lost pid file

version graph

Package: mldonkey-server; Maintainer for mldonkey-server is Debian OCaml Maintainers <debian-ocaml-maint@lists.debian.org>; Source for mldonkey-server is src:mldonkey (PTS, buildd, popcon).

Reported by: Matías Costa <mcc3@alu.um.es>

Date: Fri, 18 Feb 2005 16:03:03 UTC

Severity: normal

Tags: patch

Merged with 280551

Found in versions 2.5.28-2.0.1, 2.5.28-2

Fixed in version mldonkey/2.5.28.1-1

Done: Sylvain Le Gall <sylvain.le-gall@polytechnique.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Sylvain Le Gall <sylvain.le-gall@polytechnique.org>:
Bug#295854; Package mldonkey-server. (full text, mbox, link).


Acknowledgement sent to Matías Costa <mcc3@alu.um.es>:
New Bug report received and forwarded. Copy sent to Sylvain Le Gall <sylvain.le-gall@polytechnique.org>. (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: Matías Costa <mcc3@alu.um.es>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: mldonkey-server: Remove lost pid file
Date: Fri, 18 Feb 2005 17:01:04 +0100
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.

-- System Information:
Debian Release: 3.1
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: i386 (i686)
Kernel: Linux 2.6.10-1-k7
Locale: LANG=es_ES.UTF-8, LC_CTYPE=es_ES.UTF-8 (charmap=UTF-8) (ignored: 
LC_ALL set to es_ES.UTF-8)

Versions of packages mldonkey-server depends on:
ii  adduser                3.59         Add and remove users and groups
ii  debconf [debconf-2.0]  1.4.41       Debian configuration management sy
ii  libc6                  2.3.2.ds1-19 GNU C Library: Shared libraries an
ii  mime-support           3.28-1       MIME files 'mime.types' & 'mailcap
ii  ucf                    1.13         Update Configuration File: preserv
ii  zlib1g                 1:1.2.2-4    compression library - runtime

-- debconf information excluded



Information forwarded to debian-bugs-dist@lists.debian.org, Sylvain Le Gall <sylvain.le-gall@polytechnique.org>:
Bug#295854; Package mldonkey-server. (full text, mbox, link).


Acknowledgement sent to "Sylvain LE GALL" <sylvain.le-gall@polytechnique.org>:
Extra info received and forwarded to list. Copy sent to Sylvain Le Gall <sylvain.le-gall@polytechnique.org>. (full text, mbox, link).


Message #10 received at 295854@bugs.debian.org (full text, mbox, reply):

From: "Sylvain LE GALL" <sylvain.le-gall@polytechnique.org>
To: Matías Costa <mcc3@alu.um.es>, 295854@bugs.debian.org
Subject: Re: Bug#295854: mldonkey-server: Remove lost pid file
Date: Fri, 18 Feb 2005 22:20:07 +0100
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



Severity set to `normal'. Request was from "Sylvain LE GALL" <sylvain.le-gall@polytechnique.org> to control@bugs.debian.org. (full text, mbox, link).


Merged 280551 295854. Request was from "Sylvain LE GALL" <sylvain.le-gall@polytechnique.org> to control@bugs.debian.org. (full text, mbox, link).


Reply sent to Sylvain Le Gall <sylvain.le-gall@polytechnique.org>:
You have taken responsibility. (full text, mbox, link).


Notification sent to Matías Costa <mcc3@alu.um.es>:
Bug acknowledged by developer. (full text, mbox, link).


Message #19 received at 295854-close@bugs.debian.org (full text, mbox, reply):

From: Sylvain Le Gall <sylvain.le-gall@polytechnique.org>
To: 295854-close@bugs.debian.org
Subject: Bug#295854: fixed in mldonkey 2.5.28.1-1
Date: Mon, 05 Sep 2005 16:02:07 -0700
Source: mldonkey
Source-Version: 2.5.28.1-1

We believe that the bug you reported is fixed in the latest version of
mldonkey, which is due to be installed in the Debian FTP archive:

mldonkey-gui_2.5.28.1-1_i386.deb
  to pool/main/m/mldonkey/mldonkey-gui_2.5.28.1-1_i386.deb
mldonkey-server_2.5.28.1-1_i386.deb
  to pool/main/m/mldonkey/mldonkey-server_2.5.28.1-1_i386.deb
mldonkey_2.5.28.1-1.diff.gz
  to pool/main/m/mldonkey/mldonkey_2.5.28.1-1.diff.gz
mldonkey_2.5.28.1-1.dsc
  to pool/main/m/mldonkey/mldonkey_2.5.28.1-1.dsc
mldonkey_2.5.28.1.orig.tar.gz
  to pool/main/m/mldonkey/mldonkey_2.5.28.1.orig.tar.gz



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 295854@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Sylvain Le Gall <sylvain.le-gall@polytechnique.org> (supplier of updated mldonkey package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.7
Date: Tue, 30 Aug 2005 11:36:02 +0200
Source: mldonkey
Binary: mldonkey-gui mldonkey-server
Architecture: source i386
Version: 2.5.28.1-1
Distribution: unstable
Urgency: low
Maintainer: Sylvain Le Gall <sylvain.le-gall@polytechnique.org>
Changed-By: Sylvain Le Gall <sylvain.le-gall@polytechnique.org>
Description: 
 mldonkey-gui - Graphical frontend for mldonkey based on GTK
 mldonkey-server - Door to the 'donkey' network
Closes: 225724 231553 270283 271462 271725 271727 273156 276750 276751 277772 279030 280073 281086 283930 284556 285231 291451 295854 296573 299722 300547 300560 312370 312824
Changes: 
 mldonkey (2.5.28.1-1) unstable; urgency=low
 .
   * New upstream version:
     * Fix LOWID protocol error with ed2k (Upstream: #3415,
       Debian closes: #284556, #280073)
   * Transition to ocaml 3.08.3: changes depends in control
   * Remove patch 18_utf8_encoding since it is applied upstream
   * Remove patch 19_mlgui_align since it is applied upstream
   * Depend on docbook-xsl 1.64.1 and docbook-xml 4.2-12
     (Closes: #276750, #276751)
   * Change MDLONKEY_DIR to MLDONKEY_DIR at line 34 in the init.d file
     (Closes: #296573, #273156)
   * Create a command "force-start" to force the start of mldonkey, even if it
     is configured not to start at startup. All other command don't take into
     account the value of the variable ( so you can stop or restart a running
     server, without knowing how it was started )
     (Closes: #225724)
   * Depend on dpkg 1.10.27, so that we can rely on --nicelevel doing what we
     think it does. Put a note for backporters in README.Debian
     (Closes: #277772)
   * Add german debconf translation. Thanks to Jens Nachtigall
     (Closes: #271727)
   * Update czech debconf translation. Thanks to Jan Outrata
     (Closes: #271462)
   * Add vietnamese debconf translatio. Thanks to Clytie Siddall
     (Closes: #312824)
   * Apply patches to improve the debconf templates. Thanks to Jens Nachtigall
     (Closes: #270283)
   * Change license of manpages to LGPL v2.1
     (Closes: #281086)
   * Add "debconf-updatepo" in the target clean of debian/rules to be sure to
     be in sync for the translation
     (Closes: #271725)
   * Add a note about the fact that mldonkey cannot use all the group assigned
     to user mldonkey due to OCaml limitation in README.Debian, explain how to
     deal with this issue
   * Create a patch to correct comments in the initial downloads.ini:
     20_wrong_comments
     (Closes: #285231)
   * Cannot find cache.shareaza.com in the source. This seems to be present in
     release 2.5.4 but it is no more present.
     (Closes: #231553)
   * Added script mldonkey_create_chroot and its manpage, thanks to Mick
     Kappenburg for his contribution
   * Modify mldonkey_server:
     * Add an option to configure the group that should be used when running
       mldonkey.
     * Add an option to configure the niceness of the process
     * Add sanity check :
       * Check for stale pidfile
         (Closes: #295854)
       * Check for good permission/owner/group of files used by mldonkey. After
         better reading the patch provided in bugs 299722, i decided to replace
         a "simple" reowning of the pidfile by a complete check of permission
         and ownership. Reowning a file is not as simple as it looks like. We
         should take care of "dpkg-statoverride" et al. Moreover, i don't want
         to autoset things in the init script. If the ownership/permission of
         files are not good, there should be a real problem (as a standard
         install should set the good permission). I don't try to hide these
         problem by doing fix in the init script: i just warn the user.
         (Closes: #299722).
       * Check for stale .tmp file
         (Closes: #283930)
     * Update the manual page according to these changes.
   * Correct the way you can change password in README.Debian, thanks to
     Spiralvoice.
     (Closes: #312370)
   * Doesn't offer the possibility to keep the server running after upgrade:
     this option can cause a lot of problems (version mismatch between server
     and gui).
     (Closes: #300547)
   * Use Int64 to store integer extracted from ini files, in mldonkey_files.
     This is more compliant with the way mldonkey write this value in his ini
     files.
     (Closes: #291451)
   * Modify priority of the debconf question :
     * to priority low: run_as_user, mldonkey_group, mldonkey_umask,
       mldonkey_niceness, max_alive
     * to priority medium: mldonkey_dir (reasonable default, but are system
       specific most of the time), client_name (reasonnable default, but most
       of the time are changed by user),
     * to priority critical: reown_file (because the server cannot restart if
       the file permission are not changed),
     * So now, configuring the system with priority high only ask you 3
       question, with priority medium only 8 question.
   * Doesn't distribute anymore /etc/default/mldonkey-server. So this file is
     not automatically marked as conffile, allowing to manage it through ucf
     (Closes: #279030):
     * save the default from this file to debconf in the preinst script,
     * move mldonkey-server to mldonkey-server.bak in the preinst script,
     * generate mldonkey-server and manage it using ucf (at the same place, but
       using ucf).
     * add a note into NEWS.Debian to state this change
   * Applied patches #3919 from upstream to correct file permission, generates
     password in users.ini rather than in downloads.ini (this separation is the
     new security scheme, the file users.ini has 600 permission)
     (Closes: #300560)
   * Fix the problem of invoke-rc.d creating a defunct process: i need to stop
     the debconf module (using db_stop in postinst)
   * Enhance mldonkey_files: add the command test, to check if some source are
     from specified network (eg fasstrack).
   * Move the fasttrack split from /etc/init.d/mldonkey-server to
     mldoney-server.postinst.
   * Enhance mldonkey_users: add the command dump-users-section,
     strip-users-section and test-users-section, to extract users section from
     download.ini and place it in users.ini.
   * Create users.in out of downloads.ini using mldonkey_users in
     mldonkey-server.postinst.
   * Transition to svn-buildpackage
   * Reformat the changelog to be sure to have less than 80 characters by line.
   * [JvW] Add mldonkey start init.d script at 98, not as early as the default
     location of 20.
Files: 
 94f9b29d38edfae19388fb53175bfb74 860 net optional mldonkey_2.5.28.1-1.dsc
 8b315030b36b706ee692993f16884b94 3250049 net optional mldonkey_2.5.28.1.orig.tar.gz
 4fbdf5b5bfd9672d628420d2616cc0f4 337930 net optional mldonkey_2.5.28.1-1.diff.gz
 2297c54e24db47797ac3b968466c5d08 2370174 net optional mldonkey-server_2.5.28.1-1_i386.deb
 dfbb1bc15e713aa3e4887de19338d5dc 2664064 net optional mldonkey-gui_2.5.28.1-1_i386.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Signed by Jeroen van Wolffelaar <jeroen@wolffelaar.nl>

iD8DBQFDHMqHl2uISwgTVp8RAj6DAKCfXQBRrvIhMIYHprKdDDZoK1xvwACfU8/+
COMJmalVQAF43PIzKw65++8=
=xtvV
-----END PGP SIGNATURE-----




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Mon, 25 Jun 2007 23:31:03 GMT) (full text, mbox, link).


Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Sat Nov 25 04:20:08 2023; Machine Name: buxtehude

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.