On Sunday, 22 April 2007 11:40, Rafael J. Wysocki wrote:
> On Sunday, 22 April 2007 01:02, Tim Dijkstra wrote:
> > On Sat, 21 Apr 2007 23:14:48 +0200
> > "Rafael J. Wysocki" <[EMAIL PROTECTED]> wrote:
> > 
> > > On Saturday, 21 April 2007 22:36, Tim Dijkstra wrote:
> > > > On Sat, 21 Apr 2007 11:30:22 +0200
> > > > "Rafael J. Wysocki" <[EMAIL PROTECTED]> wrote:
> > > > 
> > > > > On Saturday, 21 April 2007 00:59, Tim Dijkstra wrote:
> > > > > > Hi,
> > > > > > 
> > > > > > I'm trying out sdisk with a swap file. 
> > > > > > 
> > > > > > $ cat /proc/swaps
> > > > > > Filename                                Type            Size    
> > > > > > Used    Priority
> > > > > > /dev/hda2                               partition       979956  
> > > > > > 189972  -1
> > > > > > /local/tmp/swapfile                     file            1048568 0   
> > > > > >     -2
> > > > > > 
> > > > > > Now what maybe complicates things is that mounted on /local is an 
> > > > > > lvm
> > > > > > logical volume, /dev/dm-5
> > > > > > 
> > > > 
> > > > > 
> > > > > First, try the built-in swsusp.
> > > > 
> > > > Doesn't work. 
> > > > $ cat /proc/cmdline
> > > > root=/dev/hda1 ro acpi_sleep=s3_bios,s3_mode vga=0x0330 
> > > > resume=/dev/dm-5 resume_offset=12979490
> > > > 
> > > > The result of `echo disk > /sys/power/state':
> > > > 
> > > > Wrote ... kbytes in ... sec
> > > > S<6>attempt to access beyond end of device
> > > > hda2: rw=16, want=103835928, limit=1959930
> > > > read-error on swap-device (3:2:103835928)
> > > > swsusp: Swap header not found!
> > > > 
> > > > 
> > > > BTW, /dev/hda2 is my other swap partition... Should I do anything else
> > > > except specifying resume en resume_offset on the command-line?
> > > 
> > > Ouch, sorry.  That has no chance to work, because /dev/dm-5 is not known 
> > > to the
> > > kernel before LVMs are initialized which happens after the resume kicks 
> > > in, so
> > > swsusp gets confused.
> > 
> > OK, but this is at suspend, then /dev/dm-5 is known.
> 
> This doesn't matter, because the resume device is selected at boot time.
> 
> > And this problem shouldn't be a problem in the case of uswsusp, should it?
> 
> No, it shouldn't.
> 
> I'll try to debug it a little later today, but I have no LVM setup handy.

I've tested with a swap on a "regular" partition and it works as expected.
If provided with the right swap offset (as returned by swap-offset from a
recent CVS), suspends and resumes.  When provided with a wrong offset,
refuses to do anything.

I think we have to debug the swap-file-on-LVM case more thoroughly.

Greetings,
Rafael

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Suspend-devel mailing list
Suspend-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/suspend-devel

Reply via email to