[lkml]   [1996]   [Apr]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: loop/mount - was: Re: /proc/misc has bad mode
Hi, wrote:
> I patched my loopback device and my mount binary
> so that closing or unmounting /dev/loop? automatically
> disassociates the device from the file.
>No patch required, that is the default behaviour of the current mount.

No, that's the default behavior of the current umount. That behavior
currently depends on a correct /etc/mtab, though presumably it could do a
stat() on the mount point instead, and find the loop device that way.

We can do things either way, of course, but I do like my way better.
Umount should be able to undo whatever it is mount does by doing a simple
umount(2) system call.

Consider am "emergency" reboot, for instance because something killed the
root partition (these things happen, you know) or because a power failure
is immanent and some process failed to shutdown in an orderly manner
(happens too).
The fast way is to kill all processes, turn off all swap, and unmount
everything in /proc/mounts in reverse order. Easy. But not at all easy if
umount must do special things for some file systems. It shouldn't have to.

You will meet a gin-soaked bar-room queen in Memphis.
Matthias Urlichs \ Noris Network GmbH i.Gr/ Xlink-POP Nürnberg
Schleiermacherstraße 12 \ Linux+Internet / EMail:
90491 Nürnberg (Germany) \ Consulting+Programming+Networking+etc'ing
PGP: 1B 89 E2 1C 43 EA 80 44 15 D2 29 CF C6 C7 E0 DE
Click <A HREF="">here</A>. 42

 \ /
  Last update: 2005-03-22 13:37    [W:0.025 / U:2.592 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site