First experiment with installing on BTRFS

You need to add cd os-prober after git clone …

2 Likes

Thanks! Just added it.

3 Likes

I’ve installed Endeavour on 2 drives (GPT) both with btrfs (and both with their own /boot/efi fat32) and they see each other (only after the manjaro os-prober) so it’s a success.

But they can’t see my KDE Neon (Ubuntu 20.04) partition on a 3rd drive which is also btrfs with a fat32 boot, I know this isn’t the same thing, just saying !

OK, it is not a general solution yet. But sounds quite strange.

Do you have any idea why they can’t see KDE Neon?

I’ve got a pending update now for os-prober 1-77-1 >> 1-77-2. Will this overwrite Manjaro’s os-prober that I installed?

Yes, it should do that as far as I know.
Should check what they have changed.
However, it is also easy to test both and use the one that works for you.

EDIT: os-prober from Arch is already 1.77-2. Manjaro has 1.77-1, and that makes it always get the Arch version.
You may consider adding IgnorePkg = os-prober into /etc/pacman.conf.

Alternatively, you could create a small script that:

  • checks if Arch version is different from the Manjaro version
  • is so, then reinstall Manjaro version

You just need to run that script if os-prober is updated by Arch. To optimize a bit, the script could be executed always when grub-mkconfig is run…

So either way, a bit more work than usual.

2 Likes

@manuel I’m not sure (I’ve checked it does have lsb-release) but after reading online it seems to have to do with having multiple kernels with different names which ubuntu’s grub takes care of so it may be using a different schema.
However, due to the multiple kernels, I think it would be far less problematic to use Ubuntu’s grub to find the Arch installs whose kernel names don’t change (which it won’t do coz it obviously doesn’t have the Manjaro patch). So that won’t work until Ubuntu patch their grub, groan!
Anyway, if you want I’ll try and test things but it’s really not a bother to me.

1 Like

I’m not “pushing” you to test this, but of course if you have the willingness and time to do that, I’d appreciate! :smile:
But it is totally up to you.

1 Like

Ok sure, what do you want me to check?
This is Neon’s /boot:

config-5.4.0-45-generic      memtest86+.elf
config-5.4.0-47-generic      memtest86+_multiboot.bin
efi                          System.map-5.4.0-45-generic
grub                         System.map-5.4.0-47-generic
initrd.img                   vmlinuz
initrd.img-5.4.0-45-generic  vmlinuz-5.4.0-45-generic
initrd.img-5.4.0-47-generic  vmlinuz-5.4.0-47-generic
initrd.img.old               vmlinuz.old
memtest86+.bin

This is /boot/grub:

fonts  gfxblacklist.txt  grub.cfg  grubenv  themes  unicode.pf2  x86_64-efi

Grub.cfg

#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
  set have_grubenv=true
  load_env
fi
if [ "${initrdfail}" = 2 ]; then
   set initrdfail=
elif [ "${initrdfail}" = 1 ]; then
   set next_entry="${prev_entry}"
   set prev_entry=
   save_env prev_entry
   if [ "${next_entry}" ]; then
      set initrdfail=2
   fi
fi
if [ "${next_entry}" ] ; then
   set default="${next_entry}"
   set next_entry=
   save_env next_entry
   set boot_once=true
else
   set default="0"
fi

if [ x"${feature_menuentry_id}" = xy ]; then
  menuentry_id_option="--id"
else
  menuentry_id_option=""
fi

export menuentry_id_option

if [ "${prev_saved_entry}" ]; then
  set saved_entry="${prev_saved_entry}"
  save_env saved_entry
  set prev_saved_entry=
  save_env prev_saved_entry
  set boot_once=true
fi

function savedefault {
  if [ -z "${boot_once}" ]; then
    saved_entry="${chosen}"
    save_env saved_entry
  fi
}
function initrdfail {
    if [ -n "${have_grubenv}" ]; then if [ -n "${partuuid}" ]; then
      if [ -z "${initrdfail}" ]; then
        set initrdfail=1
        if [ -n "${boot_once}" ]; then
          set prev_entry="${default}"
          save_env prev_entry
        fi
      fi
      save_env initrdfail
    fi; fi
}
function recordfail {
  set recordfail=1
  # GRUB lacks write support for btrfs, so recordfail support is disabled.
}
function load_video {
  if [ x$feature_all_video_module = xy ]; then
    insmod all_video
  else
    insmod efi_gop
    insmod efi_uga
    insmod ieee1275_fb
    insmod vbe
    insmod vga
    insmod video_bochs
    insmod video_cirrus
  fi
}

if [ x$feature_default_font_path = xy ] ; then
   font=unicode
else
insmod part_gpt
insmod btrfs
set root='hd3,gpt2'
if [ x$feature_platform_search_hint = xy ]; then
  search --no-floppy --fs-uuid --set=root --hint-bios=hd3,gpt2 --hint-efi=hd3,gpt2 --hint-baremetal=ahci3,gpt2  f8ba0579-95d1-4242-abe1-31b8436b0006
