swap on a lv for hibernation

David Abrahams dave at boost-consulting.com
Sun Aug 27 21:06:00 UTC 2006


Alexander Skwar <listen at alexander.skwar.name> writes:

> In /etc/hibernate/suspend2.conf, I set:
>
> SuspendDevice swap:/dev/sys/Swap

Hmm, are you sure your LVM swap partition is actually getting used?
When I do 

     sudo swapon -s 

I get no response.  Do you know how to make sure that partition
actually gets used for swap space?

> In the relevant line in /boot/grub/menu.lst, I changed:
>
> from:
> # kopt=root=/dev/mapper/sys-URoot ro resume2=swap:/dev/hda6
>
> to:
> # kopt=root=/dev/mapper/sys-URoot ro resume2=swap:/dev/sys/Swap
>
> And then update-grub must be run. Alternatively, the "kernel" command
> line of the wanted kernel is to be modified.
>
> That's it.
>
> I said it before, but I'll repeat myself: I do not know, if the
> suspend-to-disk which is in the stock kernel supports swap on a LV.

Yeah, I thought it did, but now that I see the results of swapon -s on
my machine, I'm less sure.  Also, this may have been broken in the
recent kernel update
(https://launchpad.net/distros/ubuntu/+source/linux-source-2.6.15/+bug/50031)

> I find it *extremely* bad, that the GUI installer of 6.06 doesn't
> support LVM :( As I haven't yet downloaded anything from Edgy, I
> cannot tell if this has changed - has it?

I find it unfortunate too.

> I really don't understand why Ubuntu doesn't create LVM by itself
> when it automatically has to create filesystems.

The only reason I can think of is that some people who don't know
better will be upset when a partition fills up and there is still
"plenty of space on the disk."

-- 
Dave Abrahams
Boost Consulting
www.boost-consulting.com





More information about the ubuntu-users mailing list