January 25, 2010

This is as much for my own reference as anything else. Occasionally we have problems with NFS servers going AWOL and this can leave broken mounts which are impossible to properly remove. This would not be too much of a problem if it wasn’t for the fact that rpm checks every file system before it starts doing anything. I guess this is to look for disk space or read-only partitions, I’m not convinced this is the job of a package manager but… If an NFS mount is broken then rpm will hang indefinitely, if you run rpm every night then you soon get lots of hung rpm commands that need clearing out. The trick is to kill all the running rpm commands then use the ‘-f’ and ‘-l’ options on umount, (this results in it being invisible to the RPM command) then run rpm again and all is well.