Your message dated Fri, 14 Jan 2011 18:37:20 +0100
with message-id <[email protected]>
and subject line
has caused the Debian Bug report #374669,
regarding checkinstall: 'rm -rf' hangs in Makefile if target directory contains
more than 200 files
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
374669: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=374669
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: checkinstall
Version: 1.6.0-1
Severity: normal
I have been trying to build GNU Emacs from CVS and make a package
using checkinstall. checkinstall is hanging forever while running 'rm
-fr'. I have managed to reproduce the bug - it seems to happen
whenever rm tries to remove a directory of 201 or more files. In the
following example I mkdir a directory 'tmpdir' containing 201 empty
files, then make a directory 'tmpdir2' containing a very simple
Makefile. I run 'sudo checkinstall' in 'tmpdir2' and it hangs on the
'rm' command. I show that the newfiles.tmp file grows constantly, and
show that it is filling up with '#No such file or directory' messages.
Note that when I make the Makefile in ~ and run checkinstall from
there, rather than making it in ~/tmpdir2 and running checkinstall
from there, the problem doesn't happen.
------------------------------------------------------------------------
(sid) chris@chrislap:~$ cd
(sid) chris@chrislap:~$ pwd
/home/chris
(sid) chris@chrislap:~$ ls -ld tmpdir*
ls: tmpdir*: No such file or directory
(sid) chris@chrislap:~$ mkdir tmpdir
(sid) chris@chrislap:~$ i=1; while ((i<202)); do touch
/home/chris/tmpdir/$i; ((i=i+1)); done
(sid) chris@chrislap:~$ ls tmpdir | wc -l
201
(sid) chris@chrislap:~$ mkdir tmpdir2
(sid) chris@chrislap:~$ cd tmpdir2
/home/chris/tmpdir2
(sid) chris@chrislap:~/tmpdir2$ printf "install:\n\trm -fr
/home/chris/tmpdir\n" > Makefile
(sid) chris@chrislap:~/tmpdir2$ cat Makefile
install:
rm -fr /home/chris/tmpdir
(sid) chris@chrislap:~/tmpdir2$ sudo checkinstall -y
checkinstall 1.6.0, Copyright 2002 Felipe Eduardo Sanchez Diaz Duran
This software is released under the GNU GPL.
The package documentation directory ./doc-pak does not exist.
Should I create a default set of package docs? [y]: y
Preparing package documentation...OK
*** No known documentation files were found. The new package
*** won't include a documentation directory.
*****************************************
**** Debian package creation selected ***
*****************************************
This package will be built according to these values:
0 - Maintainer: [ root@chrislap ]
1 - Summary: [ Package created with checkinstall 1.6.0 ]
2 - Name: [ tmpdir2 ]
3 - Version: [ 20060620 ]
4 - Release: [ 1 ]
5 - License: [ GPL ]
6 - Group: [ checkinstall ]
7 - Architecture: [ i386 ]
8 - Source location: [ tmpdir2 ]
9 - Alternate source location: [ ]
10 - Requires: [ ]
Enter a number to change any of them or press ENTER to continue:
Installing with make install...
========================= Installation results
===========================
rm -fr /home/chris/tmpdir
*** at this point the command hang - I hit control-z to stop it and put it into
the background ***
[1]+ Stopped sudo checkinstall -y
(sid) chris@chrislap:~/tmpdir2$ bg
[1]+ sudo checkinstall -y &
(sid) chris@chrislap:~/tmpdir2$ ps -ef | grep 'rm -fr'
root 24981 24980 85 16:39 pts/5 00:00:16 rm -fr
/home/chris/tmpdir
chris 24992 21597 0 16:39 pts/5 00:00:00 grep rm -fr
(sid) chris@chrislap:~/tmpdir2$ sudo ls -l /proc/24981/fd | grep /var
lr-x------ 1 root root 64 2006-06-20 16:40 4 ->
/var/tmp/JErNeZYSrkgcAlQeaoSq/META/DIRLS/24981_776_179687
(sid) chris@chrislap:~/tmpdir2$ sudo ls -l
/var/tmp/JErNeZYSrkgcAlQeaoSq/newfiles.tmp
-rw-r--r-- 1 root root 17783709 2006-06-20 16:40
/var/tmp/JErNeZYSrkgcAlQeaoSq/newfiles.tmp
(sid) chris@chrislap:~/tmpdir2$ sudo ls -l
/var/tmp/JErNeZYSrkgcAlQeaoSq/newfiles.tmp
-rw-r--r-- 1 root root 18735007 2006-06-20 16:40
/var/tmp/JErNeZYSrkgcAlQeaoSq/newfiles.tmp
(sid) chris@chrislap:~/tmpdir2$ tail
/var/tmp/JErNeZYSrkgcAlQeaoSq/newfiles.tmp
tail: cannot open `/var/tmp/JErNeZYSrkgcAlQeaoSq/newfiles.tmp' for
reading: Permission denied
(sid) chris@chrislap:~/tmpdir2$ sudo tail -1000
/var/tmp/JErNeZYSrkgcAlQeaoSq/newfiles.tmp | sort | uniq -c | sort -n | tail
5 -1 unlink /home/chris/tmpdir/91 #No such file or
directory
5 -1 unlink /home/chris/tmpdir/92 #No such file or
directory
5 -1 unlink /home/chris/tmpdir/93 #No such file or
directory
5 -1 unlink /home/chris/tmpdir/94 #No such file or
directory
5 -1 unlink /home/chris/tmpdir/95 #No such file or
directory
5 -1 unlink /home/chris/tmpdir/96 #No such file or
directory
5 -1 unlink /home/chris/tmpdir/97 #No such file or
directory
5 -1 unlink /home/chris/tmpdir/98 #No such file or
directory
5 -1 unlink /home/chris/tmpdir/99 #No such file or
directory
5 -1 unlink /home/chris/tmpdir/9 #No such file or
directory
(sid) chris@chrislap:~/tmpdir2$ sudo wc -l
/var/tmp/JErNeZYSrkgcAlQeaoSq/newfiles.tmp
581819 /var/tmp/JErNeZYSrkgcAlQeaoSq/newfiles.tmp
(sid) chris@chrislap:~/tmpdir2$ sudo wc -l
/var/tmp/JErNeZYSrkgcAlQeaoSq/newfiles.tmp
590494 /var/tmp/JErNeZYSrkgcAlQeaoSq/newfiles.tmp
(sid) chris@chrislap:~/tmpdir2$ fg
sudo checkinstall -y
make: *** [install] Interrupt
*** SIGINT received ***
Cleaning up...OK
Bye.
(sid) chris@chrislap:~/tmpdir2$
------------------------------------------------------------------------
Here's the same test case, but with 200 files, instead of 201.
Notice now that the "rm -fr" line is immediately followed by
"installation successful" - ie. it doesn't hang any more:
------------------------------------------------------------------------
(sid) chris@chrislap:~$ /bin/rm -fr tmpdir*
(sid) chris@chrislap:~$ mkdir tmpdir
(sid) chris@chrislap:~$ i=1; while ((i<201)); do touch
/home/chris/tmpdir/$i; ((i=i+1)); done
(sid) chris@chrislap:~$ mkdir tmpdir2
(sid) chris@chrislap:~$ cd tmpdir2
/home/chris/tmpdir2
(sid) chris@chrislap:~/tmpdir2$ printf "install:\n\trm -fr
/home/chris/tmpdir\n" > Makefile
(sid) chris@chrislap:~/tmpdir2$ sudo checkinstall -y
[...]
Installing with make install...
========================= Installation results
===========================
rm -fr /home/chris/tmpdir
======================== Installation successful
==========================
*** at this point I hit control-c, since the 'rm' had completed successfully ***
*** SIGINT received ***
Cleaning up...OK
Bye.
(sid) chris@chrislap:~/tmpdir2$
------------------------------------------------------------------------
-- System Information:
Debian Release: testing/unstable
APT prefers unstable
APT policy: (500, 'unstable')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.16-2-686
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Versions of packages checkinstall depends on:
ii file 4.17-2 Determines file type using "magic"
ii findutils 4.2.27-3 utilities for finding files--find,
ii libc6 2.3.6-15 GNU C Library: Shared libraries
checkinstall recommends no packages.
-- no debconf information
--- End Message ---
--- Begin Message ---
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
Version: 1.6.2-1
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
iQIcBAEBCAAGBQJNMInLAAoJELRG7qgympRaep0QALsZIvAd99s2QiU+T6lBRuxN
svTeGsGP/of+TpreZxuy2uuDElxQqmVNE6w0p/mrZuquO4Vs5jApLSxV/ngCidMs
pmyhNHWTye6tDRLuMEtSvHaRcI3KbEePt0HmxsRnbk9KBC0ywvHhzyH/lClyEP9L
sKlfU+eQRWaBJl0Q+a0LYzx9+NruzVdgO3hl24XMwHrUKTSTyadTCIvwzoOoGupt
QjxD0COKuXMbQg/flvTMRyICvAvF8Zq6QnkvcmsBfwMi/r+pIsi7z7RCyerQhF0j
pSBJOaJ9NGTpuNtFqsmsYLgT9ZQAPRpfHhe9egjhnG3XPX0hAboDGw6IHRvVbbq3
D62EO5EcqBy7ZYaJkwgR6nplZOq1D3her0rSBPEJrcHssoFCF7nKMMdK/DRJxRch
0LOXh4cn791KiMpr9jViz5QoL4Jm17gLQLfLWZQMs9/wmROyP/Mg9U5KqHJGZR9v
sof74XTqvl4IG32UppEWb8rY3WSDhQVl0x5CpaoZeAuQmijLHYWArNq9qMDfalFS
iCFDn41q1P955LWR2fKOfTNxUUAUe5ZLzOZR23Rcpf+oONUKaAdsGAO/ZdTydbcm
joSNBk3fQOr7+p2qDjhbsX0LzZRP+ve0cnsjIhHtfki8Gjxx5umUd9NLsFumqS6V
o7vk+ujeGSiOQimeGHxO
=OYOV
-----END PGP SIGNATURE-----
--- End Message ---