You are not logged in.
I am fairly new to Arch and after a fresh install I decided to learn how to use snapshots as a way of protecting my system during updates. As a test run I created a snapshot using
lvcreate -L1G -n snap_root -s /dev/VolGroup/root
This went smoothly, and I upgraded the system with pacman -Syu with no problems. I then tried to merge the snapshot to revert to the point in time before the upgrade using
lvconvert --merge /dev/VolGroup/snap_root
Again, no errors but I have to reboot first for the merge to happen. On reboot, during the startup messages, I get
Mounting /boot...
[FAILED] Failed to mount /boot.
See 'systemctl status boot.mount' for details.
A few more messages come after that and then I am dropped in emergency mode, however the keyboard doesn't work, so I cannot log in to look at the status of boot.mount. I tried chrooting into the system using the live cd however systemctl commands don't work in chroot as I have learned. I want to redo the install and try some other options but I first would like to ask you guys to try and see what the problem is so I can avoid making the same mistakes in the future. Do I have to make a snapshot of the boot partition as well when reverting a root snapshot? From what I've read online you don't, but that would make sense.
Please help if you can!
Thank you so much!
Last edited by carryingweight (2022-09-28 02:54:02)
Offline
bump
Offline
bump
Don't do that. https://wiki.archlinux.org/title/Genera … es#Bumping
Offline
Extra information
Output of
blkid /dev/bootpartition
/dev/boot: UUID="D80F-D66E" BLOCK_SIZE="512" TYPE="vfat" PARTLABEL="EFI system partition" PARTUUID="07b57492-71ed-44fd-9e09-c89508049b4a"
Output of
cat /etc/fstab
# /dev/bootpartition
UUID=D80F-D66E /boot vfat rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro 0 2
Last edited by carryingweight (2022-09-26 04:38:41)
Offline
If /boot is separate and you didn't roll that back too, then it is possible you updated your kernel, installed a new kernel to /boot, then rolled back snapshot for /, removing the new kernel's modules - so you are booting into a system where kernel modules are not available, and that could cause stuff to stop working, like mounting a filesystem that needs a module to be loaded first.
Snapshots are nice but you have to consider side effects, it does not just revert your system update but also everything else that is going on on that partition, so - your logs are gone, too, and perhaps even databases, mails, et cetera if such are also stored there. It also reverts passwords (if any users changed theirs) and so on and so forth.
Maybe better keep snapshots to assist in making backups... if you actually have to revert something, if the filesystem isn't completely corrupt and unusable, you can just mount both side by side then be selective about what you restore to specifically fix your issue, rather than smashing the problem with a hammer (revert everything regardless whether it's part of the problem).
----
Edit:: You can check lsmod if the vfat module is present, if it's not there, and modprobe also fails loading it, then that is your problem. In this situation you can chroot from a livecd, make sure / and /boot is mounted inside the chroot, and reinstall kernel again. You can also edit your mkinitcpio.conf to forcibly include, and load such critical modules (for filesystems, networking, etc.) so the system is at least usable even if the modules were somehow missing from the real root.
Last edited by frostschutz (2022-09-26 09:02:25)
Offline
If /boot is separate and you didn't roll that back too, then it is possible you updated your kernel, installed a new kernel to /boot, then rolled back snapshot for /, removing the new kernel's modules - so you are booting into a system where kernel modules are not available, and that could cause stuff to stop working, like mounting a filesystem that needs a module to be loaded first.
This worked perfectly, thank you so much, I thought there must be some problem with /boot. I used this pacman hook https://wiki.archlinux.org/title/System … _partition to backup /boot, but it was never saved in the root snapshot, and I think I had to change the When parameter to PreTransaction, as it only backed up the updated kernel which was causing the problem.
Snapshots are nice but you have to consider side effects, it does not just revert your system update but also everything else that is going on on that partition, so - your logs are gone, too, and perhaps even databases, mails, et cetera if such are also stored there. It also reverts passwords (if any users changed theirs) and so on and so forth.
Maybe better keep snapshots to assist in making backups... if you actually have to revert something, if the filesystem isn't completely corrupt and unusable, you can just mount both side by side then be selective about what you restore to specifically fix your issue, rather than smashing the problem with a hammer (revert everything regardless whether it's part of the problem).
Yes, I agree, because I am new to Arch I was just trying to understand how snapshots work and make sure I can use them correctly before actually implementing them in my system. So you think I should only use snapshots as a last resort, e.g., say a system update breaks my everything, I should mount and then selectively try and restore first? Is there a better way of making backups you know about while still using LVM with ext4 fs (btrfs is not an option, and ZFS is too complex for me right now)? A full backup would be preferable but the size of the iso and the time it takes are just not practical.
Again, many thanks!
Offline