[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Mounting EFI partition: default to `uid=0,gid=0`



On 21/11/2023 at 21:35, Danny van Heumen wrote:

I noticed that the mount-configuration in `/etc/fstab`, by default, relies on an *implicit* assumption for the ownership of the ESP to /boot/efi, i.e.  'root' (uid 0) only because it is executed as part of the boot process.

There is no implicit assumption. The default mount options set up by the installer command that the ESP is automatically mounted at startup, resulting in root ownership. There is no need to add uid and gid mount options.

I agree with Steve: if *you* choose to change the default mount options with "noauto,users", *you* should deal with the consequences and add other mount options if needed.

But I believe that your use case is wrong anyway: upgrading packages requires root privileges so mounting the ESP as a normal user should not be needed. Instead you may use dpkg's pre-invoke and post-invoke options or apt's Pre-Invoke and Post-Invoke options to mount and unmount the ESP, like what can be done to remount /usr read-write during package upgrades on systems where it is mounted read-only by default.


Reply to: