When running out of current assigned IP ranges, you will need to add a new IP range to Citrix XenServer before can assigning it to specific VMs. This tutorial contains step-by-step guide on this work. The following work will be done in the main server which hosts Citrix XenServer.
- When requesting additional IPs you should specifically request that a full network block be assigned. Regardless of what size you are assigned, you will need to use 3 IP addresses for administrative purposes (1 as a network address, 1 as a broadcast address and 1 as the “default gateway”). For example:
- The requested IP block is XXX.XXX.XXX.112/29
- Usable IP Range – XXX.XXX.XXX.114 – XXX.XXX.XXX.118
- Gateway – XXX.XXX.XXX.113
- Netmask – 255.255.255.248
- Create a new network interface for new IP range:[bash]vi /etc/sysconfig/network-scripts/ifcfg-newiprange[/bash]
- Remember to set the device information in the new network interface to dummy0. Sample configuration is as follows (the YOUR_FIRST_UNUSED_IP IP in the above example is XXX.XXX.XXX.114):[bash]XEMANAGED=yes
- Setting up the new network interface:[bash]ifup newiprange[/bash]
- Try pinging your first assigned IP in
- Next, you will need to add the remaining unsed IPs in your new IP range to the route:[bash]ip route add XXX.XXX.XXX.115 dev xenbr0
ip route add XXX.XXX.XXX.116 dev xenbr0
ip route add XXX.XXX.XXX.117 dev xenbr0
ip route add XXX.XXX.XXX.118 dev xenbr0[/bash]
- Finally, you need to add the above commands to the end of the /etc/rc.local file so that the routes are established any time you reboot the server.
- That’s all! You can now using the new IP range in your guest VMs.