<div>I found that the link to bootmisc.sh in /etc/rcS.d/ is S19bootmisc.sh , and the link to  mountnfs-bootclean.sh in /etc/rcS.d/ is S46mountnfs-bootclean.sh, that means bootmisc.sh is called before calling mountnfs-bootclean.sh and it remove the /var/run/.clean file, </div>
<div></div><div>By default in debian,  the link to bootmisc.sh in /etc/rcS.d/ shuould be S55bootmisc.sh, which accidently modified by some package in my box. (maybe by upstart, I&#39;ve ever test it) <br></div><div></div>
<div>Thanks, </div><div></div><div></div><div>following is the links in my /etc/rcS.d directory: </div><div></div><div>lrwxrwxrwx   1 root root    18 2007-09-23 S01glibc.sh -&gt; ../init.d/glibc.sh<br>lrwxrwxrwx   1 root root    21 2007-09-23 S02hostname.sh -&gt; ../init.d/hostname.sh<br>
lrwxrwxrwx   1 root root    24 2008-08-11 S03mountkernfs.sh -&gt; ../init.d/mountkernfs.sh<br>lrwxrwxrwx   1 root root    14 2008-08-11 S04udev -&gt; ../init.d/udev<br>lrwxrwxrwx   1 root root    26 2008-08-11 S05mountdevsubfs.sh -&gt; ../init.d/mountdevsubfs.sh<br>
lrwxrwxrwx   1 root root    19 2008-08-11 S06keymap.sh -&gt; ../init.d/keymap.sh<br>lrwxrwxrwx   1 root root    18 2008-08-11 S07bootlogd -&gt; ../init.d/bootlogd<br>lrwxrwxrwx   1 root root    24 05-02 13:47 S07keyboard-setup -&gt; ../init.d/keyboard-setup<br>
lrwxrwxrwx   1 root root    14 06-04 17:45 S07lvm2 -&gt; ../init.d/lvm2<br>lrwxrwxrwx   1 root root    21 2008-08-11 S07pcmciautils -&gt; ../init.d/pcmciautils<br>lrwxrwxrwx   1 root root    16 2008-08-11 S07procps -&gt; ../init.d/procps<br>
lrwxrwxrwx   1 root root    22 2008-08-11 S08checkroot.sh -&gt; ../init.d/checkroot.sh<br>lrwxrwxrwx   1 root root    25 08-11 23:57 S08hwclockfirst.sh -&gt; ../init.d/hwclockfirst.sh<br>lrwxrwxrwx   1 root root    24 2008-08-11 S09ifupdown-clean -&gt; ../init.d/ifupdown-clean<br>
lrwxrwxrwx   1 root root    27 2008-08-11 S09module-init-tools -&gt; ../init.d/module-init-tools<br>lrwxrwxrwx   1 root root    17 2008-08-11 S09mtab.sh -&gt; ../init.d/mtab.sh<br>lrwxrwxrwx   1 root root    19 2008-08-11 S09udev-mtab -&gt; ../init.d/udev-mtab<br>
lrwxrwxrwx   1 root root    20 06-04 17:45 S10checkfs.sh -&gt; ../init.d/checkfs.sh<br>lrwxrwxrwx   1 root root    20 08-11 23:57 S11hwclock.sh -&gt; ../init.d/hwclock.sh<br>lrwxrwxrwx   1 root root    21 06-04 17:45 S11mountall.sh -&gt; ../init.d/mountall.sh<br>
lrwxrwxrwx   1 root root    24 06-04 17:45 S11selinux-basics -&gt; ../init.d/selinux-basics<br>lrwxrwxrwx   1 root root    31 06-04 17:45 S12mountall-bootclean.sh -&gt; ../init.d/mountall-bootclean.sh<br>lrwxrwxrwx   1 root root    19 06-04 17:45 S14dns-clean -&gt; ../init.d/dns-clean<br>
lrwxrwxrwx   1 root root    14 06-04 17:45 S14fuse -&gt; ../init.d/fuse<br>lrwxrwxrwx   1 root root    20 06-04 17:45 S14lm-sensors -&gt; ../init.d/lm-sensors<br>lrwxrwxrwx   1 root root    25 06-04 17:45 S14policycoreutils -&gt; ../init.d/policycoreutils<br>
lrwxrwxrwx   1 root root    18 06-04 17:45 S14pppd-dns -&gt; ../init.d/pppd-dns<br>lrwxrwxrwx   1 root root    20 06-04 17:45 S14resolvconf -&gt; ../init.d/resolvconf<br>lrwxrwxrwx   1 root root    17 06-04 17:45 S14urandom -&gt; ../init.d/urandom<br>
lrwxrwxrwx   1 root root    20 06-04 17:45 S14x11-common -&gt; ../init.d/x11-common<br>lrwxrwxrwx   1 root root    18 06-04 17:45 S15ifupdown -&gt; ../init.d/ifupdown<br>lrwxrwxrwx   1 root root    20 06-04 17:45 S16networking -&gt; ../init.d/networking<br>
lrwxrwxrwx   1 root root    20 06-04 17:45 S19alsa-utils -&gt; ../init.d/alsa-utils<br>lrwxrwxrwx   1 root root    23 06-04 17:45 S19console-setup -&gt; ../init.d/console-setup<br>lrwxrwxrwx   1 root root    26 06-04 17:45 S19libdevmapper1.02 -&gt; ../init.d/libdevmapper1.02<br>
lrwxrwxrwx   1 root root    24 06-04 17:45 S19screen-cleanup -&gt; ../init.d/screen-cleanup<br>lrwxrwxrwx   1 root root    30 06-04 17:45 S20stop-bootlogd-single -&gt; ../init.d/stop-bootlogd-single<br>lrwxrwxrwx   1 root root    18 07-17 01:34 S30ebtables -&gt; ../init.d/ebtables<br>
lrwxrwxrwx   1 root root    26 08-12 00:02 S37mountoverflowtmp -&gt; ../init.d/mountoverflowtmp<br>lrwxrwxrwx   1 root root    21 06-27 11:06 S45mountnfs.sh -&gt; ../init.d/mountnfs.sh<br>lrwxrwxrwx   1 root root    31 08-12 00:02 S46mountnfs-bootclean.sh -&gt; ../init.d/mountnfs-bootclean.sh<br>
lrwxrwxrwx   1 root root    21 06-04 17:45 S55bootmisc.sh -&gt; ../init.d/bootmisc.sh<br>lrwxrwxrwx   1 root root    19 06-23 23:23 S75policykit -&gt; ../init.d/policykit<br>lrwxrwxrwx   1 root root    14 08-12 00:13 S75sudo -&gt; ../init.d/sudo<br>
<br><br></div><br><div class="gmail_quote">2009/7/24 Petter Reinholdtsen <span dir="ltr">&lt;<a href="mailto:pere@hungry.com">pere@hungry.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
tags 537394 - patch<br>
thanks<br>
<br>
Do not see the patch, so I remove the patch flag.<br>
<br>
[Alan Guo]<br>
<div class="im">&gt; For /etc/rcS.d/S12mountall-bootclean.sh cleans /tmp , /var/lock and<br>
&gt; /var/run, I think it is not nessary<br>
&gt; /etc/rcS.d/S46mountnfs-bootclean.sh cleanning /tmp, /var/lock,<br>
&gt; /var/run once again, so I report this bug as a initscripts bug<br>
<br>
</div>The question is really why it is cleaning it twice.  The clean jobs<br>
should log for the flag file .clean, and skip the cleaning if the file<br>
exist (and create it after the first cleaning if it does not).<br>
<br>
Any idea why this isn&#39;t happening on your system?<br>
<br>
Happy hacking,<br>
--<br>
<font color="#888888">Petter Reinholdtsen<br>
</font></blockquote></div><br><br clear="all"><br>-- <br>Alan Guo<br><a href="http://bluestone.cublog.cn">http://bluestone.cublog.cn</a><br>