Resume device. What is it?
Nigel Henry
cave.dnb2m97pp at aliceadsl.fr
Tue Mar 31 16:17:01 UTC 2009
On Tuesday 31 March 2009 16:09, Willy Hamra wrote:
> 2009/3/31 Howard Coles Jr. <dhcolesj at gmail.com>:
> > On Monday 30 March 2009 01:20:04 pm Nigel Henry wrote:
> >> On Monday 30 March 2009 18:52, Antonio Augusto (Mancha) wrote:
> >> > Hey Nigel,
> >> >
> >> > For what i get your problem MIGHT be, indeed, related to UUID. UUID is
> >> > used as a "symbolic" name to a device, so you ca use it instead of
> >> > /dev/sda3 (which might change when you repartition your disk).
> >> > What might be happening is that the UUID of /dev/sda3 was changed
> >> > (maybe by the new install of F10?) and hence none of your OSs can find
> >> > it. You can check this by looking at /dev/disk/by-uuid and seeing if
> >> > there is a syn-link there pointing to /dev/sda3, if there is check if
> >> > its the same name as used in /etc/fstab.
> >> >
> >> > The reason you see 0Mb swap may be because the UUID can't be found,
> >> > and hence no swap is activated.
> >> >
> >> > To your other question: yes you can simple comment that line in fstab
> >> > and replace it with the one form arch.
> >> >
> >> > Also, then you see "resume device", usually it refers to the partition
> >> > used to store the contents of the RAM when you put your computer to
> >> > hibernate (suspend do disk). Linux uses the swap space to store the
> >> > contents of the RAM, so it can resume when booted.
> >> > When you see a message like "waiting for resume device" or "resume
> >> > device not found", it simply means that Linux was not suspended to
> >> > disk, and is doing a cold boot. Nothing wrong with that.
> >> >
> >> > If you have any more questions please post them.
> >> >
> >> > Cheers,
> >> > KM
> >>
> >> Hi Antonio.
> >>
> >> Thanks for your reply. Having booted up a few other distros on this
> >> machine, so as to post output on my previous post to the list, I've just
> >> tried F10 again, which now boots up ok (No real surprise, as I often
> >> have problems with this Asus M2N-X Plus mobo). That said, fstab output
> >> from F10 is below, and /, and /home have UUID's, but swap is accessing
> >> /dev/sda3, and Gkrellm is showing 2000M-2000M free, which is correct.
> >> F10 was the last distro installed on this machine.
> >>
> >> #
> >> # /etc/fstab
> >> # Created by anaconda on Mon Feb 16 21:08:47 2009
> >> #
> >> # Accessible filesystems, by reference, are maintained under '/dev/disk'
> >> # See man pages fstab(5), findfs(8), mount(8) and/or vol_id(8) for more
> >> info #
> >> UUID=bd4e6a39-e802-44d4-9fd0-fc22692770b0 / ext3
> >> defaults 1 1
> >> UUID=5d6d96b6-c815-4816-8bce-81c286210754 /home ext3
> >> defaults 1 2
> >> tmpfs /dev/shm tmpfs defaults
> >> 0 0 devpts /dev/pts devpts
> >> gid=5,mode=620 0 0 sysfs /sys
> >> sysfs defaults 0 0 proc /proc
> >> proc defaults 0 0 /dev/sda3 swap
> >> swap defaults 0 0
> >>
> >> /dev/sdb1 /mnt/sdb1 vfat auto,umask=0
> >> 0 0 /dev/sdb2 /mnt/sdb2 vfat
> >> auto,umask=0 0 0
> >>
> >>
> >>
> >> Now a reboot into Kubuntu Intrepid 8.10, and with an edit to fstab,
> >> changing the UUID for swap to /dev/sda3, this appears to be ok after a
> >> reboot. See below for fstab output.
> >>
> >> # /dev/sda3
> >> #UUID=a2bc95ec-5fe4-4651-9ca5-7027344141e3 none swap sw
> >> 0 0
> >>
> >> #Swap reference changed by me
> >> /dev/sda3 none swap sw 0 0
> >>
> >> The above appears to have resolved the problem. On bootup with Intrepid,
> >> the bootup still hangs at the "waiting for resume device" line for a
> >> couple of seconds, but I'll let that go. At least Gkrellm now shows that
> >> swap is on.
> >>
> >> Tried sudo swapoff /dev/sda3, and Gkrellm showed swap as 0M, then did
> >> sudo swapon /dev/sda3, and Gkrellm showed swap as 2000M-2000M free.
> >>
> >> Thanks again for your reply Antonio.
> >>
> >> Nigel.
> >>
> >> > On Mon, Mar 30, 2009 at 13:26, Nigel Henry
> >> > <cave.dnb2m97pp at aliceadsl.fr>
> >>
> >> wrote:
> >> > > I booted up F10 this morning, after fixing an selinux related
> >> > > problem yesterday, but the bootup stalled. I noticed an entry on the
> >> > > bootup messages, "unable to stat resume device". Not wishing to
> >> > > waste time on F10, as I'd had enough of that yesterday, I rebooted
> >> > > to Kubuntu Intrepid (on the same machine), and Intrepid hung for a
> >> > > few seconds with "waiting for resume device", then the bootup
> >> > > continued with no problems.
> >> > >
> >> > > I googled "resume device", and there are a whole bunch of hits, with
> >> > > folks having various problems with it. It appears to be referencing
> >> > > "swap", but why resume device. I would have thought that, that
> >> > > description applied more to laptops, and my machine is a PC.
> >> > >
> >> > > Nigel.
> >
> > Nigel, look in the boot.cfg or /boot/grub/menu.lst for an entry called
> > "resume=<some device>" Make it match either with the UUID or the /dev/
> > id name and you should be good or just remove it altogether (as mine is)
> > and the OS should find it by default. This entry tells the Kernel were
> > to look for a resumable instance of the OS whether to RAM (suspend) or to
> > Disk (Hibernate).
>
> i believe this entry is in "/etc/initramfs-tools/conf.d/resume"
> i've had to edit this file many times, nowadays i use a link from
> /dev/disk/by-id in that file, since i always run mkswap which changes
> my swap's UUID.
>
>
> --
> Willy K. Hamra
> Manager of Hamra Information Systems
> Co. Manager of Zeina Computers and Billy Net.
Hi Willy.
Thanks for that info. I found nothing in /boot/grub/menu.lst, when my googling
"resume device" yesterday, suggested looking there. I also, today checked
out /dev/disk/by-uuid, which Antonio suggested, but no symlink there
to /dev/sda3 (swap partition). /etc/initramfs-tools/conf.d has the resume
file. Just one line in it, as below.
RESUME=UUID=a2bc95ec-5fe4-4651-9ca5-7027344141e3
That matches the UUID in /etc/fstab for the swap partition, but I assume that
because there is no symlink to /dev/sda3 in /dev/disk/by-uuid, that is the
reason why the UUID entry in /etc/fstab was unable to switch on the swap. I
fixed it as below, and perhaps it's a hack, but swap is now being switched on
at bootup.
# /dev/sda3
#UUID=a2bc95ec-5fe4-4651-9ca5-7027344141e3 none swap sw
0 0
#Swap reference changed by me
/dev/sda3 none swap sw 0 0
It's getting a bit academic now. All my machines are PC's. I may be wrong, but
it appears that this resume device is something specific to laptop users,
where when you shut the lid, whatever is in the physical RAM, is saved to the
swap partition, then when you reopen the lid, the resume device is brought
into play, and you see things as they were before you closed the lid. I'm not
a laptop user, so please excuse any errors above.
Is it possible to prevent the machine when booting up, looking for this resume
device, when you are not using a laptop? I'd already switched laptop-mode off
ages ago, using sysv-rc-conf.
I'd searched /etc/initramfs-tools earlier, but somehow missed the resume file.
I'd also had a good look in /etc/udev, but couldn't find any rules relating
to the creation of these UUID symlinks to the block devices, but perhaps they
are created by the initrd before udev is run.
While googling I did see some suggestions that to resolve the resume device
problem, it was necessary to edit the initrd file, but I've never messed with
that, yet.
As I say, this is now going a bit academic, but any comments are welcome.
Nigel.
More information about the kubuntu-users
mailing list