Installing Xpenology on ESXi and setting up virtual video surveillance

Xpenology is the same Synology NAS operating system, only installed on ordinary computer hardware. Instructions on how to install Xpenology on a regular computer are on the Internet wagon and small cart, so I will not dwell on it.

In this article, I want to tell you how to install Xpenology as a virtual machine on an ESXi server and deploy a video surveillance server on its basis. Of course, since this is primarily a NAS, after installing a virtual machine, you can store files of other virtual machines on it from this and other hosts, but, for me, this will be overkill. Although, for experiments, this is quite a working option.

This article is based in part on Tutorial: Install DSM 6.2 on ESXi 6.7

First of all, you need to download XPENOLOGY TOOL from the site:

Select the loader (loader) DS3615XS version 1.03b and DSM 6.2 23739

Download two files: “” and “DSM_DS3615xs_23739.pat”

From the archive “” we take the file “synoboot.img” and create a new text file “synoboot.vmdk” with the following content:

# Disk DescriptorFile

# Extent description
RW 102400 VMFS "synoboot.img" 0

# The Disk Data Base 

ddb.adapterType = "lsilogic"
ddb.deletable = "true"
ddb.encoding = "UTF-8"
ddb.longContentID = "7e24a756b77e33e24ac940cc6ccf51e5"
ddb.thinProvisioned = "1"
ddb.uuid = "60 00 C2 9a ee da ca 33-df 5e 04 3f 80 55 f9 62"
ddb.virtualHWVersion = "10"

Next, we need the OSFMOUNT program, with which we will mount and fix the bootloader in “synoboot.img”

On the mounted disk, edit the grub.cfg file:

1) Change the serial number and MAC address (for example, to C7AAN09761 and 0A1B2C3D4E5F); if you need more than one network, then add a line with mac2, mac3, etc.

2) Commenting out unnecessary menu lines

3) Save and unmount.

Create a virtual machine in esxi 6.7:

1) We give the machine 2 cores and two gigabytes of memory

2) Remove the disk, SCSI controller and CD/DVD. If the 3617 bootloader is used, then you need to remove the USB controller or change its type to USB 3.0.

3) Change the type of network
adapter on the E1000e and give it a MAC address, the same as we
registered in grub.cfg, in our case 0A:1B:2C:3D:4E:5F

To add a hard disk to the created virtual machine, you need to add our two files to the folder with the machine files: synoboot.img and synoboot.vmdk

After that, in the properties of the machine, click “Add hard disk” –> “Existing hard disk” and select the added disk.

Select its type SATA, SATA address (0: 0)

Don’t forget to change the boot type to BIOS

We start and see an invitation to find this device through the site We will do so (you can also use the Synology Assistant program, but only versions not older than 6.2-24922, later versions cannot be found).

If everything is correct, then in a minute it will find the device and offer to connect:

Pay attention to the serial number and mac address
Pay attention to the serial number and mac address

We accept the license agreement:

And we see a message that the hard drive is not found. In fact, this is how it should be: the disk that we added before is just a bootloader. If we did this on a real computer, then we would write this image (synoboot.img) to a USB flash drive and boot from it.

We turn off our virtual machine and add another SATA controller and a SATA (1.0) disk to it, this disk must be at least 15Gb and be of a thick type (Thick provisioned).

Going back to the site and looking for our device. Now, after accepting the license agreement, it prompts to “Install”

After clicking “Install”, select “Install manually” and select the previously downloaded file “DSM_DS3615xs_23739.pat”

Click “Install Now” and wait for the installation to complete.

After installation, we again look for the device through the site and connect. First of all, you will need to set the device name, user and password:

Then we indicate that we only need to be notified about the availability of updates and uncheck both boxes. We DO NOT NEED to update at all, we have everything virtual and SMART is irrelevant for us.

We skip the next step, we don’t need QuickConnect.

After that, the initial setup is completed. If you wish, you can climb through the settings, specify a static ip address, disable ipv6, enable SSH access, etc.

We answer all proposals to update with a decisive refusal!

There is one small step left: since this is a virtual machine, we need to install vm-tools so that the hypervisor can fully manage it. So let’s go to the site. and download “open-vm-tools_x64-6.1_10.2.0-1.spk” from there, after which we manually install the package through the “Package Center”:

But nothing will work right away, since the system does not yet have partitions on which you can install anything …

To create partitions, go to “Storage Manager” –> “Storage Resource Pool” –> “Create”

We see our 15Gb disk (if the disk was smaller, it would not allow creating a partition on it), which we gave to the virtual machine (drag it to the right with the mouse). We agree that all data on this disk will be destroyed and refuse to check the disk for errors (once again: we have everything virtual, but on real hardware this is a necessary thing)

We have created a resource pool, now we need a partition on this pool, which they will immediately write to us about (there is a slight confusion with the translation: it suggests going to the “Volume” tab, but in fact the desired tab is called “Section”).

Go to “Section” and click “Create”.

We set the size of the partition (I used all the free space) and select the type of file system (Btrfs is an interesting thing, of course, but ext4 is somehow closer).

The partition is ready, now you can install something on it (we need to install vm-tools) or create a shared folder on it (SMB, NFS, FTP …).

We return to the “Package Center” and manually install “open-vm-tools_x64-6.1_10.2.0-1.spk” (you can ignore the fact that the package is not digitally signed).

Now the hypervisor can fully manage this virtual machine (for example, shut it down correctly).

Now we can move on to what all this was started for: to video surveillance.

From the “Package Center” you need to install a trial version of “Surveillance Station” on two cameras (On the forums, I met links to a hacked version, without restrictions on the number of connected cameras).

You can immediately click “Open” and go to the page responsible for video surveillance.

Then everything is simple: cameras are added through the “IP camera”, you need to watch the recordings through the “Timeline”, and “Live Video”, as you might guess, to view images from the cameras in real time.

Adding the first camera; if the camera is not in the list of familiar devices, you can always use the ONVIF or RTSP protocol

We select the permission for the primary and secondary streams and the place where the records will be saved (we still have only one section of 10Gb).

We set how we will record – continuously or in motion.

After the camera activation is completed, all settings can be edited again: for example, specify who will be responsible for event detection (surveillance station or the camera itself).

When you try to install a third camera, the system will write that the licenses have ended. After that, either pay or look for a package with a hacked version.

To manage “Surveillance station”, you can also download “Synology Surveillance Station Client” from the Synology website (it works a little faster than through a browser).

Now a small digression about where to store recordings from video cameras. For me, spending on this precious storage space is too wasteful and the easiest way is to add an additional disk of the required size to ESXi. On this disk, you can make a separate datastore or give the entire disk to a virtual machine via RDM. Of course, after that, the mobility of this virtual machine will be reduced to zero. If this is a standalone ESXi, then there is no problem, but if it is a cluster running vCenter, then the machine is tightly tied to a specific host.

I prefer to add a disk through RDM, if necessary, it can be easily unlinked from the virtual machine and rearranged to another server, and the machine can be migrated, and then reattached to this RDM disk. If desired, such a disk can also be installed in an ordinary computer with Linux, because there is an ext4 file system.

So let’s do it. I installed an additional 1Tb disk in the host. In earlier versions of ESXi, it was possible to add a physical RDM disk directly from the menu, but then for some reason this option was removed. Therefore, we connect to our host via SSH and find out the name of our new disk:

ls -l /vmfs/devices/disks

We see that the disk we need is called:


The command that makes a link to an RDM disk looks like this:

vmkfstools -z /vmfs/devices/disks/diskname /vmfs/volumes/datastorename/vmfolder/vmnamevmdk

In our case, this is:

vmkfstools -z /vmfs/devices/disks/t10.ATA_____WDC_WD10EZRX2D00DC0B0_________________________WD2DWMC301654272 /vmfs/voluсmes/esxi04ds1/DS3615XS/rdmdisk1tbvmdk

Now this disk can be added in the properties of the virtual machine (Add hard disk –> Existing hard disk):

The drive must be on a second SATA controller (1:1)).

And to unbind the RDM disk, you need to delete it in the machine properties and delete the link file from the folder (in our case, the rdmdisk1tb.vmdk file).

Once enabled, the drive will appear in the Storage Manager:

Based on the new disk, a new resource pool and a new partition on this pool are created (everything is the same as for a 15Gb disk). If you add two RDM disks, then even a RAID can be made on their basis.

Now we have two partitions on two disks (it is clear that several partitions can be created on a disk for different needs, for example, one for file trash, the other for storing camera recordings).

The next step is to go to the control panel of Surveillance Station. There we go to the item “Record” on the tab “Storage”, “Add”

Select “Add Shared Folder” and set the name and location:

In the properties of the camera, now we select a new storage location, and after confirmation, all recordings from this camera will be moved to the new storage.

That, in fact, is all. Of course, you can register several users with different rights, set up post rotation rules, and much more, but you can read about all this in the help.

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *