Category Archives: XenServer

Xen the specified virtual disk could not be found

If you get this error message after you reboot a VM: This operation cannot be performed because the specified virtual disk could not be foundThis operation cannot be performed because the specified virtual disk could not be found Make sure to “Eject” the ISO from the DVD Drive 1.

Increase Dom0 RAM Memory in XenServer 6

Configure Control Domain (dom0) RAM memory in XenServer 6.1.0 and later: 1) SSH login as root on the XenServer host 2) Enter the following command to increase the RAM to 4GB: /opt/xensource/libexec/xen-cmdline –set-xen dom0_mem=4096M,max:4096M/opt/xensource/libexec/xen-cmdline –set-xen dom0_mem=4096M,max:4096M 3) Shutdown all running VMs to avoid data loss: *** This command may not be recommended for a pooled […]

RAID1 Mdadm and XenServer (Notes)

Important thing to note: /dev/sda1: the XenServer root partition /dev/sda2: XenServer uses this partition for temporary space during upgrades /dev/sda3: your storage repository should be in this logical volume/dev/sda1: the XenServer root partition /dev/sda2: XenServer uses this partition for temporary space during upgrades /dev/sda3: your storage repository should be in this logical volume Show info […]

Install XenServer Tools on Linux VMs

Right-click on the VM and select “Install XenServer Tools”: On the opened window click on “Install XenServer Tools”: Login via SSH as root to your VM and mount the VM image: mount /dev/xvdd /mntmount /dev/xvdd /mnt Execute this script to install the SenSeerver Tools: /mnt/Linux/install.sh/mnt/Linux/install.sh Then reboot the VM: shutdown -r nowshutdown -r now More […]

Install Debian Jessie 8 on XenServer 6.5

To install Debian Jessie 8 on XenServer 6.5 we need first to create a template for Debian 8. To do so, login as root via SSH on the XenServer and create a file: vi debian8template.shvi debian8template.sh Add this content: #!/bin/bash ## Script to install a Debian Jessie 8 template on Xenserver 6.5 ## https://gist.github.com/jniltinho/0455fb5f01cfd8bbdbff ## […]

Delete a Template on XenServer

To delete a template on XenServer you can type: xe template-uninstall template-uuid=ENTER_TEMPLATE_UUID_HERE force=truexe template-uninstall template-uuid=ENTER_TEMPLATE_UUID_HERE force=true If it cannot be deleted due to these errors: The operation attempted is not valid for a template VM You cannot delete the specified default templateThe operation attempted is not valid for a template VM You cannot delete the […]

XenServer VM virtual disk could not be found

If with Xen Server 6.2 you get an error like this when you try to start a VM: Error: Starting VM ‘vm1’ – This operation cannot be performed because the specified virtual disk could not be foundError: Starting VM ‘vm1’ – This operation cannot be performed because the specified virtual disk could not be found […]

Add new NFS virtual disk storage to Virtual Machine (XenServer)

First you need to create a NFS Virtual Disk Storage via XenCenter. Then select a VM, open the “Storage” tab in XenCenter, and click the button “Add…”: Then you should see the virtual disk present in the list of virtual disks: The virtual disk is now attached and active in the virtual machine. Connect to […]

How to secure your XenServer with Iptables

We will allow only your IP address to connect on port 22, 80 and 443. Edit the iptables file located here: vi /etc/sysconfig/iptablesvi /etc/sysconfig/iptables Change these lines: -A RH-Firewall-1-INPUT -m state –state NEW -m tcp -p tcp –dport 22 -j ACCEPT -A RH-Firewall-1-INPUT -m state –state NEW -m tcp -p tcp –dport 80 -j ACCEPT […]

Useful storage repository commands XenServer

Show what is available on the physical disks: pvdisplaypvdisplay Example output: — Physical volume — PV Name /dev/md3 VG Name VG_XenStorage-14d4c49b-a46c-3e9d-6102-6a531b2be7d9 PV Size 1.81 TB / not usable 7.19 MB Allocatable yes PE Size (KByte) 4096 Total PE 474880 Free PE 458883 Allocated PE 15997 PV UUID 1y7deB-2V4S-AQBN-TRlM-1cT4-3WD1-1LZNE5 — Physical volume — PV Name /dev/md3 […]