Skip to content

Conversation

@bar-g
Copy link

@bar-g bar-g commented Nov 30, 2025

Motivation and Context

The current initramfs script even auto-mounts "canmount=noauto" filesystems.

If there really are any cases that depend on disobeying noauto besides the current bootfs= exception, it's generally preferable to instead allow limited automounting cleanly (as in 17996) for these cases.

This is a "drive-by" filing of a very small, and sensible change, proposed in
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1110397 and #17963

Description

Skip mounting if canmount != on instead of only canmount = off (i.e. also if canmount = noauto).

How Has This Been Tested?

not tested

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Performance enhancement (non-breaking change which improves efficiency)
  • Code cleanup (non-breaking change which makes code smaller or more readable)
  • Quality assurance (non-breaking change which makes the code more robust against bugs)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Library ABI change (libzfs, libzfs_core, libnvpair, libuutil and libzfsbootenv)
  • Documentation (a change to man pages or other documentation)

Checklist:

Signed-off-by: bar-g <[email protected]>
Signed-off-by: bar-g <[email protected]>
Signed-off-by: bar-g <[email protected]>
@bar-g
Copy link
Author

bar-g commented Dec 1, 2025

Closing,

  1. The original author of the script found the logic got corrupted with an intent to make the script portable: initramfs-scripts: more elegant canmount property handling? #17963 (comment)
  2. The relaxation/disobeying of canmount=noauto is still an integral part needed for the active bootfs= boot environment, to auto-mount its sub-filesystems.
  3. So, the case of the bug-report needs to be narrowed down, noauto can't be obeyed unconditionally. (At least until having a proper, selectively applicable, path-limiting canmount= allowance alternative for noauto: canmount bootfs:path -- simple & conflict-free multi-boot / shared zpool support #17996)

@bar-g bar-g closed this Dec 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant