10_linux_zfs: empty bootmenu if POSIXLY_CORRECT
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
grub2 (Ubuntu) |
Triaged
|
Low
|
Unassigned |
Bug Description
If one has POSIXLY_CORRECT env var set (which is the case for all our admin/operator accounts) and one calls /usr/sbin/
The root cause for this is /etc/grub.
Since Linux mount requires arguments given in a posixly incorrect "order", a script should always unset POSIXLY_CORRECT, when it is going to call mount. Otherwise mount errors out, and because the script has 'set -e', the script gets aborted immediately.
NOTE: 'zfs mount ...' also calls 'mount', so same requirement applies to 'zfs {mount|create} ...'
Env:
Distributor ID: Ubuntu
Description: Ubuntu 20.04.1 LTS
Release: 20.04
Codename: focal
Linux box 5.4.0-48-generic #52-Ubuntu SMP Thu Sep 10 10:58:49 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
with latest updates installed.
I think I disagree here, scripts should not unset POSIXLY_CORRECT. Accounts should not set POSIXLY_CORRECT, it's going to wreak havoc in a lot of places. Having to accomodate for such unusual end user configurations in every shell scripts seems out of scope.