proxmox backup client only one file

Evgenii36ru

New Member
Oct 25, 2021
20
0
1
42
Hello.
Can proxmox backup client backup files? there is a need to backup one large file. The file name changes every day. I did not find it in the documentation. Thank you
 
Not tested it but should be possible. Did you try to point the PBS client to a specific file instead of a folder?
If that is not working the PBS client got exclude filters which can be inverted so you can specify to only backup specific files matching a glob pattern.
 
Sorry for reopening an old thread. But apparently this doesn't work anymore in PBS 3.1, making me think that the feature has been intentionally disabled.

Code:
# proxmox-backup-client backup archive.pxar:/etc/hostname --repository 'backup@pbs!pbs-client-test@pbs-server.test.local:localrepo'
Error: got unexpected file type (expected directory)

whereas backing up the whole /etc directory with the above command works fine.
 
if you want to backup a single file, you need to do so as "image"/fixed-size index, not "host"/dynamic-sized index. in your example, instead of NAME.pxar:/etc/hostname you'd need to use NAME.img:/etc/hostname, or, for small files, NAME.conf:/etc/hostname (the last one is not chunked at all, but stored as-is in the snapshot dir as "blob", like the guest/firewall configs are in case of a PVE CT/VM backup).
 
I guess the last example there is confusing since it refers to block devices, but it's actually a "raw single file" mode that works for block devices, image files, or any other file you want to back up on its own :)