On Saturday, February 10, 2018 at 6:51:47 AM UTC+1, 
cybe...@national.shitposting.agency wrote:
> I have a usb drive attached to sys-usb, lets say its mounted at /mnt on 
> sys-usb and im trying to backup a vm named MyVm
> from dom0 the command:
> 
> sudo qvm-backup sys-usb:/mnt MyVm
> 
> returns the error: 
> 
> The backup directory does not exist
> 
> how can i make a backup to USB when USB devices are not exposed to dom0?

I haven't seen that manner of command used for Qubes backup before. It looks 
like you're mixing together the qvm-block, qvm-usb, qvm-pci command attributes 
and options with the qvm-backup and qvm-backup-restore command attributes and 
options, which are different in this regard. See the commands below to see what 
I mean by different. 


qvm-backup -d name-of-AppVM-to-handle-backup '/path-to-backup-location' 

Also if you want to only include one or a few VM's, then; 

qvm-backup -d name-of-AppVM '/path-to-backup-location' work vault personnel 

Which will exclude everything else. But if you want everything, but exclude a 
few VM's, then you can type;

qvm-backup -d name-of-AppVM-to-handle-backup '/path-to-backup-location' -x 
sys-net -x sys-firewall -x sys-whonix -s fedora-26 -x work 

I believe you can even mix both approaches, but I have never attempted this, 
nor read if it's possible. But logically it seems possible. 

To restore again, qvm-backup-restore, just reverse the same as above, for 
example: qvm-backup-restore -d name-of-AppVM-to-handle-backup 
'/path-to-backup-location/backup-filename' Note here, unlike the above, you 
will include the backup file when restoring. 



Furthermore, you can use the '--save-profile profile-name-of-choice' attribute 
to save frequent used backup patterns. Profiles are not important, but they are 
convenient and makes life easy. For example if you just need to do a quick 
backup of all your AppVM's but don't want to include the templates, then you 
can restore it with '--profile name-of-your-AppVM-profile'. This way you can 
make frequent smaller backups very quickly, but less frequent slow and large 
backups. The large backups are useful for situations you need to re-install but 
no security issues or desires to freshly clean anything, is needed. While the 
backup of your AppVM's, at least will save your work and data. So profiling 
makes it easy and very useful to quickly make backup's of the most important 
stuff on a frequent basis. 

For example to save a profile, something like this 
qvm-backup -d name-of-AppVM '/path-to-backup-location' work vault personnel  
--save-profile AppVMs

In order to quick restore a profile, but remember a dom0 re-install likely 
removes backup profiles, though this is normally no big deal anyway. To use;
qvm-backup-restore --profile AppVMs

I remain uncertain if backup profiles can easily be transferred to a new fresh 
Qubes install. I assume there is no security issue with it too, but it's also 
something unanswered. Perhaps the profile is saved within the backup itself, or 
instead in dom0 somewhere. Either way, this should get you started.

-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to qubes-users+unsubscr...@googlegroups.com.
To post to this group, send email to qubes-users@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/e23c56f6-9778-406f-9b6b-a3034365acb2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to