/etc/mtab vs. /proc/self/mounts
I was reading through the man page for mount today, and noticed in the section about using the loop device that it's recommended to make /etc/mtab a symlink to /proc/mounts in order for umount to automatically free loop devices. Now I shut down every night and rarely use the loop device, but I'm also somewhat pedantic and would rather have things just right.
Now /proc/mounts is a symlink to /proc/self/mounts, so to follow the mount man page recommendation properly /etc/mtab should point there instead, but on examining the contents of both those files there are several minor differences: Code:
bash-3.00# cat /etc/mtab Code:
bash-3.00# cat /proc/self/mounts |
Re: /etc/mtab vs. /proc/self/mounts
Quote:
This way from what you see in your example you lose some information about mounting. That is why the man page mention you won't be able to umount automatically loop devices. you will have to do "losetup -d /dev/loopX" I used /proc/mounts for a long time and didn't notice any "problem" other than the loop umounting (which is annoying if you use it frequently) |
All times are GMT -5. The time now is 02:09 PM. |