1

How can I remove the Try Ubuntu / Install Ubuntu screen on my 20.04 Persistent USB drive?

Being diverted to this screen increases boot time on both Rufus and mkusb Persistent USB drives.

I would prefer a GRUB menuentry for installing Ubuntu.

C.S.Cameron
  • 19,519

1 Answers1

1

Removing the Try Ubuntu / Install Ubuntu Screen

For mkusb, (12.4.3), the Try/Install screen can be eliminated by removing "maybe-ubiquity" from the persistent grub.cfg menuentry, on a drive made using mkusb. Try/Install has been removed from Persistence option in latest version of mkusb.

For Rufus, (3.10), the Try/Install screen can be eliminated in BIOS mode by overwriting the contents of syslinux.cfg with:

default persistent
label persistent
  say Booting an Ubuntu Persistent session...
  kernel /casper/vmlinuz
  append  file=/cdrom/preseed/ubuntu.seed boot=casper persistent initrd=/casper/initrd quiet splash noprompt --

In UEFI mode the Try/Install screen can be eliminated by removing "maybe-ubiquity" from the persistent grub.cfg menuentry.

For Unetbootin, (677), there is not a problem with Try/Install in BIOS mode, but in UEFI mode the Try/Install screen can be eliminated by removing "maybe-ubiquity" from the first grub.cfg menuentry.

The grub.cfg menuentry for installing Ubuntu is:

menuentry "Install Ubuntu" {
    set gfxpayload=keep
    linux   /casper/vmlinuz  file=/cdrom/preseed/ubuntu.seed boot=casper only-ubiquity quiet splash ---
    initrd  /casper/initrd
}
C.S.Cameron
  • 19,519
  • Once again, Rufus is NOT a "Syslinux" based utility. It simply follows what the distro uses, which means that your explanation above is incorrect, because if you only edit syslinux.cfg, you will still get the prompt in UEFI mode. Please bear in mind that Ubuntu uses Syslinux for BIOS boot and GRUB for UEFI boot, therefore, with utilities that follow the bootloaders used by the ISO exactly (rather than add their own as you seem to believe), you need to edit BOTH grub.cfg and syslinux.cfg. Can you please amend your post to reflect that then? – Akeo Apr 27 '20 at 09:48
  • Also, I don't mind removing maybe-ubiquity when creating persistent drives with Rufus, but as @sudodus pointed out in the related bug report it may also remove other options that users may want, so I want to consider this carefully. – Akeo Apr 27 '20 at 09:51
  • @Akeo: Try what I have written concerning syslinux.cfg, You will see that Try/Install screen has been eliminated from BIOS boot. Yes I have tested in UEFI mode and there was not a problem with Try/Install.once "maybe-ubiquity" has been removed. Removing ."maybe-ubiquity" from grub.cfg does not affect booting in BIOS mode. Editing grub.cfg works in UEFI mode, editing syslinux.cfg works in BIOS mode. Ubuntu can use GRUB just fine for booting in BIOS mode, I prove that here: https://askubuntu.com/questions/1227221/simple-hand-made-persistent-usb-that-boots-either-bios-or-uefi – C.S.Cameron Apr 27 '20 at 13:51
  • @Akeo: If you put an "Install Ubuntu" menuentry in a Syslinux boot menu, like UNetbootin has, the time wasting Try/Install screen becomes redundant – C.S.Cameron Apr 27 '20 at 13:54
  • C.S.Cameron: The problem I had is that the way your post was formulated led to think that, to get a Rufus created drive not to present the prompt in either BIOS or UEFI mode, you only needed to edit the Syslinux/Isolinux config files, which is wrong. To remove the prompt in UEFI mode, you must edit grub.cfg. Only editing syslinux.cfg, which is what you suggested, will change nothing when it comes to UEFI boot. So, once again, you need to edit both files for BIOS+UEFI to remove the prompt, and I just wanted to make sure you rectified that. – Akeo Apr 27 '20 at 16:24
  • As to adding new entries for "install" I don't think I want to do that, as I'm trying to stay as close as possible to the original image when creating a drive, and I don't think I want to remove existing options. Especially, I'm not sure I'm going to bother with editing isolinux/txt.cfg, which is the actual file you want to edit rather than the top level syslinux.cfg which should only point to the isolinux files, as this is more complex than it seems (I'd need to add a full PCRE library to Rufus to edit only the relevant section) and I don't think it's worth it as long as we have UEFI. – Akeo Apr 27 '20 at 16:35
  • @Akeo: My version of 20.04 ISO shows txt.cfg does not mention "maybe-ubiquity", and uses "only-ubiquity" in the "Install Ubuntu" menuentry. The inclusion of an "Install Ubuntu" menuentry in grub goes back many years. I challenge you to find one question in Ask Ubuntu, asking how to change that for an automatic disk check every boot. 20.04 is the first version to include "maybe-ubiquity" in grub.cfg. If you don't think it's worth it as long as we have UEFI, why don't you at least fix GRUB for the benefit of faster UEFI booting? You have already added "persistent" to your grub.cfg. – C.S.Cameron Apr 28 '20 at 03:29
  • according to your proposal, the way to remove the prompt for Syslinux (i.e. BIOS) boot is to add noprompt (which would make sense, since only GRUB seems to have maybe-ubiquity). And what I am saying is that, because I don't want to downgrade the user experience by forcing a single option (which your syslinux.cfg mod would do) adding noprompt for just the label live entry in txt.cfg is tricky, because I don't have a regular expression engine in Rufus, and I expect that adding noprompt to the label live-install sections will have adverse effects. – Akeo Apr 28 '20 at 10:48
  • Therefore, considering that most people would be using UEFI and that only a smaller share of people should still use BIOS, it doesn't seem like a good investment to properly sort the BIOS experience so that people both don't get the UI prompt with persistence but still get the original ISO options (which includes the Syslinux menu choice between try and install), and therefore I am planning to leave BIOS as it. But as I indicated, I am however planning to remove maybe-ubiquity from grub.cfg in a future version of Rufus, as this can be done without affecting the install option. – Akeo Apr 28 '20 at 10:53
  • Please bear in mind that my ONLY concern here is to remove the UI prompt one gets, after X11 has been initialized, that asks the user if they want to try or install Ubuntu, with the idea being that, if the user created a bootable media with persistence, they most likely do not want to see that prompt, because they're unlikely to want to install. So all I am trying to remove is that prompt. Especially, I am not trying to change the initial Syslinux or GRUB boot menus or remove the media validation checks (which are outside the topic of the question you explicitly opened anyway). – Akeo Apr 28 '20 at 11:00