Arch: Use mountpoint=none for containers

Arch: Ignore kernel updates with zfs package

Arch Linux: Notes on single disk bash array and EFI system partition

Signed-off-by: Maurice Zhou <ja@apvc.uk>
This commit is contained in:
Maurice Zhou
2021-03-13 14:05:40 +08:00
committed by Richard Laager
parent 3d4931680d
commit 5b2a3ec69d
2 changed files with 23 additions and 11 deletions

View File

@@ -242,6 +242,10 @@ Preparations
DISK=(/dev/disk/by-id/disk1 /dev/disk/by-id/disk2) DISK=(/dev/disk/by-id/disk1 /dev/disk/by-id/disk2)
For single disk installation, use::
DISK=(/dev/disk/by-id/disk1)
System Installation System Installation
------------------- -------------------
@@ -252,7 +256,7 @@ System Installation
# clear partition table # clear partition table
sgdisk --zap-all $i sgdisk --zap-all $i
# EFI system partition # EFI system partition; must be created
sgdisk -n1:1M:+1G -t1:EF00 $i sgdisk -n1:1M:+1G -t1:EF00 $i
# Boot pool partition # Boot pool partition
@@ -265,7 +269,7 @@ System Installation
# without swap (not recommended) # without swap (not recommended)
#sgdisk -n3:0:0 -t3:BF00 $i #sgdisk -n3:0:0 -t3:BF00 $i
# with BIOS booting # with BIOS booting; can co-exist with EFI
sgdisk -a1 -n5:24K:+1000K -t5:EF02 $i sgdisk -a1 -n5:24K:+1000K -t5:EF02 $i
done done
@@ -428,7 +432,7 @@ System Installation
zfs create \ zfs create \
-o canmount=off \ -o canmount=off \
-o mountpoint=/boot \ -o mountpoint=none \
bpool_$INST_UUID/sys bpool_$INST_UUID/sys
#. Create system root container: #. Create system root container:
@@ -440,7 +444,7 @@ System Installation
zfs create \ zfs create \
-o canmount=off \ -o canmount=off \
-o mountpoint=/ \ -o mountpoint=none \
rpool_$INST_UUID/sys rpool_$INST_UUID/sys
- Encrypted: - Encrypted:
@@ -472,7 +476,7 @@ System Installation
zfs create \ zfs create \
-o canmount=off \ -o canmount=off \
-o mountpoint=/ \ -o mountpoint=none \
-o encryption=on \ -o encryption=on \
-o keylocation=prompt \ -o keylocation=prompt \
-o keyformat=passphrase \ -o keyformat=passphrase \
@@ -680,6 +684,7 @@ System Configuration
curl -L https://archzfs.com/archzfs.gpg | pacman-key -a - curl -L https://archzfs.com/archzfs.gpg | pacman-key -a -
curl -L https://git.io/JtQpl | xargs -i{} pacman-key --lsign-key {} curl -L https://git.io/JtQpl | xargs -i{} pacman-key --lsign-key {}
curl -L https://git.io/JtQp4 > /etc/pacman.d/mirrorlist-archzfs
#. Add archzfs repository:: #. Add archzfs repository::
@@ -691,7 +696,12 @@ System Configuration
Include = /etc/pacman.d/mirrorlist-archzfs Include = /etc/pacman.d/mirrorlist-archzfs
EOF EOF
curl -L https://git.io/JtQp4 > /etc/pacman.d/mirrorlist-archzfs #. Ignore kernel updates::
sed -i 's/#IgnorePkg/IgnorePkg/' /etc/pacman.conf
sed -i "/^IgnorePkg/ s/$/ ${INST_LINVAR} ${INST_LINVAR}-headers zfs-${INST_LINVAR} zfs-utils/" /etc/pacman.conf
Kernel will be manually updated, see Getting Started.
#. Enable networking:: #. Enable networking::

View File

@@ -71,6 +71,7 @@ You can use it as follows.
curl -L https://archzfs.com/archzfs.gpg | pacman-key -a - curl -L https://archzfs.com/archzfs.gpg | pacman-key -a -
curl -L https://git.io/JtQpl | xargs -i{} pacman-key --lsign-key {} curl -L https://git.io/JtQpl | xargs -i{} pacman-key --lsign-key {}
curl -L https://git.io/JtQp4 > /etc/pacman.d/mirrorlist-archzfs
#. Add archzfs repository:: #. Add archzfs repository::
@@ -83,8 +84,6 @@ You can use it as follows.
Include = /etc/pacman.d/mirrorlist-archzfs Include = /etc/pacman.d/mirrorlist-archzfs
EOF EOF
curl -L https://git.io/JtQp4 > /etc/pacman.d/mirrorlist-archzfs
#. Update pacman database:: #. Update pacman database::
pacman -Sy pacman -Sy
@@ -121,12 +120,15 @@ For other kernels or Arch-based distros, use zfs-dkms package.
pacman -Sy zfs-${INST_LINVAR} pacman -Sy zfs-${INST_LINVAR}
#. Hold kernel package from updates:: #. Ignore kernel updates::
sed -i 's/#IgnorePkg/IgnorePkg/' /etc/pacman.conf sed -i 's/#IgnorePkg/IgnorePkg/' /etc/pacman.conf
sed -i "/^IgnorePkg/ s/$/ ${INST_LINVAR} ${INST_LINVAR}-headers/" /etc/pacman.conf sed -i "/^IgnorePkg/ s/$/ ${INST_LINVAR} ${INST_LINVAR}-headers zfs-${INST_LINVAR} zfs-utils/" /etc/pacman.conf
Kernel will be upgraded when an update for ``zfs-linux*`` becomes available. #. To update kernel, run::
INST_LINVAR=$(sed 's|.*linux|linux|' /proc/cmdline | sed 's|.img||g' | awk '{ print $1 }')
pacman -Sy --needed --noconfirm ${INST_LINVAR} ${INST_LINVAR}-headers zfs-${INST_LINVAR}
zfs-dkms package zfs-dkms package
~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~