Page 1 of 1

net simulation, how? [Solved !!!]

Posted: 26. Apr 2009, 19:52
by eduardo.l
(sorry about my english...)
Guys, I just want to simulate a simple net here and I didn't find out how yet...
I just need to make 2 virtual Windows XP "to see" each other in a virtual net.
I did configure the Ethernet device at the virtual XP machines as "host interface".
At XP net configurations I used IP 192.168.1.x; 255.255.255.0; Gateway: DON'T KNOW WHAT TO USE (need help here); DNS need help too...
I am not understanding where is the DHCP server and DNS servers...
How it works at VBox net structure?

My host PC (Ubuntu) is connected directly at internet, there is no Router or nothing. The Ethernet interface is conected to a Motorola SBV5121 Cable Modem.

Thanks.

Re: net simulation, how?

Posted: 27. Apr 2009, 01:06
by Technologov
Do you want your VMs to see each others and the Internet, right?

Easiest (and secure) setup for that case is to use 2 NICs (LAN cards) on each VM. One for internal network, and other for NAT.

Another possibility is to use your host OS as a router (+DHCP server+NAT), but this requires more complex configuration

Re: net simulation, how?

Posted: 6. May 2009, 03:56
by eduardo.l
Thank you a lot!! This is exactly what I want.

I got it.

:D

Re: net simulation, how? [Solved !!!]

Posted: 19. May 2009, 03:57
by shinichikudo
ModEdit: contents removed, due to forum policy violation.

Re: net simulation, how? [Solved !!!]

Posted: 19. May 2009, 07:14
by july865
this sounds exactly like i wanted to do.
i scrapped ubunto and loaded xp pro in the VB on an xp 64bit host. (my program couldnt run with wine.
can some one post a setup guide that i can use?
i want to run a game on the VB. have my friends connect to it and me on the host. but i cant seem to connect to the game and neither can my friends.
im sorry for robbing the thread
please help!!

Re: net simulation, how? [Solved !!!]

Posted: 20. May 2009, 02:23
by vanesssa99
ModEdit: contents removed, due to forum policy violation.

Re: net simulation, how? [Solved !!!]

Posted: 20. May 2009, 02:30
by Technologov
july865: What you want is very different. Because you're asking people to connect to you, you essentially converting your VM to a server.

Here you must use "Host Networking" feature of VirtualBox, and configure your home router to forward all non-NATted traffic to your VM. This feature is called DMZ in home routers. Not all home routers support it, so you may need to route specific TCP+UDP ports.

Alternatively, you can try "Hamachi VPN".

-Technologov

Re: net simulation, how?

Posted: 20. May 2009, 14:18
by noaml
Technologov wrote:Do you want your VMs to see each others and the Internet, right?

Easiest (and secure) setup for that case is to use 2 NICs (LAN cards) on each VM. One for internal network, and other for NAT.

Another possibility is to use your host OS as a router (+DHCP server+NAT), but this requires more complex configuration
I tried to simulate this. On one machine I did:
C:\Documents and Settings\Joe>ipconfig /renew

Windows IP Configuration

An error occurred while renewing interface Local Area Connection : unable to con
tact your DHCP server. Request has timed out.

Ethernet adapter Local Area Connection:

Connection-specific DNS Suffix . :
Autoconfiguration IP Address. . . : 169.254.208.89
Subnet Mask . . . . . . . . . . . : 255.255.0.0
Default Gateway . . . . . . . . . :

Ethernet adapter Local Area Connection 2:

Connection-specific DNS Suffix . : iloffice.mainsoft.com
IP Address. . . . . . . . . . . . : 10.0.2.15
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 10.0.2.2

On the other machine I did the same:

C:\Documents and Settings\Joe>ipconfig /renew

Windows IP Configuration

An error occurred while renewing interface Local Area Connection : unable to con
tact your DHCP server. Request has timed out.

Ethernet adapter Local Area Connection:

Connection-specific DNS Suffix . :
Autoconfiguration IP Address. . . : 169.254.54.181
Subnet Mask . . . . . . . . . . . : 255.255.0.0
Default Gateway . . . . . . . . . :

Ethernet adapter Local Area Connection 2:

Connection-specific DNS Suffix . : iloffice.mainsoft.com
IP Address. . . . . . . . . . . . : 10.0.2.15
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 10.0.2.2

After that ping from one to the other did not work.
Any suggestions?

Thanks,

Noam

Re: net simulation, how? [Solved !!!]

Posted: 20. May 2009, 14:48
by baf
did you try to ping the 169.254.x.x addresses? these are the ones you should use between the guests. Or better give those interfaces static addresses on say 192.168.11.x mask 255.255.255.0 no router no dns info.
where 11 is any net you dont use and that isn't 56 (used by host only as default).

Remember there is no dhcp server on internal net unless you configure one of the guests as such.

Re: net simulation, how? [Solved !!!]

Posted: 20. May 2009, 15:35
by noaml
It worked ! thanks !

The main problem was that the XP guest systems had a firewall turned on (default after install of XP). Turning them off helped a bit ;-)

I configured both machines to two cards, one with host-only adapter, and one with NAT. I had to manually set the gateway, and then all was cool.

Noam

Re: net simulation, how? [Solved !!!]

Posted: 24. May 2009, 03:50
by singeroi
hello, im pretty new here and have similar problem like yours. how did you able to setup the gateway and nat settings? thanks for any help.

Re: net simulation, how? [Solved !!!]

Posted: 24. May 2009, 07:42
by Technologov
singeroi: You don't ! NAT is a default setting in VirtualBox. VirtualBox has it's own internal DHCP server, that tells guest OSes which IP address, subnet mask, DNS and gateway to use. It is 100% Automatic. And.. Ooh yes, it has DNS proxy built-in too.

If you want manual control, then you choose "Host Interface Networking", and here the sky is the limit. Complex network simulations done this way.

-Technologov