Page 80 of 94 FirstFirst ... 3070787980818290 ... LastLast
Results 791 to 800 of 931

Thread: Grub 2 Basics

  1. #791
    Join Date
    Jan 2007
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: Grub 2 Basics

    Quote Originally Posted by grubu View Post
    Hello,

    I just wanted to post a small thing which might help you to control the grub2's display a little easier:

    Code:
    sudo apt-get install startupmanager
    startupmanager
    then try to configure just anything to your needs and reboot to test, for me all workes fine with 1024x768,
    which is absolutely enough for me. Just for a verify, the 'grub-install -v' gives me a line-output of:
    grub-install (GNU GRUB 1.98-1ubuntu12) anyway I don't think that it is version-dependend.
    Actually, StartUp-Manager is more or less version dependent. It works only partially with Grub 2 versions, and can't handle the Grub 2 submenus introduced with Grub 1.99 (Natty).

    SUM was a great tool in its day but it has been surpassed by a GUI app written after the arrival of Grub 2: Grub Customizer:
    HowTo: Grub Customizer
    GRUB2

    Retired.

  2. #792
    Join Date
    May 2011
    Beans
    80
    Distro
    Xubuntu 12.04 Precise Pangolin

    Re: Grub 2 Basics

    Oh that is not a good thing so I am a little lucky that it was just tested on the 10.04 LTS. Sorry for the useless information.
    I will then better refer to the grub-customizer by:

    Quote Originally Posted by drs305 View Post
    [*]Terminal:
    Add the repository to your system. The following commands will add the repository, import the security key, update the list of available packages and install Grub Customizer.
    • Open a terminal
      Applications > Accessories > Terminal
    • Install Grub Customizer
      Code:
      sudo add-apt-repository ppa:danielrichter2007/grub-customizer
      sudo apt-get update
      sudo apt-get install grub-customizer
    Thanks.

    Em drs305, is there a way to update grub2 to its latest version even from an older ubuntu-version?
    Last edited by grubu; July 27th, 2011 at 09:52 PM.

  3. #793
    Join Date
    Jan 2007
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: Grub 2 Basics

    Quote Originally Posted by grubu View Post
    Em drs305, is there a way to update grub2 to its latest version even from an older ubuntu-version?
    Yes there is. I don't often mention how to do it as I believe if Grub 2 is working it's best to leave it alone.

    But if you really want or need the latest Ubuntu version (Grub 1.99RC), I'll provide the general outline of how I do it:
    • Edit /etc/apt/sources.list by whatever means you wish to use and change the "main" entry to point to "natty" instead of "lucid", "maverick", etc.
    • Save the file and update the package lists.
    • Use "apt-get install -s grub-pc" to update. The "-s" shows what it will do. Once you are satisfied it's going to do what you want, run it again without the "-s". It should only install grub-common, grub-pc and grub-gfxpayload-lists.
    • Once you have run the command, make sure you return the sources.list back to your normal release ("maverick", etc) and update the list.

    For the normal user, the chances of messing up your system outweigh the advantages IMO.
    GRUB2

    Retired.

  4. #794
    Join Date
    May 2011
    Beans
    80
    Distro
    Xubuntu 12.04 Precise Pangolin

    Re: Grub 2 Basics

    After getting rid of startupmanager and installing grub-customizer I decided to try to update my grub2 version just as you said, everything happened just as predicted: "sudo apt-get install -s grub-pc" showed:

    Suggested packages: multiboot-doc grub-emu xorriso
    The following NEW packages will be installed: grub-gfxpayload-lists
    The following packages will be upgraded: grub-common grub-pc
    2 upgraded, 1 newly installed, 0 to remove and .... not upgraded.
    Inst grub-gfxpayload-lists (0.2 Ubuntu:11.04/natty) []
    Inst grub-pc [1.98-1ubuntu12] (1.99~rc1-13ubuntu3 Ubuntu:11.04/natty) []
    Inst grub-common [1.98-1ubuntu12] (1.99~rc1-13ubuntu3 Ubuntu:11.04/natty)
    Conf grub-common (1.99~rc1-13ubuntu3 Ubuntu:11.04/natty)
    Conf grub-pc (1.99~rc1-13ubuntu3 Ubuntu:11.04/natty)
    Conf grub-gfxpayload-lists (0.2 Ubuntu:11.04/natty)

    "sudo apt-get install grub-pc" took me to this question:

    Configuration file `/etc/grub.d/00_header'
    ==> Modified (by you or by a script) since installation.
    ==> Package distributor has shipped an updated version.
    What would you like to do about it ? Your options are:
    Y or I : install the package maintainer's version
    N or O : keep your currently-installed version
    D : show the differences between the versions
    Z : background this process to examine the situation
    The default action is to keep your current version.
    *** 00_header (Y/I/N/O/D/Z) [default=N] ?

    'I' had been chosen in order to be on a save place and I also reinstalled the maintainer's "/etc/default/grub" and reinstalled
    grub2 to "sd(x)" to have anything at its basics and then I got a succesful:
    Setting up grub-pc (1.99~rc1-13ubuntu3) ...

    After setting the "/etc/apt/sources.list" back from natty to lucid and doing a reboot the "grub-install -v" is now giving me a:
    grub-install (GRUB) 1.99~rc1-13ubuntu3

    Thanks drs305 it is a pleasure to work with your guidance

  5. #795
    Join Date
    Jan 2007
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: Grub 2 Basics

    Quote Originally Posted by grubu View Post
    After getting rid of startupmanager and installing grub-customizer I decided to try to update my grub2 version just as you said, everything happened just as predicted: "sudo apt-get install -s grub-pc" showed:

    Thanks drs305 it is a pleasure to work with your guidance
    Glad it worked. Since your normal repositories do not include grub-pc 1.99 you won't get updates to the package. There shouldn't be big changes or major bugs in 1.99. If you ever needed to update the Grub package you would need to once again enable the natty (or later) repository and repeat the process using "apt-get install --reinstall". Just be sure never to run a general upgrade with the 'natty' repository enabled or it could do damage to your earlier release.
    Last edited by drs305; July 28th, 2011 at 12:22 PM.
    GRUB2

    Retired.

  6. #796
    Join Date
    Sep 2007
    Location
    Thurgoona, NSW, Australia
    Beans
    236
    Distro
    Ubuntu 15.04 Vivid Vervet

    Re: Grub 2 Basics

    [QUOTE=drs305;11093176]Yes there is. I don't often mention how to do it as I believe if Grub 2 is working it's best to leave it alone. ]

    I spit beer on the keyboard when I read that

    Amen!!!!

  7. #797
    Join Date
    May 2011
    Beans
    80
    Distro
    Xubuntu 12.04 Precise Pangolin

    Re: Grub 2 Basics

    Quote Originally Posted by drs305 View Post
    If you ever needed to update the Grub package you would need to once again enable the natty (or later) repository and repeat the process using "apt-get install --reinstall". Just be sure never to run a general upgrade with the 'natty' repository enabled or it could do damage to your earlier release.
    Yes, thank you that is an important information for any kind of package you might install from a newer build.
    We should all keep that in mind because sometimes there could be newer working packages which we are able to use then.

    As I will stick with the LTS til 2013 I will also try not to forget to set the "sources.list" back. I also have another computer
    with natty and oneiric in the test, but as this is my first real LTS I want to have a view on that long term thing.

    to Grub 2 is working it's best to leave it alone:
    Hm, I think there is a frighteness that is a little bit to strong.
    Normally we would install grub2 just to the harddisk we want to use as major-disk, but as it is
    that easy to do it by a live-cd-boot I will no more be afraid of repairing it, if grub2 might be broken in some way.

    Anyway a good solution would be to have at anytime a clean backup of your /boot folder.

    Of cause it is not really necessary to play too much with a bootloader, but to me if I haven't tried
    all that out, I would still not be able to boot an iso with or without persistence which gives me the
    possibilty to have an working environment at any time it is needed. Another plus is the succesful
    transfer of an installed system to another place which made me very happy.
    Last edited by grubu; July 28th, 2011 at 08:04 PM.

  8. #798
    Join Date
    May 2011
    Beans
    80
    Distro
    Xubuntu 12.04 Precise Pangolin

    Re: Grub 2 Basics

    Hell drs305,

    I have another question, maybe you can help me again with that:
    In order to get rid of the uuid checking from grub2 and use lable-checking
    instead I am not sure in which kind I should replace the following line in
    "/boot/grub/grub.cfg" :
    Code:
    search --no-floppy --fs-uuid --set=root xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
    the full "/boot/grub/grub.cfg" menuentry looks like that:
    Code:
    menuentry 'Ubuntu, with Linux 2.6.32-33-generic' --class ubuntu --class gnu-linux --class gnu --class os {
            recordfail
            set gfxpayload=$linux_gfx_mode
            insmod part_msdos
            insmod ext2
            set root='(/dev/sda,msdos6)'
            search --no-floppy --fs-uuid --set=root xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
            linux   /boot/vmlinuz-2.6.32-33-generic root=/dev/sda6 ro splash vga=791 quiet  quiet splash vt.handoff=7
            initrd  /boot/initrd.img-2.6.32-33-generic
    }
    Thanks for your help.

  9. #799
    Join Date
    Jan 2007
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: Grub 2 Basics

    Quote Originally Posted by grubu View Post
    Hell drs305,

    I have another question, maybe you can help me again with that:
    In order to get rid of the uuid checking from grub2 and use lable-checking
    instead I am not sure in which kind I should replace the following line in
    "/boot/grub/grub.cfg" ...
    I had not experimented with this and it's not well-documented, but I tested it in a VM.

    The 'search' line format for a labeled partition appears to be the following. The label for my Ubuntu partition for the tests was natty - replace with the correct label for your OS:

    search --no-floppy -l natty --set=root
    linux /boot/vmlinuz-2.6.32-33-generic root=LABEL=natty ro splash vga=791 quiet quiet splash vt.handoff=7
    I would edit the menuentry in the G2 menu to see if the format works for you. Editing the menuentry is non-persistent so if it doesn't work just reboot and try again or boot without making any changes.

    If you have a custom Grub 2 entry, the above is the format you need to incorporate the changes into the Grub2 menu.

    The question is how to incorporate it into a normal menuentry automatically. You can disable UUIDs in /etc/default/grub but this doesn't remove the UUID from the search line and it changes the 'linux' line to "sdXY".

    I'll have to work on this when I have a bit more time - I expect it will involve editing the /etc/grub.d/10_linux file. I'll post back when I find a solution.
    GRUB2

    Retired.

  10. #800
    Join Date
    May 2011
    Beans
    80
    Distro
    Xubuntu 12.04 Precise Pangolin

    Re: Grub 2 Basics

    It again works like a charm as my root-partition is labeled "ubuntu-root-p6"
    the menuentry of the "/boot/grub/grub.cfg" is now set to:

    menuentry 'Ubuntu-boot-by-label, with Linux 2.6.32-33-generic' --class ubuntu --class gnu-linux --class gnu --class os {
    recordfail
    set gfxpayload=$linux_gfx_mode
    insmod part_msdos
    insmod ext2
    search --no-floppy -l ubuntu-root-p6 --set=root
    linux /boot/vmlinuz-2.6.32-33-generic root=LABEL=ubuntu-root-p6 ro splash vga=791 quiet quiet splash vt.handoff=7
    initrd /boot/initrd.img-2.6.32-33-generic
    }
    As we spoke earlier the label-thing gives us a lot more control. Thank you very much drs305 for your fast guidance,
    this seems to be a very good basic, too.

    Quote Originally Posted by drs305 View Post
    The question is how to incorporate it into a normal menuentry automatically. You can disable UUIDs in /etc/default/grub but this doesn't remove the UUID from the search line and it changes the 'linux' line to "sdXY".

    I'll have to work on this when I have a bit more time - I expect it will involve editing the /etc/grub.d/10_linux file. I'll post back when I find a solution.
    Yes, that is a thing even though the uuid search could be disabled, hm maybe the the /etc/grub.d/10_linux file is a good way for doing an automatic entry.

    Anyway to me the above solution is fully practicable and I am very glad that you could tell me the syntax.

    As an "update-grub" will bring us back to the other state we at the moment just have to keep that in mind and bring it manually back then or better:
    We place it within our /etc/grub.d/40_custom file.

    Another interesting thing is that I am also able to boot by label with the new menuentry even if the line in file /etc/default/grub shows "#GRUB_DISABLE_LINUX_UUID="true" so it normally should not be possible or?
    Last edited by grubu; August 6th, 2011 at 07:42 PM. Reason: forgetting to mention some things

Page 80 of 94 FirstFirst ... 3070787980818290 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

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