Page 56 of 58 FirstFirst ... 6465455565758 LastLast
Results 551 to 560 of 580

Thread: How to have a custom Grub2 menu that is maintenance free

  1. #551
    Join Date
    Aug 2009
    Beans
    Hidden!
    Distro
    Xubuntu

    Re: How to have a custom Grub2 menu that is maintenance free

    Quote Originally Posted by Cavsfan View Post
    It took me awhile but, I finally figured out what most people probably already knew.

    When I customized Xubuntu 20.04 grub the menu would always never show, so rather than delving in to see what the problem was I had my grub on another system that didn't do that.

    Anyway, I err um, stumbled upon the fact that if I pressed the ESC key the menu would show. Figured out why that was in /etc/default/grub:
    Just needed to change this:
    Code:
    GRUB_TIMEOUT_STYLE=hidden
    to this:
    Code:
    GRUB_TIMEOUT_STYLE=menu
    Then everything worked like it should.
    Turns out my 18.04 install had this same issue. That should solve it and I updated the Wiki.
    If anyone has any problem on any version let me know.

  2. #552
    Join Date
    Sep 2007
    Location
    Thurgoona, NSW, Australia
    Beans
    285
    Distro
    Ubuntu

    Re: How to have a custom Grub2 menu that is maintenance free

    Hi Cavsfan - my old frankenbox finally fell over so I bit the bullet and went all new. This combo should last a week before obsolescence, it's that cutting edge

    Anyway, upon plugging in HDDs and booting I saw the same thing in the GRUB menu, very truncated. Luckily I remembered your post!

    Keep up the good work!

  3. #553
    Join Date
    Aug 2009
    Beans
    Hidden!
    Distro
    Xubuntu

    Re: How to have a custom Grub2 menu that is maintenance free

    Quote Originally Posted by von Stalhein View Post
    Hi Cavsfan - my old frankenbox finally fell over so I bit the bullet and went all new. This combo should last a week before obsolescence, it's that cutting edge

    Anyway, upon plugging in HDDs and booting I saw the same thing in the GRUB menu, very truncated. Luckily I remembered your post!

    Keep up the good work!
    Newer is always nice. Mine is a beast but, it's a few years old with a 4th gen i7.

    Glad I could help!

  4. #554
    Join Date
    Aug 2009
    Beans
    Hidden!
    Distro
    Xubuntu

    Re: How to have a custom Grub2 menu that is maintenance free

    Grub on Bionic Beaver 18.04.5.

    Last edited by Cavsfan; September 26th, 2020 at 04:11 AM.

  5. #555
    Join Date
    Aug 2009
    Beans
    Hidden!
    Distro
    Xubuntu

    Re: How to have a custom Grub2 menu that is maintenance free

    If you dual or multi boot Linux systems and are interested in preventing your grub moving from one partition to another every time a new version of grub is installed. There are some steps you can take.

    I currently have mine on Fedora 33 but I am booting Arch Linux, Fedora 33, openSUSE Tumbleweed, Xubuntu 18.04, Xubuntu 20.04 and Xubuntu 20.10.
    On Ubuntu you can put the grub packages on hold with this command:
    Code:
    sudo apt-mark hold <pkg>
    apt-mark man page

    I was customizing all my systems because grub moves from one to another, Ubuntu and openSUSE do anyway.

    This makes it so you only have to worry about customizing one system.

    Just thought I'd mention it. Working pretty well here.

  6. #556
    Join Date
    Mar 2008
    Location
    Northern California
    Beans
    159
    Distro
    Ubuntu Mate Development Release

    Re: How to have a custom Grub2 menu that is maintenance free

    Thanks Cavsfan for this thread. I recently acquired a laptop from Ebay that had a UEFI bios. So far I've managed to get things set up in 06_custom so as to boot everything except a live CD or ISO.

    #!/bin/sh
    echo 1>&2 "Adding MATE 20.04 LTS focal, MATE 21.04 hirsute, live CD + parted magic"
    exec tail -n +4 $0
    # This file provides an easy way to add custom menu entries. Simply type the
    # menu entries you want to add after this comment. Be careful not to change
    # the 'exec tail' line above.
    menuentry 'Ubuntu-MATE 20.04 (on /dev/sda5)' {
    search --no-floppy --fs-uuid --set=root e5cc4b83-5a56-4d3e-b885-dee279e6d6eb
    linux /boot/vmlinuz root=UUID=e5cc4b83-5a56-4d3e-b885-dee279e6d6eb ro quiet splash $vt_handoff
    initrd /boot/initrd.img
    }
    menuentry 'Ubuntu-MATE 21.04 (on /dev/sda8)' {
    search --no-floppy --fs-uuid --set=root 1588c768-4536-43d7-963f-2ababd7d4022
    linux /boot/vmlinuz root=UUID=1588c768-4536-43d7-963f-2ababd7d4022 ro quiet splash $vt_handoff
    initrd /boot/initrd.img
    }
    menuentry 'live CD (on /dev/sda5)' {
    search --no-floppy --fs-uuid --set=root e5cc4b83-5a56-4d3e-b885-dee279e6d6eb
    set isofile="/home/data/Iso/ubuntu-mate-16.04.4-desktop-amd64.iso"
    loopback loop (hd1,msdos5)$isofile
    linux (loop)/casper/vmlinuz.efi boot=casper iso-scan/filename=$isofile quiet splash
    initrd (loop)/casper/initrd.lz
    }
    menuentry 'Parted Magic (on /dev/sda5)' {
    search --no-floppy --fs-uuid --set=root e5cc4b83-5a56-4d3e-b885-dee279e6d6eb
    linux /boot/pmagic/bzImage64 root=/dev/sda5 directory=boot edd=on vga=normal
    initrd /boot/pmagic/initrd.img /boot/pmagic/fu.img /boot/pmagic/m64.img
    }

    There seems to be a bug in grub 2.04 Please see - https://bugs.launchpad.net/ubuntu/+s...2/+bug/1851311
    The bug probably is keeping me from mounting an ISO. Do you have any thoughts as to what I might do to solve or work around this issue?

  7. #557
    Join Date
    Jun 2009
    Location
    SW Forida
    Beans
    Hidden!
    Distro
    Kubuntu

    Re: How to have a custom Grub2 menu that is maintenance free

    I just installed Hirsute using UEFI & loopmount.

    My configuration is a bit involved as I use a data partition and configfile into the ISO folder in the data partition. And in ISO folder I have a file livecdimage.cfg which has all my ISO boot info. I always forgot to update grub, so I now use configfile into the text file as then I do not have to update grub. Note inconsistency with hd0 & hd1, I often have to manually edit one or the other as I boot.

    In 40_custom:
    Code:
    menuentry 'Live ISOs in data drive' { 
    search --set=root --label nvme_data --hint hd0,gpt5 
    configfile /ISO/livecdimage.cfg 
    }
    Then in
    /ISO/livecdimage.cfg

    Code:
    menuentry "Kubuntu 21.04 Live ISO" {
        set isofile="/ISO/hirsute-desktop-amd64.iso"
        rmmod tpm
        loopback loop (hd1,5)$isofile
            linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile toram noeject
            initrd (loop)/casper/initrd
    }
    Because I installed to sda drive but boot from NVMe drive, I have a numbering issue. Default boot is always hd0, but if I boot NVMe drive as hd0, my install in sda drive becomes hd1. But I also have an external drive plugged in and that often changes order again. It my only work after I unplug external drive, just to avoid confusion (mine).
    Last edited by oldfred; February 15th, 2021 at 08:43 PM.
    UEFI boot install & repair info - Regularly Updated :
    https://ubuntuforums.org/showthread.php?t=2147295
    Please use Thread Tools above first post to change to [Solved] when/if answered completely.

  8. #558
    Join Date
    Aug 2016
    Location
    Wandering
    Beans
    Hidden!
    Distro
    Xubuntu Development Release

    Re: How to have a custom Grub2 menu that is maintenance free

    Quote Originally Posted by oldfred View Post
    I just installed Hirsute using UEFI & loopmount.

    My configuration is a bit involved as I use a data partition and configfile into the ISO folder in the data partition. And in ISO folder I have a file livecdimage.cfg which has all my ISO boot info. I always forgot to update grub, so I now use configfile into the text file as then I do not have to update grub. Note inconsistency with hd0 & hd1, I often have to manually edit one or the other as I boot.

    In 40_custom:
    Code:
    menuentry 'Live ISOs in data drive' { 
    search --set=root --label nvme_data --hint hd0,gpt5 
    configfile /ISO/livecdimage.cfg 
    }
    Then in
    /ISO/livecdimage.cfg

    Code:
    menuentry "Kubuntu 21.04 Live ISO" {
        set isofile="/ISO/hirsute-desktop-amd64.iso"
        rmmod tpm
        loopback loop (hd1,5)$isofile
            linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile toram noeject
            initrd (loop)/casper/initrd
    }
    Because I installed to sda drive but boot from NVMe drive, I have a numbering issue. Default boot is always hd0, but if I boot NVMe drive as hd0, my install in sda drive becomes hd1. But I also have an external drive plugged in and that often changes order again. It my only work after I unplug external drive, just to avoid confusion (mine).
    Brilliant!
    Thanks for the share oldfred,
    With realization of one's own potential and self-confidence in one's ability, one can build a better world.
    Dalai Lama>>
    Code Tags | System-info | Forum Guide lines | Arch Linux, Debian Unstable, FreeBSD

  9. #559
    Join Date
    Mar 2008
    Location
    Northern California
    Beans
    159
    Distro
    Ubuntu Mate Development Release

    Re: How to have a custom Grub2 menu that is maintenance free

    I'll look up this configfile business as I have a data partition too. But only one SSHD.

    My configuration is a bit involved as I use a data partition and configfile into the ISO folder in the data partition. And in ISO folder I have a file livecdimage.cfg which has all my ISO boot info.
    How do I make these config files?

    I read oldfred's post with more attention to detail and came up with my livecdimage.cfg file.

    This is it -

    menuentry "Ubuntu-Mate 18.04 Live ISO" {
    set isofile="/Iso/-amd64/ubuntu-mate-18.04.4-desktop-amd64.iso"
    rmmod tpm
    loopback loop (hd0,7)$isofile
    linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile toram noeject
    initrd (loop)/casper/initrd
    }

    Getting closer but no boot to ISO yet. I'll post back with observations and details once I get this working. My suspicion is that I'll have to install a different grub.
    Last edited by Michael Dooley; February 17th, 2021 at 12:55 AM. Reason: mo info

  10. #560
    Join Date
    Aug 2009
    Beans
    Hidden!
    Distro
    Xubuntu

    Re: How to have a custom Grub2 menu that is maintenance free

    Quote Originally Posted by Michael Dooley View Post
    Thanks Cavsfan for this thread. I recently acquired a laptop from Ebay that had a UEFI bios. So far I've managed to get things set up in 06_custom so as to boot everything except a live CD or ISO.
    Thanks for the kind words! Although, I have never used a grub entry to mount a live ISO; I've no doubt that it can be done as Fred and 1fallen have done it.

    Quote Originally Posted by Michael Dooley View Post
    I'll look up this configfile business as I have a data partition too. But only one SSHD.



    How do I make these config files?

    I read oldfred's post with more attention to detail and came up with my livecdimage.cfg file.

    This is it -

    menuentry "Ubuntu-Mate 18.04 Live ISO" {
    set isofile="/Iso/-amd64/ubuntu-mate-18.04.4-desktop-amd64.iso"
    rmmod tpm
    loopback loop (hd0,7)$isofile
    linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile toram noeject
    initrd (loop)/casper/initrd
    }

    Getting closer but no boot to ISO yet. I'll post back with observations and details once I get this working.
    My suspicion is that I'll have to install a different grub.
    I was never able to get any config file to boot and I tried many times. Let me know when you get that to work.
    I use UUIDs to link the partitions in my custom grub menu. It's as simple as I could get it; I figured out what was necessary and it makes sense to me.
    Code:
    [cavsfan@Arch ~]$ sudo blkid | grep -e EFI -e sdc5 -e Bionic
    /dev/sdc1: UUID="688D-126B" BLOCK_SIZE="512" TYPE="vfat" PARTLABEL="EFI System Partition" PARTUUID="15661847-bc65-401a-84b0-97a157f3949f"
    /dev/sdc5: UUID="b564ed75-b9ee-410f-9f87-04afc30a0ff4" TYPE="swap" PARTLABEL="swap" PARTUUID="dc354366-1300-48d4-8a60-133aa2e2ca57"
    /dev/sdc10: LABEL="Bionic" UUID="338e6d3b-cbd4-496d-9cc2-b688a90c17c3" BLOCK_SIZE="4096" TYPE="ext4" PARTLABEL="Bionic" PARTUUID="4f579967-b025-47dc-b080-64a0865d7165"
    Showing the EFI boot partition just because, the swap is red and the system partition is blue. Some systems use the EFI boot partition's UUID, Arch Linux is one of those.
    Code:
    menuentry 'Xubuntu 18.04.4 Bionic Beaver LTS' {
        search --no-floppy --fs-uuid --set=root 338e6d3b-cbd4-496d-9cc2-b688a90c17c3
        linux  /vmlinuz root=UUID=338e6d3b-cbd4-496d-9cc2-b688a90c17c3 ro quiet resume=/dev/disk/by-uuid/b564ed75-b9ee-410f-9f87-04afc30a0ff4 splash
        initrd /initrd.img
    }
    menuentry 'Xubuntu 18.04.4 Bionic Beaver LTS (recovery mode)' {
        search --no-floppy --fs-uuid --set=root 338e6d3b-cbd4-496d-9cc2-b688a90c17c3
        linux  /vmlinuz root=UUID=338e6d3b-cbd4-496d-9cc2-b688a90c17c3 ro recovery nomodeset
        initrd /initrd.img
    }

Page 56 of 58 FirstFirst ... 6465455565758 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
  •