11

What do I need to do to establish backup of ESXi 3.5 or 4 server? It is my understanding that the server runs Linux, so as far as I understand the backup sequence should be:

  • create a snapshot of VM
  • copy files to a backup location
  • delete snapshot

I could probably write a script to create/delete snapshot. Is there cron on ESXi to schedule backup jobs? And another question: I assume there is no rsync or rdiff-backup pre-installed on ESXi. Are there existing pre-compiled binaries known to work with ESXi?

galets
  • 806
  • 3
  • 7
  • 18
  • ESXi does *not* run a linux kernel. ESX (no i) does. – ktower Oct 12 '09 at 05:02
  • 5
    Uuh, I think you'll find ESXi still runs a Linux kernel... there are plenty of places on the internet that will show you how to enable SSH on the box so you can get a shell... – Mark Henderson Oct 12 '09 at 05:25
  • ESX uses linux as a bootstrap; this linux kernelgets migrated to a VM halfway through the boot process (and becomes the service console). The wikipedia article describes the process and architecture pretty well. – chris Oct 12 '09 at 16:28
  • @Farseeker: Just because you can get a shell does not mean it is Linux. I repeat, the kernel for ESXi is not Linux -- it is the VMware VMKernel (enable SSH on your ESXi box and run 'uname -a'). As @chris indicates, ESX does bootstrap with a Linux kernel, but then VMKernel takes over and shifts the linux kernel into its own VM. – ktower Oct 12 '09 at 21:29

3 Answers3

9

Here is an article that describes the configuration and has scripts that you can use to perform a back of ESXi 3.5 and 4.0. I haven't deployed this myself but it is on my todo list to possibly setup.

At the moment I am just running backups within the guests.

Zoredache
  • 128,755
  • 40
  • 271
  • 413
  • +1 for the link to the very complete article. Thanks! – PEra Oct 12 '09 at 09:54
  • 1
    A caveat if you're using one of the free ESX(i) versions: There's a newer version of ghettoVCB available (ghettoVCBg2), but it requires a licensed ESX(i) host. – Dan Jun 10 '10 at 15:53
5

Zoredache has already showed the right way to go. ghettoVCB.sh is your tool of choice. It works quite well, but make sure you also read the articles by Raj Perumal (Part 1, 2 & 3).

Pauk
  • 372
  • 2
  • 6
  • 15
Phil Swiss
  • 1,437
  • 9
  • 4
  • 1
    as of this viewing, the linked articles go to a dead domain. – Dan Jun 09 '10 at 21:43
  • @Dan: The link worked for me, and it's been updated as of May 12/2010 – Jamie Jun 18 '10 at 15:11
  • 1
    I'm referring to the Raj Perumal http://blog.theworldrunsontechnology.com/ links in this post (not the link named ghettoVCB.sh)...they go to some nasty parked domain for me. – Dan Jun 18 '10 at 16:08
  • @Dan - They are fixed now. – Pauk Apr 19 '11 at 07:17
1

I started writing a script to do this myself but then I came across a free script that already does it called XSIBackup .

It does scheduling as well. I use it to schedule separate backups at different times for each vm in our office ESXi 6.0 server.

It can even do hot backups based on snapshots like the expensive Veeam Backup.

And the cool thing about it is that the backups are all run from cron directly from the ESXi host. You don't need vCenter Server or any of the expensive API tools like Veeam. It just works.