The symptom was umount2 couldn't unmount /usr. We added a  diagnostic 
mod to  /etc/rc.d/init.d/halt.  Adding a call to /sbin/fuser to find the offending 
pid(s) and then to /sbin/lsof to see exactly what files were preventing the 
umount we got:

COMMAND  PID USER   FD       TYPE DEVICE     SIZE   NODE NAME
    ... bunch of irrelevant stuff snipped ....
S01halt 1065 root    3r   REG    3,3 30306528 214860
/usr/lib/locale/locale-archive S01halt 1065 root  255r   REG    3,7   
 5575  96095 /etc/rc.d/init.d/halt

The file /etc/rc.d/init.d/halt incorporates /etc/rc.d/init.d/functions. The /usr 
locale file turned out to be called up by /etc/rc.d/init.d/functions in the line 
which goes something like this: 
   if [ -f /etc/sysconfig/i18n ]   ..... <do locale stuff>

Somehow I had installed i18n (the international set). In the spirit of 
adventure, I renamed /etc/sysconfig/i18n to /etc/sysconfig/i18n.notnow. 

Several hot and cold reboots (with my rescue disk handy) indicated  that the 
original symptom was fixed with no degradation of other programs after 
renaming the i18n file.  

This is certainly not the only way you can end up with  umount2 errors
in RH or any other distribution. The error mesage you get is rather ..er.. 
terse (although it is definitely better than "Unknown Vxd Error: Windows Will 
Close Now"). 

If your filesystems are ext3, you may not suffer much of an annoyance.
However, ext2 will run a <lengthy> fsck on the errant mount on the next 
boot, and it is unlikely that you won't notice it. 

Here is one possible diagnostic mod to  /etc/rc.d/init.d/halt (this one 
assumes there is only one errant mount . Make a copy of /etc/rc.d/init.d/halt 
before making this mod . Similar code works for me, your mileage may  
vary.) : 

    ..............<snip>
    fi
    sleep 8
    remaining=`halt_get_remaining |sort -r`
+       garbage=`/sbin/fuser -m $remaining |awk -F: ' {print $2}'`
+       echo $garbage
+       for entries in $garbage; do
+               entry=`echo $entries |sed  s/[a-z]//`
+               echo "PID: " $entry
+               /sbin/lsof -p $entry |grep $remaining
+               ps ax |grep $entry | grep -v grep;
+       done
    /sbin/fuser -k -m $remaining > /dev/null
    sleep 5
      ............<snip> .



-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]?subject=unsubscribe
https://listman.redhat.com/mailman/listinfo/redhat-list

Reply via email to