else
  search --no-floppy --fs-uuid --set=root f8ba0579-95d1-4242-abe1-31b8436b0006
fi
    font="/@/usr/share/grub/unicode.pf2"
fi

if loadfont $font ; then
  set gfxmode=auto
  load_video
  insmod gfxterm
fi
terminal_output gfxterm
insmod part_gpt
insmod btrfs
set root='hd3,gpt2'
if [ x$feature_platform_search_hint = xy ]; then
  search --no-floppy --fs-uuid --set=root --hint-bios=hd3,gpt2 --hint-efi=hd3,gpt2 --hint-baremetal=ahci3,gpt2  f8ba0579-95d1-4242-abe1-31b8436b0006
else
  search --no-floppy --fs-uuid --set=root f8ba0579-95d1-4242-abe1-31b8436b0006
fi
insmod gfxmenu
loadfont ($root)/@/boot/grub/themes/breeze/unifont-bold-16.pf2
loadfont ($root)/@/boot/grub/themes/breeze/unifont-regular-14.pf2
loadfont ($root)/@/boot/grub/themes/breeze/unifont-regular-16.pf2
loadfont ($root)/@/boot/grub/themes/breeze/unifont-regular-32.pf2
insmod png
set theme=($root)/@/boot/grub/themes/breeze/theme.txt
export theme
if [ "${recordfail}" = 1 ] ; then
  set timeout=5
else
  if [ x$feature_timeout_style = xy ] ; then
    set timeout_style=menu
    set timeout=5
  # Fallback normal timeout code in case the timeout_style feature is
  # unavailable.
  else
    set timeout=5
  fi
fi
if [ $grub_platform = efi ]; then
  set timeout=5
  if [ x$feature_timeout_style = xy ] ; then
    set timeout_style=menu
  fi
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
function gfxmode {
        set gfxpayload="${1}"
        if [ "${1}" = "keep" ]; then
                set vt_handoff=vt.handoff=7
        else
                set vt_handoff=
        fi
}
if [ "${recordfail}" != 1 ]; then
  if [ -e ${prefix}/gfxblacklist.txt ]; then
    if hwmatch ${prefix}/gfxblacklist.txt 3; then
      if [ ${match} = 0 ]; then
        set linux_gfx_mode=keep
      else
        set linux_gfx_mode=text
      fi
    else
      set linux_gfx_mode=text
    fi
  else
    set linux_gfx_mode=keep
  fi
else
  set linux_gfx_mode=text
fi
export linux_gfx_mode
menuentry 'Neon GNU/Linux' --class neon --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-f8ba0579-95d1-4242-abe1-31b8436b0006' {
        recordfail
        load_video
        gfxmode $linux_gfx_mode
        insmod gzio
        if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
        insmod part_gpt
        insmod btrfs
        set root='hd3,gpt2'
        if [ x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd3,gpt2 --hint-efi=hd3,gpt2 --hint-baremetal=ahci3,gpt2  f8ba0579-95d1-4242-abe1-31b8436b0006
        else
          search --no-floppy --fs-uuid --set=root f8ba0579-95d1-4242-abe1-31b8436b0006
        fi
        linux   /@/boot/vmlinuz-5.4.0-47-generic root=UUID=f8ba0579-95d1-4242-abe1-31b8436b0006 ro rootflags=subvol=@ resume=UUID=80b9f07f-0593-48ae-8621-959d21dbfe3f quiet splash $vt_handoff
        initrd  /@/boot/initrd.img-5.4.0-47-generic
}
submenu 'Advanced options for Neon GNU/Linux' $menuentry_id_option 'gnulinux-advanced-f8ba0579-95d1-4242-abe1-31b8436b0006' {
        menuentry 'Neon GNU/Linux, with Linux 5.4.0-47-generic' --class neon --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-5.4.0-47-generic-advanced-f8ba0579-95d1-4242-abe1-31b8436b0006' {
                recordfail
                load_video
                gfxmode $linux_gfx_mode
                insmod gzio
                if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
                insmod part_gpt
                insmod btrfs
                set root='hd3,gpt2'
                if [ x$feature_platform_search_hint = xy ]; then
                  search --no-floppy --fs-uuid --set=root --hint-bios=hd3,gpt2 --hint-efi=hd3,gpt2 --hint-baremetal=ahci3,gpt2  f8ba0579-95d1-4242-abe1-31b8436b0006
                else
                  search --no-floppy --fs-uuid --set=root f8ba0579-95d1-4242-abe1-31b8436b0006
                fi
                echo    'Loading Linux 5.4.0-47-generic ...'
                linux   /@/boot/vmlinuz-5.4.0-47-generic root=UUID=f8ba0579-95d1-4242-abe1-31b8436b0006 ro rootflags=subvol=@ resume=UUID=80b9f07f-0593-48ae-8621-959d21dbfe3f quiet splash $vt_handoff
                echo    'Loading initial ramdisk ...'
                initrd  /@/boot/initrd.img-5.4.0-47-generic
        }
        menuentry 'Neon GNU/Linux, with Linux 5.4.0-45-generic' --class neon --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-5.4.0-45-generic-advanced-f8ba0579-95d1-4242-abe1-31b8436b0006' {
                recordfail
                load_video
                gfxmode $linux_gfx_mode
                insmod gzio
                if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
                insmod part_gpt
                insmod btrfs
                set root='hd3,gpt2'
                if [ x$feature_platform_search_hint = xy ]; then
                  search --no-floppy --fs-uuid --set=root --hint-bios=hd3,gpt2 --hint-efi=hd3,gpt2 --hint-baremetal=ahci3,gpt2  f8ba0579-95d1-4242-abe1-31b8436b0006
                else
                  search --no-floppy --fs-uuid --set=root f8ba0579-95d1-4242-abe1-31b8436b0006
                fi
                echo    'Loading Linux 5.4.0-45-generic ...'
                linux   /@/boot/vmlinuz-5.4.0-45-generic root=UUID=f8ba0579-95d1-4242-abe1-31b8436b0006 ro rootflags=subvol=@ resume=UUID=80b9f07f-0593-48ae-8621-959d21dbfe3f quiet splash $vt_handoff
                echo    'Loading initial ramdisk ...'
                initrd  /@/boot/initrd.img-5.4.0-45-generic
        }
}

### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/10_linux_zfs ###
### END /etc/grub.d/10_linux_zfs ###

### BEGIN /etc/grub.d/20_linux_xen ###

### END /etc/grub.d/20_linux_xen ###

### BEGIN /etc/grub.d/20_memtest86+ ###
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/30_uefi-firmware ###
menuentry 'UEFI Firmware Settings' $menuentry_id_option 'uefi-firmware' {
        fwsetup
}
### END /etc/grub.d/30_uefi-firmware ###

### BEGIN /etc/grub.d/40_custom ###
# 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.
### END /etc/grub.d/40_custom ###

### BEGIN /etc/grub.d/41_custom ###
if [ -f  ${config_directory}/custom.cfg ]; then
  source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f  $prefix/custom.cfg ]; then
  source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###

I think this should do it for the moment. But then should i keep track of Manjaro’s os-probers’s updates on the GitLab page?

@pebcak Did you check the difference? I am sure I remember that the version numbers of Arch and Manjaro were the same when an author online tested this and Manjaro’s patch wasn’t in Arch’s files even though they were the same version.

No, I haven’t yet but I’ll do that.

Thanks! I have already put Arch’s on the ignore list.

1 Like

And if I’m right then yes you should block Arch’s os-prober and manually update Manjaro’s as you deem necessary.

1 Like

Yes.
That is quite easy to do if you clone the gitlab repository:

mkdir -p ~/where/you/want/to/keep/this
cd ~/where/you/want/to/keep/this
# Assuming you have already done this: git clone ...
git pull

If git pull says something has changed, then Manjaro has a new version. The same procedure can be applied again, starting with command cd os-prober.

1 Like

Thanks @manuel! This is great! I’ll keep a note of your post and will check up on the updates on a regular basis.

1 Like

If os-prober is ignored, then pacman will complain about it being ignored, but lets you install it.
If os-prober is not ignored, pacman will complain too, but lets you “downgrade”.

So not ignoring might be better for the future…

1 Like

I am pretty much done with the partition scheme of the disk. What would be your recommendation for the filesystem that I will be using for data to be shared between the systems installed? EXT4 or btrfs? Or else?

I would also like to ask, is btrfs, or as I like to call it, da butter, the future of Linux, ie default among distros, or will it remain an alternative much like ZFS has been?

1 Like

When I tried zfs on BSD it’s use case was rollbacks on the fly which is great for programmers, and boot recovery from a snapshot for everything else but boot recovery can also be achieved by a package manager (ie Moss which is being written for SerpentOS right now) so I guess btrfs / zfs may be overkill for a home user.
It’s very different on servers, zfs is seriously loved in the BSD world so btrfs could maybe attain those same heights.
It does confuse me though that Ubuntu have taken zfs as their ‘strategy’, and Fedora and Suse have gone btrfs.
Only time will tell, but it should be about solving a problem, not shoe-horning in something with more technical advantages that the user doesn’t need.

2 Likes

BTW on BSD, ZFS could rollback individual files in their file manager simply by clicking on the file and moving a slider to an earlier time, this is what was so good for programmers. There’s a good interview with Brian Lunduke couple of years ago with a BSD engineer trying to convince him of the amazing zfs and that was all he could convince him that applied to a normal user!

2 Likes