Howto setup GRUB bootloader password Zorin OS 17

I have to state that I am a professional UNIX/RHEL engineer with 28 years experience. I have worked predominantly with RHEL-variant OSes as opposed to Debian variants such as Zorin, Ubuntu, etc..

Anyway, I installed Zorin OS 17 on a laptop for a friend. Everything configured has been pretty easy. The last component I was working on was the GRUB bootloader.

I have set one of the alternate switches for GRUB to include "--unrestricted" and thankfully, I am not when I need to reboot the OS to full service.

However, the password I have set is not working. I have set it in /etc/grub.d/40_custom with the following lines:

set superusers="root"
password root "password1"

I then execute update-grub and observe that a new /boot/grub/grub.conf is created. The password <as I typed, password1> did not work.

So, I figured that maybe instead I needed to generate an PBKDF2 formatted password hash, using the command: grub-mkpasswd-pbkdf2, and pasted the resulting value in place of "password1" and executed another update-grub.

Still the password is not working.

To be clear in both scenarios, I am prompted for the username, and I provide the value of root and then for the password prompt: password1.

I know how to do this like an expert on RHEL variants but not Zorin OS. Is there a bug, or something I am missing?

Thank you.

This may help. Link: grub2 - How to set password for grub bootloader? - Ask Ubuntu

Thank you @Omnimaxus, but I did try both methods before.

1 Like

Not the question asked, but depending on the level of security you may be trying to achieve for the laptop have you considered installing Zorin using an encrypted LVM or ZFS partition which then prompts you for a password when booting the OS?

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.