Welcome!
Important information
-- Spectre and Meltdown vulnerabilities
-- Change in MX sources

News
-- MX Linux on social media: here
-- Mepis support still here

Current releases
-- MX-17.1 Final release info here
-- antiX-17 release info here

New users
-- Please read this first, and don't forget to add system and hardware information to posts!
-- Here are the Forum Rules

Re : New MX Tool: MX Boot Options

Help for Current Versions of MX
Message
Author
turtlebay777
Forum Regular
Forum Regular
Posts: 199
Joined: Sat Apr 14, 2018 2:40 pm

Re : New MX Tool: MX Boot Options

#1 Post by turtlebay777 » Fri Aug 10, 2018 6:13 pm

https://mxlinux.org/new-mx-tool-mx-boot-options

So what's the difference between the new MX Boot Options tool and the existing Grub Customizer that is loaded into MX 17 by default?

User avatar
Jerry3904
Forum Veteran
Forum Veteran
Posts: 22461
Joined: Wed Jul 19, 2006 6:13 am

Re: Re : New MX Tool: MX Boot Options

#2 Post by Jerry3904 » Fri Aug 10, 2018 6:17 pm

The most obvious is the ability to use a splash, along with a choice of themes.
Production: 4.15.0-1-amd64, MX-17.1, AMD FX-4130 Quad-Core, GeForce GT 630/PCIe/SSE2, 8 GB, Kingston SSD 120 GB and WesternDigital 1TB
Testing: AAO 722: 4.15.0-1-386. MX-17.1, AMD C-60 APU, 4 GB

User avatar
asqwerth
Forum Veteran
Forum Veteran
Posts: 3342
Joined: Sun May 27, 2007 5:37 am

Re: Re : New MX Tool: MX Boot Options

#3 Post by asqwerth » Sat Aug 11, 2018 3:30 am

turtlebay777 wrote:So what's the difference between the new MX Boot Options tool and the existing Grub Customizer that is loaded into MX 17 by default?
Also, there is a difference in how the grub customizations are implemented.

MX Boot Options: it just makes simple text edits directly to specific lines in the /etc/default/grub file where the grub menu settings are stored.

GC: it sets up some intermediary folders and files where the settings changes go, and it can do some things that MXBO can't, like change the order of menu entries, add manually created customised entries, etc. However, I have found that when it saves and generates the customised grub menu, some errors gradually creep in, particularly when you have a multiboot machine.

It may be that if all you have is Windows and 1 or 2 distros, you won't encounter any issues. But my old and new PC had/has 10 or more, as did my old laptop.

I used GC regularly on my old PC and laptop from around 2012 to end 2014 when I was installing and testing many different distros (GC was kept constant though, in WattOS and Manjaro), and I found that over time, the menu generation was slower and slower and the grub menu itself that was churned out was longer (visually) because it was repeated 2 or 3 times.

It's only when I started to learn a little about grub to solve my problems that I discovered the multiple os-prober entries. Somehow GC was adding more os-prober entries to the menu. When I used GC to generate a new menu, each os-prober entry would make the machine scan the drives again and generate another menu that was appended to the end of the last one. I had to manually delete the extra os-prober entries, but they would creep back in again.

I think there was also at least once where it messed my system up but I can't remember the circumstances. I repaired the problem with a live distro.

Finally I got fed up and removed GC and when I got my new PC, I decided to learn some grub basics and create custom entries so I could edit grub settings directly without relying on GC. I've sworn off GC ever since. OK, so I can't change the order of entries in the main part of the grub.cfg file that is normally generated by grub, but I can have customised entries in a separate /boot/grub/custom.cfg file, so I often ignore the top half of my menu and just scroll straight to my custom entries.
Desktop: Intel i5-4460, 16GB RAM, Intel integrated graphics
Clevo N130WU-based Ultrabook: Intel i7-8550U (Kaby Lake R), 16GB RAM, Intel integrated graphics (UEFI)
ASUS X42D laptop: AMD Phenom II, 6GB RAM, Mobility Radeon HD 5400

User avatar
fehlix
Forum Guide
Forum Guide
Posts: 1725
Joined: Wed Apr 11, 2018 5:09 pm

Re: Re : New MX Tool: MX Boot Options

#4 Post by fehlix » Sat Aug 11, 2018 3:53 am

