How to assign ip to virtual machine on cent os xen host machine?

Discussion in 'HOWTO-Related Questions' started by JACOBKELL, Aug 21, 2009.

  1. JACOBKELL

    JACOBKELL New Member

    I used this tutorial:
    http://www.howtoforge.com/paravirtualization-with-xen-on-centos-5.3-x86_64
    to install xen,but when i tried dhcp or manualy enter ip during installation of guest cent os machine,i get message no such site which i think probably means ip address which i entered didn't been accepted and it cannot connect to internet.Do i maybe first need to remove desired ip adress from host machine or is there something else to configure?
     
  2. falko

    falko Super Moderator ISPConfig Developer

    The IP you want to use must not be configured anywhere else, e.g. on the host.
    Do you have a DHCP server in your network?
     
  3. JACOBKELL

    JACOBKELL New Member

    I host on softlayer resseler,so i guess yes.I just ordered block of new ip's(4 new ip's)which i didn't added yet on host machine.Should i try now simply to add one of those new ip adress to guest machine?
     
  4. falko

    falko Super Moderator ISPConfig Developer

    Yes, try that.
     
  5. JACOBKELL

    JACOBKELL New Member

    Nop still cannot find.
    I find this about virtual machines on softlayer:
    http://knowledgelayer.softlayer.com/questions/372/Static and Portable IP blocks
    Maybe i need to assign entire block of ip to virtual machine?
    And this is what i added now:
    |IPv4 address: freeipadress___ / 255.255.255.0___ |
    |Gateway: ____________________________ |
    |Name Server: 10.0.80.11,10.0.80.12
    I going to install iso from disk,so i can at least have prepared virtual machine.But it seems even then it is required
    to define source of iso,what to select,cdrom,hard disk,nsf,http or ftp?
     
    Last edited: Aug 23, 2009
  6. JACOBKELL

    JACOBKELL New Member

    I found tutorial on softlayer(my host)for installing xen server and it seems it required a lot of network configuration edit.Can i send it to you so you can see it?There are some things which i don't understood there.
     
    Last edited: Aug 24, 2009
  7. matey

    matey New Member

    they way I did it was to mount the xen FS onto /mnt/ then chroot to it then set name, root password and edit /etc/network/interfaces and do
    auto eth0
    iface eth0 inet static
    address 10.0.52.110
    netmask 255.255.255.0
    network 10.0.52.0
    broadcast 10.0.52.255
    gateway 10.0.52.1

    or something like that. then exit, umount then edit my xen config file /etc/xen/ and make sure I give it a virtual NIC
    there are couple of ways that I know of, one is to use vif and the other to give it a MAC address then IP.

    The thing I also do is when I chroot to /mnt/xenmachine/
    I set root password the Same as the main machine's root just in case.
    then you can change once boot up.
     

Share This Page