Installing a Virtual Tape Library

From Proxmox Backup Server
Jump to navigation Jump to search

Introduction

Proxmox Backup Server 1.1 and later include support for tape backup, allowing you to save Datastores to tape, and manage tape libraries and tape pools.

Since testing backup and restore with real tape hardware takes a lot of time, it can be a good idea to use a faster Virtual Tape Library (VTL) for evaluation and for testing of the correct allocation and retention policies for your use case.

One example of such a VTL is the QuadStor VTL. This tutorial will guide you through the installation and configuration of a QuadStor VTL, and also show you how to integrate it into Proxmox Backup Server.

Installing the QuadStor VTL

It's recommended to install it on a separate Virtual Machine (for example, on a Proxmox VE installation).

This tutorial assumes the use of a VM with Debian 11 (Bullseye) as the OS and '10.20.1.59' as its IP address. Two disks are needed, one for the OS, one (larger) for the VTL as storage.

The installation instructions are based on the official QuadStor documentation for Debian 9, but they will also work for Debian 11.

  1. Install supporting packages:
    apt update
    apt install uuid-runtime build-essential sg3-utils apache2 psmisc linux-headers-`uname -r`
    a2enmod cgi
    systemctl restart apache2
  2. Now you can download and install the VTL packages:
    wget -c https://www.quadstor.com/vtldownloads/quadstor-vtl-ext-3.0.76.1-debian-x86_64.deb
    apt install ./quadstor-vtl-ext-3.0.76.1-debian-x86_64.deb
    Installation can take a while.
  3. Following this, the daemon should be started/enabled automatically. If not, you can enable and start it manually with: systemctl enable --now quadstorvtl.service
  4. Finally, the VM needs to be rebooted: reboot

You can now access the VTL configuration interface over HTTP using your browser. In our example, we'd use http://10.20.1.59.

Configuring the VTL

These steps are described in more detail in the official QuadStore documentation, but the minimum required steps are repeated here.

  1. The first thing to configure is the 'Physical Storage'.
    For this, you need to add a new disk to the VM.
  2. After that, you can click on 'Physical Storage' and 'Rescan'.
    Your newly added, empty disks should show up with their Vendor, Model and Serial information.
    Click on 'Add'.
  3. Now select a 'Storage Pool' (there should be one called 'Default') and click 'Submit'.
    This will initialize the disk so that it can be used as a storage target for the virtual tapes.
  4. Now you can create a Virtual Tape Library (VTL). Click on 'Virtual Libraries' and 'Add VTL'.
    Give it a name under 'VTL Name' and select:
    • The Vendor/Model you want to simulate (best if this is as close as possible to your real tape hardware for testing).
    • The type and number of VDrives (Virtual Drives). These define the actual tape drives inside the library.
    • The number of VSlots (Virtual Slots), which is the number of slots that can hold tapes.
    • The number of 'IE Ports' (Import/Export slots).
    The remaining options are not so important and can be left on their default.
    For this example, let's choose the name 'MYTAPELIB' and the library 'IBM 3584 Ultra Scalable Library' with 2 VDrives 'IBM 3580 Ultrium 8'.
    • Click on 'Submit'.
  5. Now you need to add some virtual tapes by clicking 'Add VCartridge'.
    • Choose the number you want (this will matter for the auto-numbering scheme) and a Prefix, for example 'TAPES0', and then click on 'Submit'.
  6. After this, you can add the newly created VTL to a Proxmox Backup Server instance.

Adding the VTL to Proxmox Backup Server

The following commands must all be executed on the Proxmox Backup Server instance.

Making devices available over iSCSI

  1. The VTL will be added to Proxmox Backup Server via iSCSI, so you first make sure that the open-iscsi package is installed:
    apt install open-iscsi
  2. To automatically log in to the iSCSI targets on boot, you have to carry out the following steps:
    1. modify the iSCSI config in /etc/iscsi/iscsid.conf and change node.startup = manual to node.startup = automatic
    2. then restart iscsid by executing systemctl restart open-iscsi.service
  3. Now you need to discover the VTL tape drive and changer devices with iscsiadm. Please do not forget to adapt the IP address, if you chose a different one for the Quadstore VTL VM.
    iscsiadm -m discovery -t st -p 10.20.1.59
    The resulting output should look like this:
    10.20.1.59:3260,1 iqn.2006-06.com.quadstor.vtl.MYTAPELIB.autoloader
    10.20.1.59:3260,1 iqn.2006-06.com.quadstor.vtl.MYTAPELIB.drive2
    10.20.1.59:3260,1 iqn.2006-06.com.quadstor.vtl.MYTAPELIB.drive1
  4. You have to log in to each of these devices with
    iscsiadm -m node --targetname iqn.2006-06.com.quadstor.vtl.MYTAPELIB.autoloader --login
    iscsiadm -m node --targetname iqn.2006-06.com.quadstor.vtl.MYTAPELIB.drive1 --login
    iscsiadm -m node --targetname iqn.2006-06.com.quadstor.vtl.MYTAPELIB.drive2 --login
    This will populate /dev with the correct devices.

Adding the Changer and Drives to Proxmox Backup Server

You can now add the devices from the Proxmox Backup Server WebUI:

  1. Go to 'Tape Backup' -> 'Changers'
  2. Click on 'Add', give the changer a name, and select the path (should be autofilled).
  3. Now go to 'Tape Backup' -> 'Drives'
    • For each drive, click on 'Add' and choose a name, the corresponding changer, the index of the drive inside the changer (Drive Number), and the correct path.
    • Verify the index by comparing the serial numbers in the Proxmox Backup Server Web UI and the VTL Web UI.

After adding the drives and changers, you can use the VTL like a normal tape library in Proxmox Backup Server.