ufs freeze does not work

Mateusz Guzik mjguzik at gmail.com
Tue Jun 28 19:57:39 UTC 2016


On Tue, Jun 28, 2016 at 08:55:23PM +0200, Edward Tomasz Napierała wrote:
> As I said, the suspension is released when the ufssuspend file descriptor
> gets closed - which is what happens when the calling process exits.  It's
> a protection mechanism, to avoid the situation where the process malfunction
> (eg a crash) would leave the system in unrecoverable (suspended) state.
> 
> You probably want your process to just execute another one, and wait until
> it exits.
> 

The example with freeze -f strongly hints this is supposed to work as a
drop in replacement for linux scripts.

As such, maybe ufs should grow another operation which does not
automagically unfreeze.


> On 0628T0733, Hongjiang Zhang wrote:
> > I run "./freeze -f", the program should freeze the "/" file partition, but I can still write something to "/tmp" folder.
> > 
> > -----Original Message-----
> > From: Edward Tomasz Napierała [mailto:etnapierala at gmail.com] On Behalf Of Edward Tomasz Napierala
> > Sent: Tuesday, June 28, 2016 2:55 PM
> > To: Hongjiang Zhang <honzhan at microsoft.com>
> > Cc: freebsd-fs at freebsd.org
> > Subject: Re: ufs freeze does not work
> > 
> > On 0627T0815, Hongjiang Zhang via freebsd-fs wrote:
> > > Hi all,
> > > 
> > > I wrote a test to freeze ufs, but it does not work even if the ioctl returns successful. What is the problem?
> > 
> > What do you mean by 'does not work'?  What happens, and what did you expect to happen?
> > 
> > Regarding your example - remember that the filesystem gets automatically unsuspended as soon as you close the /dev/ufssuspend file descriptor.
> > 
> _______________________________________________
> freebsd-fs at freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-fs
> To unsubscribe, send any mail to "freebsd-fs-unsubscribe at freebsd.org"

-- 
Mateusz Guzik <mjguzik gmail.com>


More information about the freebsd-fs mailing list