Last updated on Monday 28th of February 2022 08:52:48 PM

©XSIBackup backup jobs

Step by step guide to composing backup jobs

 Please note that this post is relative to old deprecated software ©XSIBackup-Classic. Some facts herein contained may still be applicable to more recent versions though.

For new instalations please use new ©XSIBackup which is far more advanced than ©XSIBackup-Classic.

Like with any other piece of software XSIBackup has its learning curve. We have conceived it to be straight and really fast to setup. In fact, it will take you no more than five minutes to setup your first backup job.

Apart from being reliable and easy to use, XSIBackup will offer you advanced options that you can use to create complex backup topologies that adapt to your needs.

Nevertheless, you can not have both things at the same time. If you want some easy to setup and reliable backup job, the syntax is pretty easy, you can just cut & paste and change a couple of things to get it going.

But, if on the contrary you want to setup some more complex type of backup job, perform backup chaining, use two step deduplication or backup over IP, you will need at least to comprehend the concept behind, which will take you the time to read the manual, the eventual posts on the subject and some additional time to make some tests.

So, citing one of the most well known philosophers in the 20th century (Mr. Miyagi from Karate Kid): "With great power comes great responsability".

In this post we will pose some examples to ilustrate how to create different types of backup jobs using XSIBackup-Free. If you have bought a license of XSIBackup-Pro, you will be able to perform most of this actions by using the GUI. In any case, reading this post will also be beneficial to you, so that you can open a backup job and comprehend what each of the arguments enclosed there mean and how to tweak them manually.



Your first backup job

As stated, this is the kind of backup job that you can just cut & paste to backup your host. It will require almost no tweaking at all, apart from setting the --backup-point, which is the path in your datastore where you want the backups to be placed.

"/vmfs/volumes/datastore1/xsi-dir/xsibackup" \
--backup-prog=Vmkfstools \
--backup-point="/vmfs/volumes/backup" \
--backup-type=Running \
--backup-how=Hot \
--date-dir=yes \
--use-smtp=1 \
--mail-to=you@yourserver.com \
--backup-id=001 \
--description="Simple Vmkfstools backup" \
--exec=yes >> "/vmfs/volumes/datastore1/xsi-dir/var/logs/xsibackup.log"


The above command will backup all your running VMs to the path set in the --backup-point argument. You just need to set the backup point itself and the e-mail address you want your backup report to be sent to. Your SMTP server's file needs to have been previously configured. You should also try the backup job previous to setting it up in the crontab by using the --run-backup=001 command.

If you just want your Virtual Machines to be backed up and you are not interested in learning anything else, this is your prototypical backup job. As said, cut and paste and change the --backup-point and --mail-to to suit your needs.

Want more?

This next step in the learning stairway will take you 1 minute to comprehend the concept behind, you most probably want to go for it. In the example above you learned how to backup all the running Virtual Machines in your host, but, what if you want to backup specific VMs?.

In this case, you will need to state what are those VMs that you want to backup. You use the --backup-vms argument to achieve that. Apart from the --backup-vms argument, you will need to change the --backup-type argument to custom.

"/vmfs/volumes/datastore1/xsi-dir/xsibackup" \
--backup-prog=Vmkfstools \
--backup-point="/vmfs/volumes/backup" \
--backup-type=Custom \
--backup-vms="LINUX01,WIN002,FBSD003" \
--backup-how=Hot \
--date-dir=yes \
--use-smtp=1 \
--mail-to=you@yourserver.com \
--backup-id=001 \
--description="Simple Vmkfstools backup" \
--exec=yes >> "/vmfs/volumes/datastore1/xsi-dir/var/logs/xsibackup.log"


Many people will just stick to this kind of backups for their daily needs. They allow you to backup VMs to the configured path, each set of VMs backups is stored in a time stamped folder by virtue of the --date-dir=yes argument and those time stamped folders will be deleted to make room, when the storage volume fills up, starting with the eldest timestamped folder in the set.

My VMs are big, I cannot backup all data every time.

If you have a set of VMs which is bigger than 500 gb. you should start to think about recurring to some kind of differential backup. XSIBackup offers you two different ways to perform differential backups: ©OneDiff and ©XSITools. The first will produce an instant differential backup based on the differential data stored in between the backup cycles, while the latter will create deduplicated backups in a repository of data chunks. ©XSITools is a differential tool as well, but it calculates hashes, which does at almost RAM speed, so it will take more than ©OneDiff, still the moved data will be the differential blocks with the added advantage of having a deduplicated backup end.

