Vmware data protection настройка

Обновлено: 04.07.2024

I have been playing around with different back-up software lately in my lab and I think this is the first time I took a closer look at the vSphere Data Replication (Advanced) and its features and possibilities. So, first let’s see how vSphere Data Protection is defined by VMware.

“VMware vSphere Data Protection is a backup and recovery solution from VMware. It is fully integrated with VMware vCenter Server and VMware vSphere Web Client, providing disk-based backup of virtual machines. vSphere Data Protection is based on the industry-leading EMC Avamar backup and recovery solution and is available in two editions:

  • VMware vSphere Data Protection, included with VMware vSphere Essentials Plus Kit and higher
  • VMware vSphere Data Protection Advanced, purchased separately”

Alright, that is quite clear. So, what are the differences between the Standard and the Advanced edition? Here is a quick summary taken from the vSphere Data Protection Administration Guide.

vSphere Data Protection-P1-S01

Now, let’s have a look at the installation process. But before you begin, make sure you created a forward and a reverse lookup record for the VDP in your DNS server or you may run into some configurations issues during the deployment.

The deployment process can take a while. Proceed with the initial configuration of the VDP appliance when it is finished.

The restart process can take a while. Once it completes, you can log back in to the web interface and you should see the configuration of the VDP appliance.

vSphere Data Protection-P1-S09

One last thing, select the Configuration tab and click the Email button. Here you can configure your SMTP server if you want to receive emails from the VDP appliance.

This concludes the installation and the initial configuration process of the vSphere Data Protection appliance. In the next part we will take a closer look at backup & recovery of the VMs in the vSphere Data Protection.

Подробная инструкция по установке VMware Data Protection

Статья содержит подробную инструкцию по установке, настройке и использованию встроенной системы резервного копирования VMware Data Protection

Начиная с лицензии VMware Essentials Plus kit доступна функция резервного копирования, которая с версии vSphere 5.1 называется Data Protection. За основу разработчики VMware взяли продукт EMC Amavar, в результате имеем бэкап с поддержкой сжатия и дедупликации, который работает без установки агентов в гостевые операционные системы (использует vStorage APIs for Data Protection). Данный продукт скачивается в виде готового аплайнса (виртуальной машины) в формате OVF.

Устанавливаем appliance, который скачали предварительно на сайте VMware или рутрекере. Есть несколько вариантов файлов OVF, различаются они поддерживаемым дисковым пространством для хранения резервных копий виртуальных машин, 0.5Тб или 1Тб или 2Тб и Advanced версия, уже за отдельные деньги, на 8Тб. Чтобы установить аплайнс необходимо подготовить на своей системе хранения свободное пространство для установки, соответственно для версии 0.5Тб нужег лун 868Гб, для версии 1Тб нужено 1.57Тб, для версии 2Тб нужно 3.02Тб свободного места.

показываю путь к OVF файлу с версией 0.5Тб

Смотрим, что будет, после установки. Если у вас система хранения не поддерживает Thin Provisioning то Data Protector откушает от вашего LUN 868Гб места, т.к. создается такой диск. FreeNAS поддерживает технологию тонких дисков, поэтому продолжаю установку.Не все так плохо, позже можно будет изменить формать большого диска.

Указываю, как будет называться виртуальная машина

Выбираю LUN, на котором будут располагаться диски ВМ Data Protector

Если есть возможность выбрать Толстые диски, то выбираем их, работать будет быстрее.

Теперь задаем сетевые настройки будущей виртуальной машины, причем DNS сервер — это обязательный и очень важный параметр. Но об этом я узнал позже. В первую установку, указал DNS сервер для работы интернета, и это было плохое решение.

Все готово к установке.

Сам процесс установки выглядит так:

Виртуальная машина готова, открываем консоль, чтобы понять, что делать дальше

А вот и инструкция: Первым делом подключаемся в через браузер к виртуальной машине.

пароль — changeme («семени меня» — хороший, запоминающийся, стоит его оставить)

Запускается мастер установки, который должен зарегистрировать VDP в моем vCenter сервере.

И вот первая засада, на этом шаге нужно указать Hostname этого сервера и домен. У меня изначально в схеме не было внутреннего DNS, который бы ресольвил внутренние адреса и имена, но без него дальше этого шага не продвинуться. Тогда я включил контроллер домена, который у меня остался после настройки терминального сервера и добавил туда в зону прямого просмотра запись про данный сервер, чтобы он смог resolve-ить себя.

Но этого оказалось мало, нужно добавить еще и обратную запись DNS:

Вот таким образом:

Только в том случае, если ваш сервер VDP сможет успешно выполнить ping самого себя по имени и nslookup по IP адресу, в веб интерфейсе настройки вы сможете двинуться дальше.

Москва, хотя время все равно не поменялось на правильное.

пароль для доступа к VDP серверу

