VMware Cloud Community
Vibz03
Contributor
Contributor

virtual machine on private network

Hi,

I have private virtual machines on 10.0.4.x network. Host machine is esx 3.5 server with two nics. one nic is connected to internet ( via company switch ) and other nic is not connected anywhere. virtual console is on configured on nic which is conncted. Question is what would be the default gateway for virtual machines running on private network. how do i make these machines to connect to internet. i can resolve and ping various websites from host mahcine ( ssh to virtual console and pining www.google.co.uk ) but same can not be done from virtual machine.

Thanks for the help in advance.

vibz

0 Kudos
5 Replies
Yattong
Expert
Expert

Hey,

The easiest way would be to attach the unused nic to the VM portgroup.

Connect this nic to a physical LAN with connectivity to the internet.

The gateway in this case would be your router or proxy.



If you found this or any other answer useful please consider the use of the Helpful or correct buttons to award points

~y

If you found this or any other answer useful please consider the use of the Helpful or correct buttons to award points ~y
0 Kudos
Vibz03
Contributor
Contributor

Hi,

Thanks for your reply.

Can this be done without connecting second nic to the network.? i can reach internet from host using only one nic. so why the need of connecting second nic.

also, where would NATing happnen? virtual machines are on 10.0.4.x private network and how would these addresses get translated into ip of nic1?

Vibz

0 Kudos
Yattong
Expert
Expert

From your questioning, it seems you have not grasped the networking concepts with ESX.

You should read these docs to proceed...

http://www.vmware.com/support/pubs/vi_pages/vi_pubs_35u2.html

Can this be done without connecting second nic to the network.? i can reach internet from host using only one nic. so why the need of connecting second nic.

Yes it can, you could create a VM portgroup on the same vSwitch as the Service Console.

You could then create a VM which could act as a router between your private network and the same network as the Service Console

(maybe you should describe your network configuration so that we can have a better idea of what will work?)

also, where would NATing happnen? virtual machines are on 10.0.4.x private network and how would these addresses get translated into ip of nic1?

In my original suggestion, Nat'ing would be at your physical router.

If you use a VM as a router, then you would use the VM routers IP address as gateway and NAT device.

These are suggestion to help you get up and running with ESX, not for production use.



If you found this or any other answer useful please consider the use of the Helpful or correct buttons to award points

~y

If you found this or any other answer useful please consider the use of the Helpful or correct buttons to award points ~y
0 Kudos
Vibz03
Contributor
Contributor

Hi ,

Thanks for the link.

I have already tried with vyatta router and also with MS RRAS and it is working fne, when either router or RRAS is connected to the same network as service console. However, for proof of concept for something in production environment ( with watchguard firewall, where you can configure same ip on all network interfaces and also create secondary private ip on each interfaces. ) i want private ip address leaving esx host ( not possible !! ) or have host machine remember NATing from private to its public ( instead of vyatta router or MS RRAS ). do you know if this can be done.

Thanks .

Vibz

0 Kudos
Yattong
Expert
Expert

If I correctly understand your question,

You're basically asking whether you can use ESX or the Service Console as a router,

Answer is: No, it is not what ESX/Service console is used for, and is definitely not best practice.

The Service console network is there so you can manage the ESX host server, not to route or NAT VM's.

If you want to read about secure network, or DMZ read this.



If you found this or any other answer useful please consider the use of the Helpful or correct buttons to award points

~y

If you found this or any other answer useful please consider the use of the Helpful or correct buttons to award points ~y
0 Kudos