VM Backup Plugin


JTok

238 posts in this topic Last Reply

Recommended Posts

On 3/25/2021 at 3:03 PM, jlficken said:


I get this error:

 

+==============================================================================
| Skipping package vmbackup-v0.2.3-2021.03.11 (already installed)
+==============================================================================


This is something I found right after the last release. It will be fixed in the next version. Glad you figured it out though.

If anyone else runs into this, you can also fix it by running this from the terminal (which will force the vmbackup plugin to fully uninstall).
 

removepkg vmbackup*

 

Link to post
  • Replies 237
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Popular Posts

Hello, long time no see. I am truly sorry to see so many of you have had an issue with this plugin, and it was not my intention to abandon it for as long as I have. Sadly, life had other plans (a

Mod note: this plugin has multiple known issues, use with care.   This is a beta version of a plugin I am working on to replace the unraid-vmbackup script I have been maintaining here and he

Dang. Sorry for the issues with the latest version. I wasn’t having them on my server (although mine was still on 6.8.3), but I must have messed something up when I uploaded the latest version to GitH

Posted Images

Thanks for this plugin and apologies for what might be a simple question:

 

I may have missed this but exactly how do you go about restoring? I tried using the backed up XML but got an NVRAM related error. 

Do you have to manually move the NVRAM files somewhere?

 

Thanks

Link to post

Hi i'm new to the forum, thanks for your job!

This is indeed an useful plugin, installed and run seamlessy just reading github readme.

Now simple question, i cannot find nowhere similar easy instructions for restore procedure. 

How to do that?

I guess is quite easy but... i would like to test the full procedure :-)
Thanks again!

Link to post

how do you find out what the error is when it runs and tells you there is an error.. really there is nothing in this error log to tell me exactly whats wrong.. says no error then says there is error..   

well whats error?  so i confused? and how you fix it  and where is the incremental file list?


2021-04-04 03:36:01 information: copy of /mnt/user/Backup Files/VMs Backup/Windows 98/20210328_0000_win98.qcow2 to /mnt/user/Backup Files/VMs Backup/Windows 98/20210404_0000_win98.qcow2 complete.
2021-04-04 03:36:01 information: skip_vm_shutdown is false. beginning vm shutdown procedure.
2021-04-04 03:36:01 information: Windows 98 is shut off. vm desired state is shut off. can_backup_vm set to y.
2021-04-04 03:36:01 information: actually_copy_files is 1.
2021-04-04 03:36:01 information: can_backup_vm flag is y. starting backup of Windows 98 configuration, nvram, and vdisk(s).
sending incremental file list
Windows 98.xml

sent 4,328 bytes received 35 bytes 8,726.00 bytes/sec
total size is 4,217 speedup is 0.97
2021-04-04 03:36:01 information: copy of Windows 98.xml to /mnt/user/Backup Files/VMs Backup/Windows 98/20210404_0000_Windows 98.xml complete.
2021-04-04 03:36:01 information: Windows 98 does not appear to have an nvram file. skipping.
2021-04-04 03:36:01 information: extension for /mnt/user/isos/Microsoft Windows 98 Second Edition/Microsoft Windows 98 Second Edition/Windows 98 Second Edition.iso on Windows 98 was found in vdisks_extensions_to_skip. skipping disk.
sending incremental file list
win98.qcow2

sent 171,501 bytes received 299,973 bytes 188,589.60 bytes/sec
total size is 1,835,139,072 speedup is 3,892.34
2021-04-04 03:36:03 information: copy of /mnt/cache/vms/win98/win98.qcow2 to /mnt/user/Backup Files/VMs Backup/Windows 98/20210404_0000_win98.qcow2 complete.
2021-04-04 03:36:04 information: backup of /mnt/cache/vms/win98/win98.qcow2 vdisk to /mnt/user/Backup Files/VMs Backup/Windows 98/20210404_0000_win98.qcow2 complete.
2021-04-04 03:36:04 information: the extensions of the vdisks that were backed up are qcow2.
2021-04-04 03:36:04 information: vm_state is shut off. vm_original_state is shut off. not starting Windows 98.
2021-04-04 03:36:04 information: backup of Windows 98 to /mnt/user/Backup Files/VMs Backup/Windows 98 completed.
2021-04-04 03:36:04 information: number of days to keep backups set to indefinitely.
2021-04-04 03:36:04 information: number of backups to keep set to infinite.
2021-04-04 03:36:04 information: removing local Windows 98.xml.
removed 'Windows 98.xml'
2021-04-04 03:36:04 information: Windows XP can be found on the system. attempting backup.
2021-04-04 03:36:04 information: creating local Windows XP.xml to work with during backup.
2021-04-04 03:36:04 information: /mnt/user/Backup Files/VMs Backup/Windows XP exists. continuing.
2021-04-04 03:36:04 information: extension for /mnt/user/isos/en_windows_xp_home_with_service_pack_3_x86_cd_x14-92413.ISO on Windows XP was found in vdisks_extensions_to_skip. skipping disk.
2021-04-04 03:36:04 information: extension for /mnt/user/isos/virtio-win-0.1.160-1.iso on Windows XP was found in vdisks_extensions_to_skip. skipping disk.
2021-04-04 03:36:04 information: copy of backup of /mnt/user/Backup Files/VMs Backup/Windows XP/20210328_0000_vdisk1.img vdisk to /mnt/user/Backup Files/VMs Backup/Windows XP/20210404_0000_vdisk1.img starting.
'/mnt/user/Backup Files/VMs Backup/Windows XP/20210328_0000_vdisk1.img' -> '/mnt/user/Backup Files/VMs Backup/Windows XP/20210404_0000_vdisk1.img'
2021-04-04 03:38:37 information: copy of /mnt/user/Backup Files/VMs Backup/Windows XP/20210328_0000_vdisk1.img to /mnt/user/Backup Files/VMs Backup/Windows XP/20210404_0000_vdisk1.img complete.
2021-04-04 03:38:37 information: skip_vm_shutdown is false. beginning vm shutdown procedure.
2021-04-04 03:38:37 information: Windows XP is shut off. vm desired state is shut off. can_backup_vm set to y.
2021-04-04 03:38:37 information: actually_copy_files is 1.
2021-04-04 03:38:37 information: can_backup_vm flag is y. starting backup of Windows XP configuration, nvram, and vdisk(s).
sending incremental file list
Windows XP.xml

sent 4,691 bytes received 35 bytes 9,452.00 bytes/sec
total size is 4,581 speedup is 0.97
2021-04-04 03:38:37 information: copy of Windows XP.xml to /mnt/user/Backup Files/VMs Backup/Windows XP/20210404_0000_Windows XP.xml complete.
2021-04-04 03:38:37 information: Windows XP does not appear to have an nvram file. skipping.
2021-04-04 03:38:37 information: extension for /mnt/user/isos/en_windows_xp_home_with_service_pack_3_x86_cd_x14-92413.ISO on Windows XP was found in vdisks_extensions_to_skip. skipping disk.
2021-04-04 03:38:37 information: extension for /mnt/user/isos/virtio-win-0.1.160-1.iso on Windows XP was found in vdisks_extensions_to_skip. skipping disk.
sending incremental file list
vdisk1.img

sent 26,350,696 bytes received 7,373,283 bytes 130,966.91 bytes/sec
total size is 107,374,182,400 speedup is 3,183.91
2021-04-04 03:42:54 information: copy of /mnt/user/vms/Windows XP/vdisk1.img to /mnt/user/Backup Files/VMs Backup/Windows XP/20210404_0000_vdisk1.img complete.
2021-04-04 03:42:55 information: backup of /mnt/user/vms/Windows XP/vdisk1.img vdisk to /mnt/user/Backup Files/VMs Backup/Windows XP/20210404_0000_vdisk1.img complete.
2021-04-04 03:42:55 information: the extensions of the vdisks that were backed up are img.
2021-04-04 03:42:55 information: vm_state is shut off. vm_original_state is shut off. not starting Windows XP.
2021-04-04 03:42:55 information: backup of Windows XP to /mnt/user/Backup Files/VMs Backup/Windows XP completed.
2021-04-04 03:42:55 information: number of days to keep backups set to indefinitely.
2021-04-04 03:42:55 information: number of backups to keep set to infinite.
2021-04-04 03:42:55 information: removing local Windows XP.xml.
removed 'Windows XP.xml'
2021-04-04 03:42:55 information: finished attempt to backup webserver, Windows Server 2016, 2. Volumio, 1. Hass, 1. caller id, 1.v, FreeBSD, hassass, home assistant Hasso, Landon's - Ubuntu, Landon's - Windows 10, Landon's - Windows XP, LibreELEC, Linux, Linux Lite, OpenELEC, OpenSUSE, Ubuntu, Webserver (192.168.0.30) Server 2019, Windows 10, Windows 7 32 bit, Windows 98, Windows XP to /mnt/user/Backup Files/VMs Backup.
2021-04-04 03:42:55 information: cleaning out logs over 1.
2021-04-04 03:42:55 information: removed '/mnt/user/Backup Files/VMs Backup/logs/20210328_0000_unraid-vmbackup.log'.
2021-04-04 03:42:55 information: cleaning out error logs over 10.
2021-04-04 03:42:55 information: did not find any error log files to remove.
2021-04-04 03:42:55 warning: errors found. creating error log file.
sending incremental file list
20210404_0000_unraid-vmbackup.log

sent 71,278 bytes received 35 bytes 142,626.00 bytes/sec
total size is 71,136 speedup is 1.00
2021-04-04 03:42:55 Stop logging to log file.
2021-04-04 03:42:55 Stop logging to error log file.
2021-04-04 03:42:55 Found /tmp/vmbackup/scripts/default.pid. Attempting to kill process.
2021-04-04 03:42:55 Killed user script with pid 2265 for default.
2021-04-04 03:42:55 Removed: /tmp/vmbackup/scripts/default/user-script.sh
2021-04-04 03:42:55 Removed: /tmp/vmbackup/scripts/default.pid

 

Link to post

running on unraid 6.8.3 and vm backup 2021.3.11

 

set to run ever saturday night. looking through my files it looks like it hasnt actually done a backup since december of last year. if i go to the script and i select to run backup i get the notifiaction fairly quickly that it has finished but no new backup. attaching my log file.

 

 

 

 

 