для следующего шага заносим в DNS сервер vCenter. Прямую и обратную запись.

теперь параметры для подключения к vCenter:

Все готово для продолжения установки.

В консоли виртуальной машины колбасится настройка 20 минут, а может и дольше. Почему так долго, ума не приложу.

Все необходимые процессы закончились, но инструкция в консоли виртуальной машины Data Protection не изменилась.

Во вкладке плагины vCenter сервера появился плагин VDP, который, как следует из описания, не требует никаких действий со стороны клиента.

Причем я знаю, как устанавливается и работает Data Protection в своем варианте установки в Windows версию vCenter. Там этот плагин добавляет пункт меню, который отображается в vSphere client и резервным копированием можно управлять, опять же, через консоль vSphere client. Сейчас же ничего не появилось. Чуть чуть погуглив, нашел следующий способ.

Подключаемся к vCenter серверу через web интерфейс, Log in to vSphere Web Client

И в веб версии видим вкладку vSphere Data Protection:

Без вариантов, жмем connect

Минимум настроек, давайте попробуем настроить задание резервного копирования.

Будем бэкапить виртуальную машину WinXP:

да да, именно WinXP

Расписание, в котором не получится выставить точного времени. Очень необычно. Резервное копирование каждый день и точка. Потом можно будет выставить промежуток времени, когда может запускаться задание, но все равно, точное время не выставить.

Хранить резервные копии 60 дней, по дефолту. Но есть и более продвинутые схемы X - сын - папа - дед (X - неделя - месяц - год):

Даю название заданию резервного копирования:

Видим в отчетах, что бэкап не создавался и его создание не запустилось само собой:

Запускаю в ручном режиме:

Процесс, очень долгий, начался:

Отслеживать, что происходит с виртуальной машиной мне привычнее через vSphere client:

Пока делается бэкап можно посмотреть как выглядят файлы виртуалльной машины VDP на системе хранения. Непонятно, как можно посмотреть, сколько реально занимает та или иная резервная копия. Еще сложнее достать из этих vmdk файлов резервную копию нужной виртуальной машины если что-то сломается глобальное:

Вот так выглядит процесс создания бэкапа из веб клиента, малоинформативно. Но бэкап сделался за 8 минут, следующий запуск в 8 часов по полудни. К реальному (текущему) времени это не имеет никакого отношения, зачем спрашивается я указывал часовой пояс:

Восстанавливаем виртуальную машину из бэкапа:

Если бы задание выполнялось бы уже много раз, то выбор бы был больше:

Можно восстановить ВМ, заменив оригинал или создать новую виртуальную машину из бэкапа:

Готово к запуску:

Виртуальная машина была создана, удалять ее VDP не собирается после ошибки, попробую ее запустить на всякий случай, вдруг заработает. Предварительно отключаю сетевой интерфейс, чтобы не возникло конфликтов:

Открываю консоль, стартую:

Чуда не произошло, диск поврежден.

Удаляю виртуальную машину:

Еще раз восстанавливаю, ВМ из бэкапа, на этот раз все заканчивается успешно:

Данная система представляет собой appliance в виде ova файла.

Для импорта appliance перейдем в Vcenter и выберем Deploy OVF Template


Далее укажем путь к файлу appliance


Далее вы увидите информацию о импортируемой виртуальной машине


Соглашаемся с лицензией


Выбираем каталог для виртуальной машины


Выбираем хост ESXI


Указываем тип дисков


Указываем сеть для виртуальной машины.


Указываем настройки сети


Нажимаем Next, и ждем завершения импорта, после этого включаем виртуальную машину.

Подключаемся к консоли виртуальной машины через Vcenter

И смотрим адрес Data Protection


Переходим по адресу, указанному в консоли. Внимание! открывайте в браузере Internet explorer! В других браузерах работать не будет!


Далее мы попадем в мастер настройки, нажимаем Next, и переходим к настройкам сети.

Вводим настройки ip, шлюза, dns, указываем hostname и домен. Не забудьте предварительно создать DNS запись для Data Protection.



Указываем новый пароль для Data Protection


Указываем пользователя с ролью Administrator, и данные для подключения к vcenter.

Обратите внимание что PSC контроллер указывается отдельно.



Указываем хранилище и указываем тип дисков.


Указываем ресурсы для виртуальной машины.


Анализ производительности можно не включать.


Соглашаемся на создание хранилища


Далее начнется процедура создания


Через некоторое время Data protection будет перезагружен.

В веб клиенте Vcenter должно появится задание


Процесс создания хранилища может быть очень долгим.

После выполнения задания, вы можете зайти на тот же адрес Data Protection и увидеть, что теперь доступен интерфейс для настройки системы.



Откройте данный пункт и подключитесь к виртуальной машине Data Protection.


После подключения вы увидите интерфейс Data Protection.


Перейдем во вкладку Backup и настроем задание резервного копирования.

Нажимаем кнопку Backup job actions, и выбираем New.


Выбираем тип бэкапа. Есть возможность выбрать виртуальные машины или приложения внутри них.


Далее выбираем копирование полного образа ВМ, или отдельные диски.


Выбираем виртуальные машины.


Далее указываем расписание резервного копирования.


Настраиваем как долго нужно хранить резервные копии.


Вводим название задания резервного копирования и нажимаем Finish.

После этого задание будет доступно в меню Data Protection.


Для восстановления резервной копии, перейдите во вкладку Restore.

Далее выберите нужную резервную копию и нажмите кнопку Restore.



Выбираем опции восстановления, и нажимаем Next.


Далее проверяем параметры восстановления и нажимаем Finish.

В Data Protection имеется возможность репликации резервных копий на другой сервер Data Protection или EMC Avamar.

Для настройки данной функции перейдите во вкладку Replication, и нажмите кнопку Replication job actions. Выберите New.

Указываем что нужно реплицировать, виртуальные машины/резервные копии приложений или сами бэкапы.


Указываем кол-во клиентов Data Protection.


Выбираем за какие периоды нужно реплицировать резервные копии.


Указываем данные удаленной машины Data Protection или EMC Avamar.


Настраиваем расписание репликации.


Настраиваем время хранения резервных копий.


Вводим имя задания.


Далее проверяем настройки и нажимаем Finish.

Во вкладке Reports можно настроить отправку отчетов на электронную почту.

Во вкладке Configuration можно просмотреть текущую конфигурацию Data Protection.

Настройка FLR (File Level Restore).

Далее мы можем использовать 2 метода восстановления.

Первый метод Basic. В этом случае мы должны ввести учетные данные локального администратора виртуальной машины в которую мы будем восстанавливать файлы.

В этом случае мы увидим все бэкапы данной виртуальной машины, из данных бэкапов нам будут доступны все файлы и папки.


Второй метод Advanced.

Отличие в том что мы вводим не только учетные данные локального администратора, но и администратора Vcenter.

После авторизации нам будут доступны не только бэкапы виртуальной машины из которой у нас открыта консоль восстановления, но и все бэкапы других виртуальных машин.

Данный метод (FLR) удобен если нам нужно быстро восстановить файл за определенный день, или удаленный файл.

Полное руководство по Data Protection 6 можно прочитать тут.

Внимание! В данной версии Data Protection используется устаревшая таймзона MSK. Поэтому чтобы избежать проблем внимательно настраивайте расписание бэкапов.

and many more can be found in the VMware vSphere Data Protection Overview document.

To deploy the latest version of VDP, which is version 6 at the time of this writing you need to have at least VMware vCenter 5.1 and a lot of CPU and RAM on your ESXi hosts or cluster. This resources can increase or decrease, depending on how much backup storage you provision on the virtual appliance. To give you an idea, here is a table for all the minimum CPU and memory allocation needed:

Provisioned
Storage
0.5 TB 1 TB 2 TB 4 TB 6 TB 8 TB
Processors Minimum four
2 GHz
processors
Minimum four
2 GHz
processors
Minimum four
2 GHz
processors
Minimum four
2 GHz
processors
Minimum four
2 GHz
processors
Minimum four
2 GHz
processors
Memory 4 GB 4 GB 4 GB 8 GB 10 GB 12 GB
Disk Space 873 GB 1.6 TB 3 TB 6 TB 9 TB 12 TB

Besides hardware and software requirements, there are some infrastructure prerequisites needed also, like DNS, user accounts, and time configuration (NTP). Since I mentioned VDP 6, this will also be the version I will use in this article, but the installation is the same for older versions.

Now log in on one of your domain controllers, open the DNS console, select your DNS zone, right-click it and choose New Host (A or AAA). In the New Host window, fill the Name and IP address boxes with the required information then check the Create associated pointer (PTR) record box and click Add Host. This will be the name and IP address of the VDP appliance.

Once DNS was taking care of, a service/user account needs to be prepared in order for the VDP appliance to be able to access vCenter, and to run tasks needed to perform backup and restore jobs. This user needs to be added as administrator on the vCenter root node, and must not inherit permissions from group roles or is not going to be valid. There are two options for this: create the user in the SSO database or in AD. And since I have an Active Directory environment, I will create the user account in AD then add it to vCenter as administrator.

Right-click the OU where you want to create the user account and choose New > User.

Now open the VMware vSphere Web Client and log in with administrative privileges. Click the vCenter server from the root level of the tree structure, go to the Manage tab, and then select Permissions. Click the green plus button to add permissions.

On the Add Permission window click Add.

Installing and Configuring VDP 6

From the Domain drop-down box select your domain then search for the user account created earlier. Add it to the Users list and click OK.

