Results 1 to 4 of 4

Thread: s2disk without skipping GRUB menu

  1. #1
    Join Date
    Jun 2008
    Location
    Tallinn, Estonia
    Posts
    228

    Lightbulb s2disk without skipping GRUB menu

    I'm looking for method using suspend to disk, but with a choice of operating system during next booting.

    Why?

    On my laptop openSUSE 11.1 and Windows Vista are installed. What I want to achieve is suspending everything to hard disk in my KDE session and rebooting to Windows Vista (or any other suspended operating system I want to choose). As long as that other OS doesn't use the same Swap partition as suspended OS, I suppose it is possible to boot it without corrupting suspended one?

    Here goes the explanation, how I think things work (if I have understood it incorrectly, please correct me):

    Normally s2disk moves everything from RAM to Swap (hard disk) and 'overrides' GRUB operation system choosing menu, so next time system boots it automatically chooses operating system. The same thing happens when you choose operating system you want to reboot before actually rebooting it - at least you can do this in KDE.

    So maybe I can somehow disable this GRUB skipping, for example, by editing s2disk script or any other configuration files?

  2. #2

    Default Re: s2disk without skipping GRUB menu


  3. #3
    Join Date
    Jun 2008
    Location
    Tallinn, Estonia
    Posts
    228

    Default Re: s2disk without skipping GRUB menu

    Thank you!

    That is an obvious place to look before asking
    and I think I have even seen that page,
    but I probably have overseen this subheading.

    When I try described procedure, I will post the result here.

  4. #4
    Join Date
    Jun 2008
    Location
    Tallinn, Estonia
    Posts
    228

    Default Re: s2disk without skipping GRUB menu

    Yes, the trick works!

    But there was a small difference in code of the listed script (at least in my system)
    Code:
    /usr/lib/pm-utils/sleep.d/99Zgrub
    Snip from the file (grub lines already commented out)

    Code:
    ###### main()
    
    if [ "$1" = hibernate ] || [ "$1" = suspend -a "$2" = suspend_hybrid ]; then
    ###        prepare-grub
    fi
    if [ "$1" = thaw ] || [ "$1" = resume -a "$2" = suspend_hybrid ]; then
    ###        grub-once-restore
    fi

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •