Add /etc/fstab to initramfs (#447)

That way it can mount a root volume with mountpoint=legacy.
pull/457/head
Lucas Ransan 3 years ago committed by GitHub
parent 3401f8a294
commit da8c8c699c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      src/zfs-utils/zfs-utils.initcpio.hook
  2. 1
      src/zfs-utils/zfs-utils.initcpio.install

@ -129,7 +129,7 @@ zfs_mount_handler () {
local node="$1"
local rootmnt=$(zfs get -H -o value mountpoint "${ZFS_DATASET}")
local tab_file="${node}/etc/fstab"
local tab_file="/etc/fstab"
local zfs_datasets="$(zfs list -H -o name -t filesystem -r ${ZFS_DATASET})"
# Mount the root, and any child datasets

@ -41,6 +41,7 @@ build() {
[[ -f /etc/zfs/zpool.cache ]] && cp "/etc/zfs/zpool.cache" "${BUILDROOT}/etc/zfs/zpool.cache.org"
[[ -f /etc/modprobe.d/zfs.conf ]] && add_file "/etc/modprobe.d/zfs.conf"
[[ -f /etc/fstab ]] && add_file "/etc/fstab"
}
help() {

Loading…
Cancel
Save