Back on the Add Permission window assign the account to the Administrator role and hit OK.

Installing and Configuring VDP 6

The new user/service account should now be present in vCenter. More information about adding users in vCenter can be found here, and assigning the proper roles to those users can be found in this article.

Installing and Configuring VDP 6

The last infrastructure prerequisite, and the most sensitive one is the NTP configuration (the clock). This needs to be properly set-up/synchronized on all you ESXi servers and your vCenter server because VDP takes advantage of VMware Tools to synchronize time through NTP. As a caution here, do not configuring NTP directly on the VDP appliance because it will causes time synchronization errors:

Error: The most recent request has been rejected by the VDP appliance.

The most common cause of this error is that the time on the VDP appliance and the SSO server are not synchronized. See NTP configuration in the vSphere Data Protection Administration Guide for more information.

Installing and Configuring VDP 6

I usually set the domain controller (the PDC) as the NTP server on my ESXi hosts.

Installing and Configuring VDP 6

Once all of the above are meet, we can start deploying the virtual appliance. Open the vSphere Web Client, right-click the host or cluster where you want the virtual appliance to be deployed and choose Deploy OVF Template.

Installing and Configuring VDP 6

On the first page on the Deploy OVF Template wizard click the Browse button and provide the virtual appliance file then hit Next.

Installing and Configuring VDP 6

Review the template details then continue the wizard.

Installing and Configuring VDP 6

Accept the EULA and hit Next.

Installing and Configuring VDP 6

On the Select name and folder page, you can specify a different name for the appliance than the default one. Also, if you choose to put the appliance in a folder, you can do it from the Select a folder or datacenter section. The folder needs to be created beforehand, because there is no option to create it from the wizard.

Installing and Configuring VDP 6-07_1

Select a network where traffic can reach the VDP appliance in order for you to be able to access it and configure it later on.

Installing and Configuring VDP 6

Installing and Configuring VDP 6

On the Ready to complete page click Finish to start the deployment. You are also given the option to power on the appliance after the deployment process is done by checking the Power on after deployment box.

Installing and Configuring VDP 6

Depending on your network and storage speed, this could take from a few minutes to a few dozen minutes.

Installing and Configuring VDP 6

Installing and Configuring VDP 6

On the first log in, a very neat configuration wizard is displayed. Click Next to skip the Welcome screen.

Installing and Configuring VDP 6

All the network settings should be automatically completed if you followed all the above steps correctly, since most of them were provisioned while deploying the appliance from the template. If something is missing, fill in the settings manually and continue the wizard.

Choose the time zone for the VDP appliance and click Next. This is a very important setting so make sure is the same time zone as your hypervisors and vCenter server.

Installing and Configuring VDP 6

Type in a new password and continue the wizard.

Installing and Configuring VDP 6

In this page you provision the backup space on the appliance from 0.5 up to 8 TB. The more storage you provision, the more resources are needed for the appliance; as shown in the table at the beginning of the article. You allocate space depending on how many VMs you backup and for how long those VMs are stored. It is a waste of resources (CPU, memory and space on the datastores) to allocate all the 8TB now and use just half of it, or even less. Is better to provision only the space needed on the appliance, and expand it later on when is needed, because now you can do this. A few things to take into consideration when expanding the disk space on the appliance (more on the VDP 6.0 Administration guide) :

Installing and Configuring VDP 6

Choose the datastore for the VDP storage disks and the provision type for them and click Next. If you go with thin provision, make sure you proactively monitor your datastores because VDP disks will grow very fast on first backups.

Installing and Configuring VDP 6

Here is the minimum CPU and memory required for the configured capacity. The numbers can be increased if you consider is needed (busy appliance).

Installing and Configuring VDP 6

If you want to participate in the CEIP program, check the Enable Customer Experience Improvement Program box and continue the wizard, if not, just click Next.

Installing and Configuring VDP 6

Installing and Configuring VDP 6

On the warning window that pops-up, click Yes to set-up the VDP appliance with the new configuration.

Once completed, a reboot is needed, so you can either do it manually by pressing Restart now, or let it reboot automatically after one minute. Be patient because the reboot will take a while.

Installing and Configuring VDP 6

If you look in vCenter, you should see the new configuration for the appliance.

Installing and Configuring VDP 6

Now log out from your VMware vSphere Web Client then authenticate again in order for the VDP icon and menu to be displayed in the console.

Installing and Configuring VDP 6

Installing and Configuring VDP 6

After a few seconds the VDP Getting Started page will be displayed along with all the other menus needed to perform the required tasks.

Installing and Configuring VDP 6

As you can see, deploying VDP is not difficult, neither configure it. The real challenge is creating a proper plan for the backup jobs, verify those backups, and do some successful restores. All this tasks will be presented in some future article, but until then, feel free to explore the product, see if it actually fits in your company.

Читайте также: