VM Backup Plugin


Recommended Posts

So what's the deal, is this plugin defunct or what?  My unraid just flat refuses to install it anymore.  I'm on 6.12.8.

If I go to the plugins page and click the "Plugin file install errors" tab, it shows vmbackup.plg as status:error, with no explanation.

My only option is [delete]. 

Anyone found a way to get it working?  I'd really like to have backups of my VMs....

Link to comment
23 hours ago, Elmojo said:

I'd really like to have backups of my VMs....

I use urbackup, it allows you to get good versioned backups of the guest OS without shutting down the VM. There are many options to choose from if you treat your VM's as normal bare metal machines when dealing with backups.

  • Like 1
Link to comment
On 2/18/2024 at 10:20 AM, JonathanM said:

I use urbackup, it allows you to get good versioned backups of the guest OS without shutting down the VM. There are many options to choose from if you treat your VM's as normal bare metal machines when dealing with backups.

Checking out URBackup now. For a VM, am I better off just backing up the vdisk image or should I setup the Windows client with URBackup and do it that way?  I guess the downside of the vdisk file is the size but if size isn't an issue seems like an easier way to go?

 

If I go the Windows client route and I'm mainly concerned about the OS getting backed up with latest configuration, should I just do an image backup?

Edited by betaman
Link to comment
35 minutes ago, betaman said:

For a VM, am I better off just backing up the vdisk image or should I setup the Windows client with URBackup and do it that way?

Backing up a running VM from the host is not a great idea. At best the backup will be in a crash consistent state, i.e. just like you hit the reset button, any changes still in RAM are lost.

 

So, ideally you need to stop the VM, snapshot the vdisk, save the xml and any other related files like video bios, etc, then restart the VM.

 

If you back up INSIDE the VM, with a backup client that can interact with the OS while staying up to flush RAM and commit other changes, you end up with a much more portable backup. If you've done serious customization to the xml you still may need to make a copy of that to reference when you spin up the recovery VM to restore the backup, but generally you should be able to restore it bare metal or generic VM and it should run.

Link to comment
50 minutes ago, JonathanM said:

Backing up a running VM from the host is not a great idea. At best the backup will be in a crash consistent state, i.e. just like you hit the reset button, any changes still in RAM are lost.

 

So, ideally you need to stop the VM, snapshot the vdisk, save the xml and any other related files like video bios, etc, then restart the VM.

 

If you back up INSIDE the VM, with a backup client that can interact with the OS while staying up to flush RAM and commit other changes, you end up with a much more portable backup. If you've done serious customization to the xml you still may need to make a copy of that to reference when you spin up the recovery VM to restore the backup, but generally you should be able to restore it bare metal or generic VM and it should run.

Thanks. I think I just want to setup image backups for my vm inside my Windows client. I'll ask for more details on the restoration process over there. Appreciate the help!

Link to comment
  • 3 weeks later...

How do I stop this plugin from shutting down my VMs?  I have removed the plugin because it was causing some issues, but even with the plugin removed it seems like it is still trying to do things.  There are no new backups that have been created in the last few days since it have been removed and no new log files, but my VMs are still getting stopped at the 2 am start time I had setup.  Not sure what I am missing here.

 

Thanks for your time, 

Link to comment
4 hours ago, Kilrah said:

Did you reboot after uninstalling it?

There should be no need to reboot after installing or uninstalling any plugins or dockers with unraid, unless they are VERY poorly coded.  That's kind of one of the big "selling points" of server-type architectures; that they don't require constant reboots to apply updates and software changes, even system-level stuff.  Looking at you, Mr. Windows... lol

Link to comment
1 hour ago, Elmojo said:

There should be no need to reboot after installing or uninstalling any plugins or dockers with unraid, unless they are VERY poorly coded. 

Indeed, but it could precisely be the case since this plugin hasn't been maintained in ages and didn't follow unraid updates.

OP hasn't said what the issue was though. It still works fine for me.

Link to comment

The issue is that I removed the plugin and even with the script removed it, or something else is shutting down my VMs at the time of night that I had set up in the plugin.  There have been no new logs created in the data store that I was storing the backs in since I removed the plugin but they are still shutting down at 2 am and not coming back up until I login and restart them.  I don't see anything in the Unraid logs that jump out at me.  

 

I have re-installed the plugin and set up the config to ignore my VMs and tried the Backup Now option on the plugin setup page and it did not shut my VMs down.  I will have to see what happens tonight.  

 

The reason that I removed the plugin to start with was that it would not bring my VMs back up once they were shutdown and the backup was run.  

Link to comment
20 hours ago, Kilrah said:

this plugin hasn't been maintained in ages and didn't follow unraid updates

Good point.

 

18 hours ago, jwolfera said:

The reason that I removed the plugin to start with was that it would not bring my VMs back up once they were shutdown and the backup was run.  

Sorry I can't help.  I no longer use this plugin for a similar reason.  I'm now using binhex-urBackup.  If you get the issue resolved, you might want to look into it as a replacement, if you haven't already.

Link to comment
  • 1 month later...

For those (that like me) still find the plugin still works for them I have released a minor update today with two fixes:

 

v0.2.6 - 2024/04/21

Booger Nights

  • workaround for issue with empty path with unassigned devices (thanks to Juugis)
  • fix issue with plugin requiring internet at server boot (thanks to realizelol)
  • respect existing installed packages that might be used by other plugins (thanks to realizelol)

  • moved old cronjob removal to pre-install step (thanks to realizelol)


While I genuinely do not have the time to spend much time maintaining this right now, I am happy add others to the repository or review PRs for fixes/updates/etc

Edited by JTok
add missing changelog notes
Link to comment

Alright, so I found one other issue to fix with the plugin, plus some errors in my last update notes (fixed above and in the code)

 

v0.2.7 - 2024/04/21a

Loud Sounds in the Night

  • fix v0.2.6 update notes
  • fix config directory not being created automatically

And to repeat my note from the post above:

While I genuinely do not have the time to spend much time maintaining this right now, I am happy add others to the repository or review PRs for fixes/updates/etc

Link to comment

Another update thanks to realizelol!

 

v0.2.8 - 2024/04/23

Forks and Spoons Only

  • fix backup of VM names containing spaces (@realizelol)
  • indentation fixes (@realizelol)
  • update loops to break the row via semicolon (@realizelol)
  • fix disk_prefix in $vdisk_path variable (@realizelol)
  • fix counting vDisks by using Disks instead of "file sources" + Silence: STDERR output to /dev/null (@realizelol)
  • add ability for the script to handle OS suspended VMs (@realizelol)
Link to comment

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.