Proxmox Backup Client Using Debian Live Sanity Check

mrdmadev

Member
Oct 15, 2020
16
1
8
I just used the Proxmox Backup Client using Debian Live for the first time by using the docs and a little trial and error. What I would like to gain by posting my experience is a little sanity check - or rather, is there a better or more efficient way than the approach I am outlining below.

I bought a brand new laptop with Windows 10 and before setting it up I wanted to do a complete backup in it's pristine "not set up state" before I start its install/setup process.

Here are the steps I followed based on the Proxmox Documentation and a little trial an error.

Created dataset on PBS through PBS's GUI.

booted to debian live 11.3 xfce non free on new laptop
add PBS client repo to sources
Bash:
sudo nano /etc/apt/sources.list.d/pbs-client.list
added
Code:
deb http://download.proxmox.com/debian/pbs-client bullseye main
add trusted key and install PBS client
Code:
sudo wget https://enterprise.proxmox.com/debian/proxmox-release-bullseye.gpg -O /etc/apt/trusted.gpg.d/proxmox-release-bullseye.gpg
sudo apt update
sudo apt-get install proxmox-backup-client

find disk and/or partitions to backup
Code:
lsblk
nvme0n1     259:0    0 953.9G  0 disk
├─nvme0n1p1 259:1    0   300M  0 part
├─nvme0n1p2 259:2    0   128M  0 part
├─nvme0n1p3 259:3    0 933.2G  0 part
├─nvme0n1p4 259:4    0   900M  0 part
└─nvme0n1p5 259:5    0  19.3G  0 part

changed my hostname since this is a live boot

Code:
sudo hostname MSIPrestige14

multi partition backup - must make mount points for each partition?

Code:
sudo mkdir /mnt/nvme0n1p1
sudo mkdir /mnt/nvme0n1p2
sudo mkdir /mnt/nvme0n1p3
sudo mkdir /mnt/nvme0n1p4
sudo mkdir /mnt/nvme0n1p5

Code:
sudo mount /dev/nvme0n1p1 /mnt/nvme0n1p1
sudo mount /dev/nvme0n1p2 /mnt/nvme0n1p2 - problems with this one - need to figure out what kind or partition - mount: /mnt/nvme0n1p2: wrong fs type, bad option, bad superblock on /dev/nvme0n1p2, missing codepage or helper program, or other error.
sudo mount /dev/nvme0n1p3 /mnt/nvme0n1p3
sudo mount /dev/nvme0n1p4 /mnt/nvme0n1p4
sudo mount /dev/nvme0n1p5 /mnt/nvme0n1p5

Code:
proxmox-backup-client backup nvme0n1p1.pxar:/mnt/nvme0n1p1 --repository 192.168.2.6:MSIPrestige14
proxmox-backup-client backup nvme0n1p2.pxar:/mnt/nvme0n1p2 --repository 192.168.2.6:MSIPrestige14
proxmox-backup-client backup nvme0n1p3.pxar:/mnt/nvme0n1p3 --repository 192.168.2.6:MSIPrestige14
proxmox-backup-client backup nvme0n1p4.pxar:/mnt/nvme0n1p4 --repository 192.168.2.6:MSIPrestige14
proxmox-backup-client backup nvme0n1p5.pxar:/mnt/nvme0n1p5 --repository 192.168.2.6:MSIPrestige14

As I see it, the only problem with this approach is as I might change partitions on the NVME drive, the partition numbers may change in their purpose, and therefore might be difficult to track which partitions are which on each backup moving forward. Is there a better way? Is there a way to mount the NVME as a block device and then backup the block device? Are there options/flags with the pbs client to add comments on the command-line? Any other tips. tricks, or ideas?

Thanks in advance.
 
two things:

i'd backup the whole nvme as block device (as you asked). in that case you must not mount it, but use it directly:
Code:
proxmox-backup-client backup nvme.img:/dev/nvme0n1
that makes a backup of the whole block device with 4MiB chunks (like PVE vms are backed up)

if you stll want to make file-based backups, i'd put all pxars into a single backup invocation:
Code:
proxmox-backup-client backup nvme0n1p1.pxar:/mnt/nvme0n1p1 nvme0n1p2.pxar:/mnt/nvme0n1p2 ...

this way you have only a single snapshot containing all the data

Are there options/flags with the pbs client to add comments on the command-line? Any other tips. tricks, or ideas?
you can set the comment after making the backup with
Code:
proxmox-backup-client snapshot notes update <snapshot> <notes>
 
two things:

i'd backup the whole nvme as block device (as you asked). in that case you must not mount it, but use it directly:
Code:
proxmox-backup-client backup nvme.img:/dev/nvme0n1
that makes a backup of the whole block device with 4MiB chunks (like PVE vms are backed up)

if you stll want to make file-based backups, i'd put all pxars into a single backup invocation:
Code:
proxmox-backup-client backup nvme0n1p1.pxar:/mnt/nvme0n1p1 nvme0n1p2.pxar:/mnt/nvme0n1p2 ...

this way you have only a single snapshot containing all the data


you can set the comment after making the backup with
Code:
proxmox-backup-client snapshot notes update <snapshot> <notes>

Wow! Great tips! Thank you so much!
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!