2021-04-04 08:25:25 Start logging to log file.
2021-04-04 08:25:25 information: send_notifications is 1. notifications will be sent.
2021-04-04 08:25:25 information: only_send_error_notifications is 0. normal notifications will be sent if send_notifications is enabled.
2021-04-04 08:25:31 information: keep_log_file is 1. log files will be kept.
2021-04-04 08:25:31 information: number_of_log_files_to_keep is 1. this is probably a sufficient number of log files to keep.
2021-04-04 08:25:31 information: enable_vm_log_file is 0. vm specific logs will not be created.
2021-04-04 08:25:31 information: backup_all_vms is 1. vms_to_backup will be ignored. all vms will be backed up.
2021-04-04 08:25:31 information: use_snapshots is 0. vms will not be backed up using snapshots.
2021-04-04 08:25:31 information: kill_vm_if_cant_shutdown is 0. vms will not be forced to shutdown if a clean shutdown can not be detected.
2021-04-04 08:25:31 information: set_vm_to_original_state is 1. vms will be set to their original state after backup.
2021-04-04 08:25:31 information: number_of_days_to_keep_backups is 0. backups will be kept indefinitely. be sure to set number_of_backups_to_keep to keep backups storage usage down.
2021-04-04 08:25:31 information: number_of_backups_to_keep is 3. this is probably a sufficient number of backups to keep.
2021-04-04 08:25:31 information: inline_zstd_compress is 0. vdisk images will not be inline compressed.
2021-04-04 08:25:31 information: pigz_compress is 0. backups will not be post compressed.
2021-04-04 08:25:31 information: use_snapshots disabled, not adding snapshot_extension to vdisk_extensions_to_skip.
2021-04-04 08:25:31 information: snapshot_fallback is 0. snapshots will fallback to standard backups.
2021-04-04 08:25:31 information: pause_vms is 0. vms will be shutdown for standard backups.
2021-04-04 08:25:31 information: enable_reconstruct_write is 0. reconstruct write will not be enabled by this script.
2021-04-04 08:25:31 information: compare_files is 0. files will not be compared after backups.
2021-04-04 08:25:31 information: backup_xml is 1. vms will have their xml configurations backed up.
2021-04-04 08:25:31 information: backup_nvram is 1. vms will have their nvram backed up.
2021-04-04 08:25:31 information: backup_vdisks is 1. vms will have their vdisks backed up.
2021-04-04 08:25:31 information: start_vm_after_backup is 0. vms will not be started following successful backup.
2021-04-04 08:25:31 information: start_vm_after_failure is 0. vms will not be started following an unsuccessful backup.
2021-04-04 08:25:31 information: disable_delta_sync is 0. rsync will be used to perform delta sync backups.
2021-04-04 08:25:31 information: rsync_only is 0. cp will be used when applicable.
2021-04-04 08:25:31 information: actually_copy_files is 1. files will be copied.
2021-04-04 08:25:31 information: clean_shutdown_checks is 20. this is probably a sufficient number of shutdown checks.
2021-04-04 08:25:31 information: seconds_to_wait is 30. this is probably a sufficient number of seconds to wait between shutdown checks.
2021-04-04 08:25:31 information: keep_error_log_file is 1. error log files will be kept.
2021-04-04 08:25:31 information: number_of_error_log_files_to_keep is 10. this is probably a sufficient error number of log files to keep.
2021-04-04 08:25:31 information: started attempt to backup 001 Windows 10, 002 Windows 10, 003 Windows 10, Backup DNS, CentOS, Debian 002, Macinabox BigSur, Ubuntu to /mnt/user/Drive Backups/VM Backups/Automatic Backups
2021-04-04 08:25:31 information: 001 Windows 10 can be found on the system. attempting backup.
2021-04-04 08:25:31 information: removing old local 001 Windows 10.xml.
2021-04-04 08:25:31 information: creating local 001 Windows 10.xml to work with during backup.
2021-04-04 08:25:31 information: /mnt/user/Drive Backups/VM Backups/Automatic Backups/001 Windows 10 exists. continuing.
2021-04-04 08:25:31 information: finished attempt to backup 001 Windows 10, 002 Windows 10, 003 Windows 10, Backup DNS, CentOS, Debian 002, Macinabox BigSur, Ubuntu to /mnt/user/Drive Backups/VM Backups/Automatic Backups.
2021-04-04 08:25:31 information: cleaning out logs over 1.
2021-04-04 08:25:31 information: removed '/mnt/user/Drive Backups/VM Backups/Automatic Backups/logs/20210404_0812_unraid-vmbackup.log'.
2021-04-04 08:25:31 information: cleaning out error logs over 10.
2021-04-04 08:25:31 information: did not find any error log files to remove.
2021-04-04 08:25:31 Stop logging to log file.

Edited by itskamel
Link to post
  • 2 weeks later...

so i havent found out yet why the 2 Windows VMs cant be backed up.. is it because there running at the same time..

and now if it fails  you cant run Backup again.. tells me can not run default

 

but why cant it back up windows vms?

Link to post

I've sat here for a while and took me some days to finish reading ALL the posts so far. 

First of all I want to thank and congratulate @JTok for making this plug in. And I wish you the best from now on. I've read that you don't have a test server. Feel free to tell me and I can grant you access in mine should you want to run some tests.

 

However I'm backing up Win 2012 Server, Win 7 and win 10 VMs. And sometimes the backup is done and some it is not. 

I've installed the plugin a couple of weeks ago and I'm in a run test phase. I found in the logs that the problem is that the VMs are not being shut properly and when that happens the vm is not backed up. I don't know if you could point me in some direction in order to start looking I would really appreciate it.

 

TIA!

 


 

Link to post

i hear ya i found out with parity  problems everytime unraid reboots   its due to VMs not shutting down  basiclly my 2 Windows Server..

another guy told me to try setting up  in VMs Manager under Advanced..  change the Shutdown  to   Hibernate  and then you need to install KVM Guest    on VMs     

its supposed to shut them down faster..  as i have  parity checks everytime i reboot due to VMS not shutting down.. and my 2 windows Vms  dont back up anymore with the latest Unraid  its problem a bug  why it doesnt backup either..

 

so you could try it.. i even tried uninstalling VM Backup  and it didnt solve.. so   i waiting for a latest fix.. and gonna try this KVM Guest and with the Shutdown set to Hibernation

 

 

Link to post

ya it doesnt help latest unraid 6.9.2 has a bug in the OS  that causes parity check and unsafe shutdowns

 

i in the middle trying to get kvm guest  to see if  it will fix the VMBackup errors as it only has a problem with Windows Server  and Unraid 6.9.2  hosting it.. it didnt have a problem in previous unraids 

sp tjos bug must be affecting vmbackups too

 

if Windows Vms are running  doesnt affect any stopped vms

 

 

and doing that set 420 seconds disk settings and 300 seconds vms  did not work  just took lot longer to start up and still created unclean shut down and parity checking started

Link to post
  • 2 weeks later...

Does the plugin only back up the vdisk files for a VM or does it back up the XML (and potentially BIOS) files that are stored in the libvirt image?   If not I would think adding this should be easy and it would definitely make restoring a VM much easier.

Link to post
2 hours ago, itimpi said:

Does the plugin only back up the vdisk files for a VM or does it back up the XML (and potentially BIOS) files that are stored in the libvirt image?

 

Looks like it backs up all of them. See log from a recent run (core-backup/domains is the destination directory)

 

2021-04-27 10:41:02 information: Debian is shut off. vm desired state is shut off. can_backup_vm set to y.
2021-04-27 10:41:02 information: actually_copy_files is 1.
2021-04-27 10:41:02 information: can_backup_vm flag is y. starting backup of Debian configuration, nvram, and vdisk(s).
sending incremental file list
Debian.xml

sent 7,343 bytes received 35 bytes 14,756.00 bytes/sec
total size is 7,237 speedup is 0.98
2021-04-27 10:41:02 information: copy of Debian.xml to /mnt/user/core-backup/domains/Debian/20210427_1040_Debian.xml complete.
sending incremental file list
55c212-015b-6fc0-dada-cba0018034_VARS-pure-efi.fd

sent 131,246 bytes received 35 bytes 262,562.00 bytes/sec
total size is 131,072 speedup is 1.00
2021-04-27 10:41:02 information: copy of /etc/libvirt/qemu/nvram/55c212-015b-6fc0-dada-cb6ca0018034_VARS-pure-efi.fd to /mnt/user/core-backup/domains/Debian/20210427_1040_55c21fa2-015b-6fc0-dada-cba0018034_VARS-pure-efi.fd complete.
'/mnt/cache/domains/Debian/vdisk1.img' -> '/mnt/user/core-backup/domains/Debian/20210427_1040_vdisk1.img'
2021-04-27 10:42:19 information: copy of /mnt/cache/domains/Debian/vdisk1.img to /mnt/user/core-backup/domains/Debian/20210427_1040_vdisk1.img complete.
2021-04-27 10:42:19 information: backup of /mnt/cache/domains/Debian/vdisk1.img vdisk to /mnt/user/core-backup/domains/Debian/20210427_1040_vdisk1.img complete.
2021-04-27 10:42:19 information: extension for /mnt/user/isos/debian-10.3.0-amd64-netinst.iso on Debian was found in vdisks_extensions_to_skip. skipping disk.
2021-04-27 10:42:19 information: the extensions of the vdisks that were backed up are img.
2021-04-27 10:42:19 information: vm_state is shut off. vm_original_state is running. starting Debian.
Domain Debian started

2021-04-27 10:42:20 information: backup of Debian to /mnt/user/core-backup/domains/Debian completed.

 

Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.