Virtualization system requirements

Xen version 4.16 or later in HVM mode is required to install and launch vESR.

Creating a virtual machine

1) Create the virtual disk on which vESR will be stored, using the dd utility:

dd if=/dev/zero of=vesr_xen.img bs=1M count=1024


As a result, an empty 1 GB file must be created.

2) Create the configuration file with the following content:

type='hvm'
name='vesr_xen'
memory=4096
vcpus='4'
disk=['<full_path_to_virtual_disk>,,hdc,w', '<full_path_to_installer_image>,,hdb:cdrom,r']
boot='d'

where:

type='hvm'
name='vesr_xen'
memory=4096
vcpus='4'
disk=['/root/vesr/vesr_xen.img,,hdc,w', '/root/vesr/vesr-1.28.0-build7.firmware,,hdb:cdrom,r']
boot='d'


Installing vESR

1) To start the installation, launch the virtual machine, passing its configuration as a parameter:

sudo xl create /root/vesr/vesr_xen.conf


2) After the virtual machine is launched, connect to the console using the Xen tools:

sudo xl console vesr_xen


The next vESR installation steps are detailed in the vESR installation process section.

3) After the installation is complete, shut down vESR:

sudo xl destroy vesr_xen


4) In the configuration file, change the value of the boot parameter from 'd' to 'c', which means that the boot will be performed from the hard disk on which vESR was installed.

5) Launch the virtual machine, passing the modified configuration as a parameter:

sudo xl create /root/vesr/vesr_xen.conf


Connecting network interfaces

1) Shut down vESR:

sudo xl destroy vesr_xen


2) Add the following parameters to the configuration file:

vif=['mac=<MAC_address>, model=<network_card_model>, bridge=<bridge_name>']

where:

vif — the list of emulated network interfaces.

It is specified as a list of virtual interfaces:

vif = [ 'vifspec', 'vifspec', ... 

where:

For the system to operate successfully, the network bridge must be configured. Its configuration must be described in the network tools of your distribution.

3) Launch the virtual machine, passing the modified configuration as a parameter:

sudo xl create /root/vesr/vesr_xen.conf


Connecting a serial port (optional)

The settings in this section are optional and do not affect system operation.

1) Shut down vESR:

sudo xl destroy vesr_xen


2) Add the following parameter to the configuration file:

serial=<pty>

where:

pty — a pseudo-terminal in the host system, allocated automatically.

To find out the required pseudo-terminal number, view the content of the file:

/var/log/xen/qemu-dm-<machine_name>.log
esr@esr:# cat /var/log/xen/qemu-dm-vesr.log
char device redirected to /dev/pts/6 (label serial0)
VNC server running on 127.0.0.1:5900
qemu-system-i386: terminating on signal 1 from pid 47254 (/usr/lib/xen-4.16/bin/xl) 


The pseudo-terminal number is specified in the following line:

char device redirected to /dev/pts/6 (label serial0)

3) Launch the virtual machine, passing the modified configuration as a parameter:

sudo xl create /root/vesr/vesr_xen.conf


minicom -D /dev/pts/6