asqwerth wrote:
Sat Aug 11, 2018 3:30 am
...but I can have customised entries in a separate /boot/grub/custom.cfg file, so I often ignore the top half of my menu and just scroll straight to my custom entries.
@asqwerth, to avoid scrolling down the menu, you can have the custom-menuentries before the default generated ones like this:

Code: Select all

sudo mv /etc/grub.d/41_custom /etc/grub.d/09_custom
sudo update-grub
:puppy:
Gigabyte Z77M-D3H, Intel Xeon E3-1240 V2 (Quad core), 32GB RAM,
GeForce GTX 770, Samsung SSD 850 EVO 500GB, Seagate Barracuda 4TB

User avatar
asqwerth
Forum Veteran
Forum Veteran
Posts: 3342
Joined: Sun May 27, 2007 5:37 am

Re: Re : New MX Tool: MX Boot Options

#5 Post by asqwerth » Sat Aug 11, 2018 4:17 am

fehlix wrote:
Sat Aug 11, 2018 3:53 am
asqwerth wrote:
Sat Aug 11, 2018 3:30 am
...but I can have customised entries in a separate /boot/grub/custom.cfg file, so I often ignore the top half of my menu and just scroll straight to my custom entries.
@asqwerth, to avoid scrolling down the menu, you can have the custom-menuentries before the default generated ones like this:

Code: Select all

sudo mv /etc/grub.d/41_custom /etc/grub.d/09_custom
sudo update-grub
:puppy:
Thanks! I've tried something similar before, but then I realised that putting my custom entries in the custom scripts stored in /etc/grub.d means having to update grub everytime I change it. And with tons of distros, the updating of grub takes very long.

Placing entries in /boot/grub/custom.cfg means I never need to update grub when I change the entries within custom.cfg. Just save the changes and reboot, and the new stuff is there.
Desktop: Intel i5-4460, 16GB RAM, Intel integrated graphics
Clevo N130WU-based Ultrabook: Intel i7-8550U (Kaby Lake R), 16GB RAM, Intel integrated graphics (UEFI)
ASUS X42D laptop: AMD Phenom II, 6GB RAM, Mobility Radeon HD 5400

User avatar
fehlix
Forum Guide
Forum Guide
Posts: 1725
Joined: Wed Apr 11, 2018 5:09 pm

Re: Re : New MX Tool: MX Boot Options

#6 Post by fehlix » Sat Aug 11, 2018 4:26 am

asqwerth wrote:
Sat Aug 11, 2018 4:17 am

Thanks! I've tried something similar before, but then I realised that putting my custom entries in the custom scripts stored in /etc/grub.d means having to update grub everytime I change it. And with tons of distros, the updating of grub takes very long.

Placing entries in /boot/grub/custom.cfg means I never need to update grub when I change the entries within custom.cfg. Just save the changes and reboot, and the new stuff is there.
Read again. After my fix above, the custom.cfg entries will be placed before the default ones, no need for regenerating the menu via update-grub after changing custom.cfg, with m fix above.
You might have mixed 40_custom and 41_custom within you answer.
Gigabyte Z77M-D3H, Intel Xeon E3-1240 V2 (Quad core), 32GB RAM,
GeForce GTX 770, Samsung SSD 850 EVO 500GB, Seagate Barracuda 4TB

User avatar
asqwerth
Forum Veteran
Forum Veteran
Posts: 3342
Joined: Sun May 27, 2007 5:37 am

Re: Re : New MX Tool: MX Boot Options

#7 Post by asqwerth » Sat Aug 11, 2018 4:37 am

fehlix wrote:
Sat Aug 11, 2018 4:26 am
asqwerth wrote:
Sat Aug 11, 2018 4:17 am

Thanks! I've tried something similar before, but then I realised that putting my custom entries in the custom scripts stored in /etc/grub.d means having to update grub everytime I change it. And with tons of distros, the updating of grub takes very long.

Placing entries in /boot/grub/custom.cfg means I never need to update grub when I change the entries within custom.cfg. Just save the changes and reboot, and the new stuff is there.
Read again. After my fix above, the custom.cfg entries will be placed before the default ones, no need for regenerating the menu via update-grub after changing custom.cfg, with m fix above.
You might have mixed 40_custom and 41_custom within you answer.
Oooooooh. Learnt something new today.

And yes, I never realised there was a difference between 40_custom and 41_custom.

I'll test it when I have time. Manjaro controls my grub and I'm doing some updates and maintenance of my other distros now I'm back from my holiday.

Thanks!
Desktop: Intel i5-4460, 16GB RAM, Intel integrated graphics
Clevo N130WU-based Ultrabook: Intel i7-8550U (Kaby Lake R), 16GB RAM, Intel integrated graphics (UEFI)
ASUS X42D laptop: AMD Phenom II, 6GB RAM, Mobility Radeon HD 5400

User avatar
fehlix
Forum Guide
Forum Guide
Posts: 1725
Joined: Wed Apr 11, 2018 5:09 pm

Re: Re : New MX Tool: MX Boot Options

#8 Post by fehlix » Sat Aug 11, 2018 5:15 am

asqwerth wrote:
Sat Aug 11, 2018 4:37 am
...Manjaro controls my grub
...
If you are interessted, I can provide you with grub-patch which
would allow you to boot manjaro from MX-linux grub menu.
I'm running with this patch for years to boot from any debian based grub's
into manjaro. Need to tidy it up a bit.
:puppy:
Gigabyte Z77M-D3H, Intel Xeon E3-1240 V2 (Quad core), 32GB RAM,
GeForce GTX 770, Samsung SSD 850 EVO 500GB, Seagate Barracuda 4TB

User avatar
asqwerth
Forum Veteran
Forum Veteran
Posts: 3342
Joined: Sun May 27, 2007 5:37 am

Re: Re : New MX Tool: MX Boot Options

#9 Post by asqwerth » Sat Aug 11, 2018 5:39 am

fehlix wrote:
Sat Aug 11, 2018 5:15 am
asqwerth wrote:
Sat Aug 11, 2018 4:37 am
...Manjaro controls my grub
...
If you are interessted, I can provide you with grub-patch which
would allow you to boot manjaro from MX-linux grub menu.
I'm running with this patch for years to boot from any debian based grub's
into manjaro. Need to tidy it up a bit.
:puppy:
Very cool. Yes please!

I don't know if I'll use it, but I like to learn and see how others deal with this quirk of Manjaro.

You don't remove the intel ucode from Manjaro itself, do you?

For me, it's not a problem to let Manjaro control grub since it gets kernel updates every time there is an update, meaning that it's going to execute a update-grub command every update anyway, so I might as well let it handle grub.

But the problem is when, for example, Mint seizes control of bootloader when I update or install a kernel there. To boot into Manjaro and have it take back control I could manually edit the Mint grub menu's Manjaro entry to add the ucode text but that's troublesome.

So I have the custom.cfg file saved on a few different distros and they all have chainloading entries for Manjaro. Well, actually I have chainloading or "directly run the grub.cfg file of target distro" entries for every distro.
Desktop: Intel i5-4460, 16GB RAM, Intel integrated graphics
Clevo N130WU-based Ultrabook: Intel i7-8550U (Kaby Lake R), 16GB RAM, Intel integrated graphics (UEFI)
ASUS X42D laptop: AMD Phenom II, 6GB RAM, Mobility Radeon HD 5400

User avatar
fehlix
Forum Guide
Forum Guide
Posts: 1725
Joined: Wed Apr 11, 2018 5:09 pm

Re: Re : New MX Tool: MX Boot Options

#10 Post by fehlix » Sat Aug 11, 2018 6:35 am

asqwerth wrote:
Sat Aug 11, 2018 5:39 am
You don't remove the intel ucode from Manjaro itself, do you?
With the grub-patch to boot manjaro, you'll get the full boot-line used by manjaro including the intel-µcode.
asqwerth wrote:
Sat Aug 11, 2018 5:39 am
So I have the custom.cfg file saved on a few different distros and they all have chainloading entries for Manjaro. Well, actually I have chainloading or "directly run the grub.cfg file of target distro" entries for every distro.
Rather recommend not load manjaro's grub.cfg, which will fail on some internal used properties, like background, fonts etc,
but instead do a "proper" chainload "multiboot" of other OS's grub.
To give you an impression what can be done find below,
the part of my custom.cfg, which allows me to "chainload" from any of thos grub's
into the other grub-menu.

Code: Select all

submenu 'GRUB MULTIBOOT Chainloader'  {
# --------------------------
    # ----------------------------------
    menuentry 'GRUB MULTIBOOT MX 17 Horizon (auf /dev/sda6)' --class mx --class gnu-linux --class gnu --class os $menuentry_id_option 'grub-multiboot-7bfc8e75-74bd-442e-8d45-fbe88dfcb321' {
    # ----------------------------------
      savedefault
      insmod part_gpt
      insmod part_msdos
      insmod ext2
      # /dev/sda6: UUID="7bfc8e75-74bd-442e-8d45-fbe88dfcb321" TYPE="ext4"
      set root='hd0,gpt6'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt6 --hint-efi=hd0,gpt6 --hint-baremetal=ahci0,gpt6  7bfc8e75-74bd-442e-8d45-fbe88dfcb321
		else
		  search --no-floppy --fs-uuid --set=root 7bfc8e75-74bd-442e-8d45-fbe88dfcb321
		fi
        set OS_boot_config='/boot/grub/grub.cfg'
        multiboot /boot/grub/i386-pc/core.img
    }

    # ----------------------------------
    menuentry 'GRUB MULTIBOOT Manjaro Linux XFCE  64-bit (/dev/sda1)' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'grub-multiboot-d250b5ba-a538-4494-bc12-5373ad66b4d0' {
    # ----------------------------------
      savedefault
        insmod part_gpt
        insmod part_msdos
        insmod ext2
		# /dev/sda1: UUID="d250b5ba-a538-4494-bc12-5373ad66b4d0" TYPE="ext4" PARTUUID="1944aa56-2798-477c-8941-f752d200e5b8"
		set root='hd0,gpt1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt1 --hint-efi=hd0,gpt1 --hint-baremetal=ahci0,gpt1  d250b5ba-a538-4494-bc12-5373ad66b4d0
		else
		  search --no-floppy --fs-uuid --set=root d250b5ba-a538-4494-bc12-5373ad66b4d0
		fi
        set OS_boot_config='/boot/grub/grub.cfg'
        multiboot /boot/grub/i386-pc/core.img
    }
    # ----------------------------------
    menuentry 'GRUB MULTIBOOT Manjaro Linux KDE 64-bit (/dev/sda2)' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'grub-multiboot-18d28359-ed0c-404a-b342-385953ebb61b' {
    # ----------------------------------
      savedefault
        insmod part_gpt
        insmod part_msdos
        insmod ext2
		# /dev/sda2: UUID="18d28359-ed0c-404a-b342-385953ebb61b" TYPE="ext4" PARTUUID="a6975cd1-3f1d-4eb6-a173-69caa17b83a2"
		set root='hd0,gpt2'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2  18d28359-ed0c-404a-b342-385953ebb61b
		else
		  search --no-floppy --fs-uuid --set=root 18d28359-ed0c-404a-b342-385953ebb61b
		fi
        set OS_boot_config='/boot/grub/grub.cfg'
        multiboot /boot/grub/i386-pc/core.img
    }

    # ----------------------------------
    menuentry 'GRUB MULTIBOOT Linux Mint MATE  64-bit (/dev/sda5)' --class linuxmint --class gnu-linux --class gnu --class os $menuentry_id_option 'grub-multiboot-08b6acd3-467d-484b-b43c-9253903bb7e6' {
    # ----------------------------------
      savedefault
        insmod part_gpt
        insmod part_msdos
        insmod ext2
        # /dev/sda5: UUID="08b6acd3-467d-484b-b43c-9253903bb7e6" TYPE="ext4" PARTUUID="98d423f1-45ef-47f9-9eae-fa361b2e7c5e"
        set root='hd0,gpt5'
        if [ x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt5 --hint-efi=hd0,gpt5 --hint-baremetal=ahci0,gpt5  08b6acd3-467d-484b-b43c-9253903bb7e6
        else
          search --no-floppy --fs-uuid --set=root 08b6acd3-467d-484b-b43c-9253903bb7e6
        fi
        set OS_boot_config='/boot/grub/grub.cfg'
        multiboot /boot/grub/i386-pc/core.img
    }
}
In the above code is intentioanly valid for both gpt- and bios-msdos-partion tables,
will work for either UEFI or BIOS-systems.
Gigabyte Z77M-D3H, Intel Xeon E3-1240 V2 (Quad core), 32GB RAM,
GeForce GTX 770, Samsung SSD 850 EVO 500GB, Seagate Barracuda 4TB

Post Reply

Return to “MX Help”