---
title: Comprehensive Guide to Backing Up Virtual Machines on ESXi 7 Free License Without Enterprise Tools
created: 2025-12-15
updated: 2025-12-15
type: summary
tags: ["backup", "esxi", "notes", "telegram", "virtualization"]
external: http://go/ui/posts/1719/
---

Because you are using the **free license of ESXi 7**, standard enterprise backup tools (like Veeam Backup & Replication, Nakivo, or Synology Active Backup for Business in "hypervisor mode") **will not work**.

This is because the free license locks the **vStorage API for Data Protection (VADP)**, preventing external software from requesting snapshots or reading VM disks directly.

However, since you are a DevOps engineer, you have two excellent workarounds: a "Host-Level" script approach (GhettoVCB) and a "Guest-Level" agent approach.

### Method 1: The "Host-Level" Script (GhettoVCB)

**Best for:** Backing up the actual VM files (`.vmdk`, `.vmx`) efficiently.
**How it works:** You run a shell script directly on the ESXi host. The script triggers a local snapshot, copies the files to your NAS, and then removes the snapshot.

#### Step 1: Prepare your NAS (NFS is required)

ESXi cannot natively mount SMB/CIFS shares as a datastore easily. You **must** use NFS.

1.  On your NAS, enable the **NFS Service**.
2.  Create a shared folder (e.g., `/volume1/esxi_backups`).
3.  **Important:** In your NAS NFS permissions, ensure the ESXi host's IP address has Read/Write access. You may need to enable "Map all users to admin" or "Squash Root to Admin" because ESXi runs as `root`, and standard NFS often blocks root write access by default.

#### Step 2: Mount NAS on ESXi

1.  Log in to the ESXi Web Client.
2.  Go to **Storage** -\> **Datastores** -\> **New Datastore**.
3.  Select **Mount NFS Datastore**.
4.  **Name:** `NAS_Backups`
5.  **NFS Server:** `<NAS_IP_ADDRESS>`
6.  **NFS Share:** `/volume1/esxi_backups`
7.  **NFS Version:** NFS 3 (usually most compatible for this simple use case) or NFS 4.1.

#### Step 3: Install & Configure GhettoVCB

This is the industry-standard "hack" script for free ESXi.

1.  **Enable SSH** on your ESXi host (`Host` -\> `Actions` -\> `Services` -\> `Enable Secure Shell`).
2.  **SSH into your host**.
3.  **Download the script:**
    ```bash
    cd /vmfs/volumes/NAS_Backups
    # You might need to download this to your PC and upload it via datastore browser if wget fails due to certificates
    wget https://raw.githubusercontent.com/lamw/ghettoVCB/master/ghettoVCB.sh
    chmod +x ghettoVCB.sh
    ```
4.  **Create a Config File:**
    Create a file named `ghettoVCB.conf` in the same directory. Minimal config:
    ```bash
    VM_BACKUP_VOLUME=/vmfs/volumes/NAS_Backups/backups
    DISK_BACKUP_FORMAT=thin
    VM_BACKUP_ROTATION_COUNT=3
    POWER_VM_DOWN_BEFORE_BACKUP=0
    ENABLE_HARD_POWER_OFF=0
    ITER_TO_WAIT_SHUTDOWN=3
    POWER_DOWN_TIMEOUT=5
    SNAPSHOT_TIMEOUT=15
    LOG_LEVEL=info
    BACKUP_LOG_OUTPUT=/vmfs/volumes/NAS_Backups/ghettoVCB.log
    ENABLE_COMPRESSION=0
    ```
5.  **Run the backup:**
    To backup **all** VMs:
    ```bash
    ./ghettoVCB.sh -a -g ./ghettoVCB.conf
    ```
    To backup a **list** of VMs, create a file `vms_to_backup` (one VM name per line) and run:
    ```bash
    ./ghettoVCB.sh -f vms_to_backup -g ./ghettoVCB.conf
    ```

**Note on Automation (Cron):**
ESXi resets the crontab on reboot. To make the schedule persistent, you must add the cron line to `/etc/rc.local.d/local.sh` so it re-injects the cron job every time the server boots.

-----

### Method 2: The "Guest-Level" Agent (Bypass the Hypervisor)

**Best for:** Reliability and avoiding scripts.
**How it works:** You ignore the ESXi layer entirely. You install backup software *inside* the VM (Windows/Linux) and treat it like a physical server.

1.  **Veeam Agent for Windows / Linux (Free Edition):**
      * Install the agent inside the VM.
      * Point the destination to your NAS SMB share (`\\nas\backups`).
      * This is robust, supports application-aware processing (VSS for SQL/Exchange), and is completely free for individual workloads.
2.  **Synology Active Backup for Business (Agent Mode):**
      * If you own a Synology NAS, this is the **best option**.
      * Do **not** use the "VMware" connection method (it will fail due to the API lock).
      * Use the **"Physical Server"** method. Install the Synology Agent inside your VMs.
      * It does global deduplication and is extremely fast.

### Summary Recommendation

  * **If you want "Image Level" backups (easy restore of the whole `.vmdk`):** Use **Method 1 (GhettoVCB)**. It's a bit of initial setup, but once running, it's very effective for disaster recovery.
  * **If you want "File Level" granularity or easier setup:** Use **Method 2 (Veeam Agent or Synology Agent)**. It bypasses the ESXi licensing restrictions entirely.

**Next Step:**
Would you like me to generate the exact code snippet to make the GhettoVCB cron job persist across reboots?