Using any of the above mentioned built in backup programs will take just one little tweak to the previously existing backup jobs. We'll start by using ©OneDiff. Please note that OneDiff will produce an exact mirror copy of the VMWare Virtual Machine being backed up. This is great if you want a ready to use fresh copy, but it is a bad protection against viruses, ransomware, etc..., thus you should perform some additional form of archival on the mirror copy or combine with other type of backup like ©XSITools

As you can see, the only change we made was to the --backup-prog argument, where we set Onediff as the argument's value.

"/vmfs/volumes/datastore1/xsi-dir/xsibackup" \
--backup-prog=Onediff \
--backup-point="/vmfs/volumes/backup" \
--backup-type=Custom \
--backup-vms="LINUX01,WIN002,FBSD003" \
--backup-how=Hot \
--date-dir=yes \
--use-smtp=1 \
--mail-to=you@yourserver.com \
--backup-id=001 \
--description="Simple Vmkfstools backup" \
--exec=yes >> "/vmfs/volumes/datastore1/xsi-dir/var/logs/xsibackup.log"


©OneDiff backups can be made over IP too, you would just change the --backup-point to some IP:port:/path value. You need to have previously linked to the target server (100.100.200.33:22) by means of the --link-srv argument.

"/vmfs/volumes/datastore1/xsi-dir/xsibackup" \
--backup-prog=Onediff \
--backup-point="100.100.200.33:22:/vmfs/volumes/backup" \
--backup-type=Custom \
--backup-vms="LINUX01,WIN002,FBSD003" \
--backup-how=Hot \
--date-dir=yes \
--use-smtp=1 \
--mail-to=you@yourserver.com \
--backup-id=001 \
--description="Simple Vmkfstools backup" \
--exec=yes >> "/vmfs/volumes/datastore1/xsi-dir/var/logs/xsibackup.log"


I don't have much space to save my backups. I want to take advantage of it as much as possible.

By using ©XSITools deduplication you can take advantage of your available backup room. ©XSITools is as fast as Vmkfstools, and will multiply the amount of data you can fit into a given space. The drawback is that you won't be able to use the backups directly, you will need to restore Virtual Machines previous to re-adding them to the ESXi host or vCenter inventory.

At the time of writing this post ©XSITools can only backup to a local datastore. We have plans to offer ©XSITools over IP in short.

Please note that we always add the :z flag to any ©XSITools examples. In case of ©XSITools the compression flag is used to compress the data chunks by using LZO compression, which is very fast, thus it's always good to use it, as it does not reduce backup speed.

"/vmfs/volumes/datastore1/xsi-dir/xsibackup" \
--backup-prog=Xsitools:z \
--backup-point="/vmfs/volumes/backup" \
--backup-type=Custom \
--backup-vms="LINUX01,WIN002,FBSD003" \
--backup-how=Hot \
--date-dir=yes \
--use-smtp=1 \
--mail-to=you@yourserver.com \
--backup-id=001 \
--description="Simple Vmkfstools backup" \
--exec=yes >> "/vmfs/volumes/datastore1/xsi-dir/var/logs/xsibackup.log"


I don't have much space to save my backups, but I have the requirement to save a historic set of backups spanning to the widest possible time period.

It does not matter how big and wealthy your company is, I have known very little, if any, IT departments that had enough budget to achieve what they were required to.

We have written a post in which we demonstrate how to achieve an incredible data density ratio by combining ©XSITools deduplication with Borg: a general purpose deduplication archiving tool.

http://33hops.com/xsibackup-two-step-deduplication-deployment.html

This post has been written to serve you as a guide on how to face ©XSIBackup learning. As you have noted, you can backup your host in a matter of minutes if you keep it simple. ©XSIBackup is a very flexible tool, you can use it to achieve almost anything that you can think of. It will not stop you from doing anything, so it's you that must size the speed you drive at to your driving skills. It would not make much sense, per instance, to use ©XSITools before knowing what block deduplication is.

Daniel J. García Fidalgo
33HOPS