Host Networking sucess with vmnet1 (Vmware Host Interface)

Discussions related to using VirtualBox on Linux hosts.
Post Reply
raja_s_patil
Posts: 6
Joined: 30. Nov 2008, 10:38

Host Networking sucess with vmnet1 (Vmware Host Interface)

Post by raja_s_patil »

Hello,

Today I demontrated VirtualBox to one of my friends. During this process by mistake i attached vmnet1 to VB's Host interface and found that I could access Vmware VMs, Host samba server shares and The own VB VM shares seemlessly. So a idea struck to me
:idea:
If i could configure a network Interface similar to Vmware's VMnet1, configure DHCP to it I could solve my long pending issue of virtual Internal LAN of VB VMs which I plan for Software testing could be resolved.
:idea:
Can somebody elaborate me how I could do this. with various command i have to use.

the ifconfig output is

Code: Select all


eth0      Link encap:Ethernet  HWaddr 00:21:70:c7:c7:35
          inet addr:192.168.1.248  Bcast:192.168.1.255
          Mask:255.255.255.0
          inet6 addr: fe80::221:70ff:fec7:c735/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  
          MTU:1500  Metric:1
          RX packets:152767 errors:0 dropped:3715331736
          overruns:0 frame:0
          TX packets:52351 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:114054397 (108.7 MB)  TX bytes:3723064 (3.5 MB)
          Interrupt:218 Base address:0x2000

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:1324 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1324 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:84466 (82.4 KB)  TX bytes:84466 (82.4 KB)

vbox0     Link encap:Ethernet  HWaddr 00:ff:05:70:28:e8
          inet6 addr: fe80::2ff:5ff:fe70:28e8/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:6 overruns:0 carrier:0
          collisions:0 txqueuelen:500
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

vmnet1    Link encap:Ethernet  HWaddr 00:50:56:c0:00:01
          inet addr:10.1.1.1  Bcast:10.1.1.255  Mask:255.255.255.0
          inet6 addr: fe80::250:56ff:fec0:1/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:3 errors:0 dropped:0 overruns:0 frame:0
          TX packets:263 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

vmnet8    Link encap:Ethernet  HWaddr 00:50:56:c0:00:08
          inet addr:172.16.183.1  Bcast:172.16.183.255  Mask:255.255.255.0
          inet6 addr: fe80::250:56ff:fec0:8/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:24 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

and route output is

Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
172.16.183.0    *               255.255.255.0   U     0      0        0 vmnet8
192.168.1.0     *               255.255.255.0   U     0      0        0 eth0
10.1.1.0        *               255.255.255.0   U     0      0        0 vmnet1
link-local      *               255.255.0.0     U     1000   0        0 eth0
default         192.168.1.1     0.0.0.0         UG    100    0        0 eth0
the vmnet1 address was 10.1.1.1, DCP was running on
10.1.1.2 and VMs were getting ips >= 10.1.1.130
TerryE
Volunteer
Posts: 3572
Joined: 28. May 2008, 08:40
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Ubuntu 10.04 & 11.10, both Svr&Wstn, Debian, CentOS
Contact:

Post by TerryE »

Because of various interoperation issues, parallel execution of VMware and VirtualBox is not supported (see the UG for more details), therefore I think that you are really on your own in working out how to do clever things between VBox and vmnet1.

However, if you want to solve your "long pending issue of virtual Internal LAN of VB VMs" perhaps you could explain what you mean and we could help.
Read the Forum Posting Guide
Google your Q site:VirtualBox.org or search for the answer before posting.
raja_s_patil
Posts: 6
Joined: 30. Nov 2008, 10:38

Post by raja_s_patil »

Thanks Terryl

I plan to use VMs for testing of database application.

Host will act as Database server and a samba server (10.1.1.1)
On smba shares application exe and support dll will reside.

Guest 1 (XP) (10.1.1.<dhcp or fixed>
will execute exe from samba share and access database server.

Guest 2 (XP) (10.1.1.<dhcp or fixed>
will execute exe from samba share and access database server.

no of guests may increase but i think same process can
be repeated for additional guests.

I want to test concurrency and messaging between nodes which is
based on events fired on database.

The RDBMS is firebird and database will reside on Host OS secured Directory.

In later part of test I want to open VPN kind of stuff but its not
need at present and the idea is not yet consolidated.

Hope this much information is enough. Right now I have to go to my
friends place to carry these tests, he has VMware installed and this
setup is working on his machine. I want to emulate the virtual switch which is used in VMware on linux. I have demonstrated Virtual box to him, he is impressed with speed of booting and seemless mode of virtual box.

Please help me in this regard.
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Post by Sasquatch »

If you want contained Host <> Guest communication, check out the VirtualBox FAQ and look for the MS Loopback Adapter. Install that, set your VMs to use Host Interface and point to the loopback. Set static addresses on all sides and you should be working.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
Post Reply