Commit before push

This commit is contained in:
Cyteen May 2019-07-05 11:56:58 +01:00
parent ef5637fe5f
commit 825168fa70
1 changed files with 28 additions and 8 deletions

View File

@ -24,10 +24,29 @@ mount -t proc /proc ${ZFS_HOME}/proc
mkdir -p ${ZFS_HOME}/run mkdir -p ${ZFS_HOME}/run
mount -o bind /run ${ZFS_HOME}/run mount -o bind /run ${ZFS_HOME}/run
# Rebuild drivers chroot ${ZFS_HOME} bash -c 'apt-get install -y --reinstall dkms spl-dkms gcc-6 libc6-dev debhelper dh-autoreconf linux-headers-4.9.0-4-all-amd64'
chroot ${ZFS_HOME} dpkg-reconfigure spl-dkms
chroot ${ZFS_HOME} bash -c 'apt-get install -y --reinstall zfs-dkms zfs-initramfs zfsnap zfsutils-linux busybox'
chroot ${ZFS_HOME} bash -c "cat > /usr/share/initramfs-tools/conf.d/zfs" << 'EOF'
for x in $(cat /proc/cmdline)
do
case $x in
root=ZFS=*)
BOOT=zfs
;;
esac
done
EOF
chroot ${ZFS_HOME} dpkg-reconfigure zfs-dkms chroot ${ZFS_HOME} dpkg-reconfigure zfs-dkms
chroot ${ZFS_HOME} bash -c 'apt-get -y -f install'
# Rebuild drivers
#chroot ${ZFS_HOME} dpkg-reconfigure spl-dkms
#chroot ${ZFS_HOME} dpkg-reconfigure zfs-dkms
# Update initramfs # Update initramfs
# Error: live system without live media mounted as /lib/live/mount/medium # Error: live system without live media mounted as /lib/live/mount/medium
chroot ${ZFS_HOME} bash -c 'apt-get remove -y live-tools' chroot ${ZFS_HOME} bash -c 'apt-get remove -y live-tools'
@ -39,10 +58,11 @@ chroot ${ZFS_HOME} grub-mkdevicemap
chroot ${ZFS_HOME} grub-probe / chroot ${ZFS_HOME} grub-probe /
chroot ${ZFS_HOME} update-grub chroot ${ZFS_HOME} update-grub
chroot ${ZFS_HOME} lsinitramfs /boot/initrd.img-*
umount ${ZFS_HOME}/dev umount -lf ${ZFS_HOME}/dev
umount ${ZFS_HOME}/dev/pts umount -lf ${ZFS_HOME}/dev/pts
umount ${ZFS_HOME}/sys umount -lf ${ZFS_HOME}/sys
umount ${ZFS_HOME}/proc umount -lf ${ZFS_HOME}/proc
umount ${ZFS_HOME}/run umount -lf ${ZFS_HOME}/run
umount ${ZFS_HOME} umount -lf ${ZFS_HOME}