Fantastic — glad you’ve decided to do a clean reinstall with LUKS. Below is a safe, copy‑paste friendly, step‑by‑step plan you can follow when you’re ready. It covers which backups to make, exact commands to run, how to format/prepare your external drive, the reinstall steps, and how to restore afterwards — all focused on preserving your apps/settings and giving you an encrypted root install.
I make no assumptions about filenames or device names, so I include commands to discover the correct device (lsblk). Read each step, run the commands you’re comfortable with, and ask if anything looks odd. Save this post (or copy it into a text file) so you can copy commands exactly.
Quick overview (what we’ll do)
1) Back up important data and lists (home, configs, package lists, browser profiles).
2) Create a live USB for Zorin and verify hardware in “Try Zorin” mode.
3) Reinstall Zorin, choose “Erase disk and install Zorin” and enable “Encrypt the new Zorin installation” (LUKS).
4) After the fresh install: backup LUKS header, restore files and reinstall packages.
5) Test and verify.
A — Prepare your external backup medium
- If you will use the external drive ONLY on Linux (recommended): format it ext4.
- If you need Windows access too: format as exFAT (better than NTFS for Linux write support) or NTFS if you prefer Windows tools. (exFAT is simpler.)
Commands to format (replace /dev/sdX1 with the actual partition — I’ll show how to find it):
1) List disks and partitions:
lsblk -o NAME,SIZE,FSTYPE,LABEL,MOUNTPOINT
2) If the external is /dev/sdb and you want ext4:
sudo mkfs.ext4 -L BACKUP /dev/sdb1
3) If you need exFAT (Windows & Linux):
sudo apt update
sudo apt install exfatprogs
sudo mkfs.exfat -n BACKUP /dev/sdb1
4) Create a mountpoint and mount:
sudo mkdir -p /mnt/backup
sudo mount /dev/sdb1 /mnt/backup
check it mounted:
df -h /mnt/backup
B — Back up everything you’ll want to restore (copy/paste commands)
Create a backup folder on your external drive and run these (adjust /mnt/backup to your mount point):
1) Create backup folders
mkdir -p /mnt/backup/zorin-backup
mkdir -p /mnt/backup/zorin-backup/home
mkdir -p /mnt/backup/zorin-backup/config
mkdir -p /mnt/backup/zorin-backup/system-lists
2) Timeshift snapshot (system/state; optional but useful)
sudo timeshift --create --comments "pre-LUKS reinstall" --tags D
3) Backup your home (rsync preserves permissions)
sudo rsync -aAXv --progress /home/ /mnt/backup/zorin-backup/home/
4) Backup app configs, browser profiles, SSH keys, and dotfiles
sudo rsync -aAXv --progress /home/yourusername/.config/ /mnt/backup/zorin-backup/config/.config/
sudo rsync -aAXv --progress /home/yourusername/.local/ /mnt/backup/zorin-backup/config/.local/
sudo rsync -aAXv --progress /home/yourusername/.ssh/ /mnt/backup/zorin-backup/config/ssh/
Brave profile:
sudo rsync -aAXv --progress /home/yourusername/.config/BraveSoftware/ /mnt/backup/zorin-backup/config/brave/
5) Export package lists (useful to re-install apps)
dpkg --get-selections > ~/zbackup/dpkg-selections.txt
apt-mark showmanual > ~/zbackup/manual-packages.txt
mkdir -p /mnt/backup/zorin-backup/system-lists
cp ~/zbackup/dpkg-selections.txt /mnt/backup/zorin-backup/system-lists/
cp ~/zbackup/manual-packages.txt /mnt/backup/zorin-backup/system-lists/
6) Snap / Flatpak lists (if you use them)
snap list > /mnt/backup/zorin-backup/system-lists/snap-list.txt
flatpak list --app > /mnt/backup/zorin-backup/system-lists/flatpak-list.txt
7) Save apt sources
sudo cp -a /etc/apt/sources.list* /mnt/backup/zorin-backup/system-lists/
8) (Optional) Save /etc and other custom system files
sudo rsync -aAXv --progress /etc/ /mnt/backup/zorin-backup/etc-backup/
9) Verify backup contents
ls -la /mnt/backup/zorin-backup
du -sh /mnt/backup/zorin-backup/home
Notes:
- Replace yourusername with your actual username in the commands.
- These rsync commands create a full file-by-file copy of /home and configs. They’re fast and reliable.
- If you have large media (music, video), consider backing that up separately.
C — Create lists to help reinstall apps later (explain restore approach)
When you restore:
- Use the package lists to reinstall apt packages.
- Recreate snaps and flatpaks from saved lists.
- Restore your home folder via rsync back to /home and set ownership:
sudo rsync -aAXv --progress /mnt/backup/zorin-backup/home/ /home/
sudo chown -R yourusername:yourusername /home/yourusername
To reinstall packages (after reinstall):
restore package selections (careful: review file first):
sudo dpkg --set-selections < ~/zbackup/dpkg-selections.txt
sudo apt-get -u dselect-upgrade
OR reinstall manual packages:
xargs -a ~/zbackup/manual-packages.txt sudo apt install -y
D — Create and verify Zorin live USB
- Use Rufus (Windows) or BalenaEtcher. If using Rufus, let it add any recommended helpers if it asks — it’s fine.
- Boot the USB, choose “Try Zorin” and verify Wi‑Fi, touchpad, keyboard, suspend/resume, audio, display brightness, and external devices you need.
E — Reinstall Zorin with LUKS (the guided steps you’ll see in installer)
1) Boot live USB → click Install Zorin.
2) When the installer shows “Installation type” choose “Erase disk and install Zorin.”
3) Check “Encrypt the new Zorin installation” (LUKS). You’ll be prompted for an encryption passphrase — choose a strong passphrase and store it safely (password manager + printed copy+ offline USB).
4) Continue install and reboot when done.
F — After first boot of encrypted system — backup LUKS header (very important)
Find your encrypted partition name:
lsblk -f
You will see the encrypted partition (likely /dev/sdaX) with TYPE luks. Run:
replace /dev/sdaX with the device you found, and /mnt/backup with your external
sudo cryptsetup luksHeaderBackup /dev/sdaX --header-backup-file /mnt/backup/zorin-backup/luks-header-backup.img
Store that header image offline (USB in safe place or offline backup). If your LUKS header corrupts you lose data — header backup can save you.
G — Restore files and packages (post-install)
1) Mount your external backup and rsync home back:
sudo mount /dev/sdb1 /mnt/backup # if not already mounted
sudo rsync -aAXv --progress /mnt/backup/zorin-backup/home/ /home/
sudo chown -R yourusername:yourusername /home/yourusername
2) Restore configs (careful with overwriting):
sudo rsync -aAXv --progress /mnt/backup/zorin-backup/config/.config/ /home/yourusername/.config/
fix ownership:
sudo chown -R yourusername:yourusername /home/yourusername/.config
3) Reinstall packages from saved lists (see above). Review lists before running mass installs.
4) Reinstall snaps:
while read snapname; do sudo snap install "$snapname"; done < /mnt/backup/zorin-backup/system-lists/snap-list.txt
(You’ll need to parse this file — I can give exact commands if you want.)
H — Extra recommended steps
- After install and restore, run updates:
sudo apt update && sudo apt upgrade -y
- Reinstall Timeshift (if you used it) and create a new snapshot.
- Reinstall fwupd, tlp, and any ThinkPad specific packages:
sudo apt install fwupd tlp tlp-rdw
sudo systemctl enable --now tlp
sudo fwupdmgr refresh && sudo fwupdmgr get-updates && sudo fwupdmgr update
I — Final checks
- Verify your files are present and owned by you:
ls -la /home/yourusername
- Test booting and that you’re prompted for LUKS passphrase at boot.
- Test battery, suspend/resume, Wi‑Fi and devices.
J — Some extra safety items & notes
- Keep at least two copies of backups (external + secondary USB) until you’ve confirmed the new system is good.
- Keep the LUKS header backup offline and do NOT keep it on the same encrypted disk.
- If you want, I can produce a small restore script to simplify the package reinstallation after you paste your saved manual-packages.txt.
K — If you want me to produce exact copy/paste commands tailored to your environment
Tell me:
1) The mount point you’ll use for the external drive (e.g., /mnt/backup).
2) Your username (so I can produce exact chown commands).
3) Whether you prefer ext4 (Linux-only) or exFAT/NTFS (cross-platform) for the external drive.
I’ll generate a single clipboard‑friendly block of commands that you can paste into a terminal (and warn before anything destructive). If you want, I can also create a printable checklist.
Enjoy your nap — when you’re back I’ll prepare the exact commands for your setup (or a script) and then walk you through the installer and the LUKS header backup step.