:: Re: [DNG] I've got the automounter …
Startseite
Nachricht löschen
Nachricht beantworten
Autor: Didier Kryn
Datum:  
To: dng
Betreff: Re: [DNG] I've got the automounter running
Le 28/12/2015 03:03, Steve Litt a écrit :
> Hi all,
>
> I have the automounter running, incompletioncies and all. It's running
> off of Runit, but I'm sure it would work with sysvinit or /etc/rc.local
> or pretty much anything else.
>
> Assuming you don't actually edit anything, when you plug in a thumb
> drive, all its partitions open within 5 seconds (usually quicker), as
> evidenced by my Thunar file manager. When I pull it out, the mounts go
> away and the mountpoints are deleted.
>
> I'm sure there are a dozen edge cases and a couple corner cases where
> it doesn't work in a desireable manner. I found one, when I yank the
> thumb drive while a file on it is still being edited. I'll fix that.
>
> It's got zillions of diagnostic prints left in it: Those must go or
> they'll end up in everyone's logs.
>
> Also, this program needs a companion program that identifies, and
> perhaps umounts, partitions by label or by whatever else.
>
> Finally, I'd prefer this program run as a user other than root (which
> it's doing right now).
>
> But the good thing is, it's working, and IMHO it's working faster and
> more reliably than at least half the automounting addons, packaged with
> filemanagers, that I've tried..
>
>


     Congratulations, Steve.


     There remains a fundamental problem with automatic mount/umount. 
While automounting is safe, auto-unmounting is not if it is triggered by 
device removal. Unmounting must be done *before* removing the device if 
anything has been written to it, otherwise data is lost and the 
filesystem may be corrupted; also running applications with open files 
in the mountpoint can broken.


     Didier