VMWare: Windows 2003 Host, CentOS 5 Guest – Bridged Networking


We would usually just setup a NAT based VM appliance for any new requirement. Most of the time, access is limited to ones desktops. When the need arise for a shared Linux VM on our local Windows 2003 server, the inexperienced may find it trouble setting up the CentOS guest as a reachable application server just like its host OS.

To achieve this, make sure the following items a re true:

  • HOST » VMWare » Edit » Virtual Network Editor
  1. Automatic Bridging - "Automatically choose an available physical network adapter to bridge to VMNet0" is UNCHECKED
  2. Host Virtual Network Mapping - VMNet0 is mapped to you chosen physical adapter, NOT automatically.
  3. You can disable NAT, DHCP and Host Virtual Network Adapters
  • HOST » Control Panel » Network Connections
  1. Right click your chosen physical adapter, then Properties. Make sure "VMWare Bridge Protocol" is CHECKED.
  • GUEST - Assign an unused static IP, the same network/netmask and gateway that is used on your host's physical adapter.

Other items worth checking when inbound and outbound connections from the guest OS:

  • Host firewall
  • Guest DNS server settings, resolv.conf.

This checklist should get you up and running with a virtualized development platform with the same network visibility as a physical machine in your office.

, , ,

  1. #1 by Sami on April 19, 2010 - 4:00 PM

    Hi dear , i want to ask you what if the main IP have netmask different than additional IP’s on the server ? example :

    Main ip : 179.166.11.155
    netmask : 255.255.255.248
    default gateway : 179.166.11.88

    Additional IP’S is 74.13.22.68 ~ 80
    netmask : 255.255.255.0

    So what is the guest os network setting ?

    Thanks for your topic !

  2. #2 by admin on April 19, 2010 - 4:16 PM

    Sami,

    Depends on which adapter VMNet0 is mapped to. If it is mapped to the host interface with the main IP, then it must have the same netmask as the main IP. Same goes with the supplemental IPs.

    Cheers!

  3. #3 by Sami on April 19, 2010 - 4:48 PM

    Thanks for your reply , i try that but no success
    Host : windows server 2003
    guest : windows xp

    may i must made some registry modification like IPENABLEROUTER one in the registry key Tcpip\Parameters to 1 ? or enable Routing and Remote Access Service ? is that true ?

  4. #4 by admin on April 19, 2010 - 4:53 PM

    Sami,

    I never needed to make any registry changes on the host nor the guest. What VMWare version are you using?

    Cheers

  5. #5 by Sami on April 19, 2010 - 4:54 PM

    i’am using vmware workstation 7.0.1 .

    Thanks

  6. #6 by admin on April 19, 2010 - 5:01 PM

    Sami,

    How are you testing? How many interfaces does your host have? How many does you guest have? What are your virtual network mappings? Any firewall on your host?

    There can be many factors why this will not work, you might need to trace them one by one from host to mapping to guest and back.

    Cheers

  7. #7 by Sami on April 19, 2010 - 6:18 PM

    i have dedicated server on softlayer testing on it . i have 2 interfaces “public / private interface ) i mapped vmnet0 to public one , i have 1 vm on the host

    New hint : i can ping the host ip but i cant ping any public ip . guessing its dns problem

  8. #8 by admin on April 19, 2010 - 8:09 PM

    Sami,

    If you are pinging by IP then it’s not DNS.

    Is the IP you assign to the guest assigned to you by SoftLayer? Confirm with them the usable IP addresses to be sure.

    Cheers

(will not be published)