[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: tomorrows rawhide kernel.



On Sat, Aug 13, 2005 at 01:10:40AM -0500, Michel Alexandre Salim wrote:
 > On Fri, 2005-08-12 at 23:57 -0400, Dave Jones wrote:
 > > As the rawhide kernel has been pretty boring and uneventful
 > > so far, this last day or two, Jeremy Katz and I managed to
 > > beat suspend to disk support into shape.
 > > 
 > [snip]
 > 
 > > 1. Make sure you have a swap partition.
 > > (if you have >1, it'll only use the first one, so make sure
 > >  its at least as big as your RAM).  Whilst suspend does evict
 > >  some non-essential things from memory before it suspends,
 > >  it can still end up with quite a bit to write out.
 > > 
 > Great! It works with swap-on-LVM, I assume?

Worked for me :-)

 > > - *NEVER*, *EVER*, write into /sys/power/resume after you've booted.
 > > This is going to have to be made safe at some point. Right now, doing
 > > that whilst you've got partitions mounted is a guaranteed way to say
 > > goodbye to some files.  The good news, is that this is the only
 > > way I've found so far to corrupt data.
 > > 
 > Could this be done with unionfs, I wonder? Layer a branch that contains
 > an immutable /sys/power/resume on top of the real /sys.


Actually, this should be a non-issue 99% of the time.
Once you've booted, the resume partition will be turned back
into a swap partition, so echoing anything there will try to
resume, and then fail gracefully (at least it should).
The only case this can still corrupt data is if you boot
with init=/bin/bash and have stuff mounted, and theres a valid
resume partition in your swap.

That's a special case that I'm not sure how to protect against,
so that may just be a "dont do that" case.

	Dave



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]