Changing the MAC address of the VirtualBox Host-Only Adapter

Discussions related to using VirtualBox on Windows hosts.

Changing the MAC address of the VirtualBox Host-Only Adapter

Postby rooney » 30. Jan 2010, 20:20

Hello!

Is it possible to change the MAC address of the VirtualBox Host-Only ethernet adapter that can be found in "Settings->Network Connections"?

Regards,
Rooney
rooney
 
Posts: 7
Joined: 10. Mar 2009, 07:33

Re: Changing the MAC address of the VirtualBox Host-Only Adapter

Postby Perryg » 30. Jan 2010, 20:31

Sure. Click the advanced button. It is located there.
Perryg
Site Moderator
 
Posts: 25923
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX - Other

Re: Changing the MAC address of the VirtualBox Host-Only Adapter

Postby rooney » 30. Jan 2010, 20:50

I just can change the firewall settings no MAC address in the advanced options.
rooney
 
Posts: 7
Joined: 10. Mar 2009, 07:33

Re: Changing the MAC address of the VirtualBox Host-Only Adapter

Postby Perryg » 30. Jan 2010, 21:19

Strange. Mine has a MAC address. I might have started out with Bridged though. See screen shot.
But as long as you have it working. No problem.

HostOnlyMAC.jpg
HostOnlyMAC.jpg (34.58 KiB) Viewed 4442 times
Perryg
Site Moderator
 
Posts: 25923
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX - Other

Re: Changing the MAC address of the VirtualBox Host-Only Adapter

Postby mpack » 31. Jan 2010, 00:58

rooney wrote:I just can change the firewall settings no MAC address in the advanced options.

I think you are looking in the wrong place. Look in the Settings|Network area for the VM (in the VirtualBox GUI), not the network settings inside the guest.
mpack
Site Moderator
 
Posts: 13162
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows XP
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Changing the MAC address of the VirtualBox Host-Only Adapter

Postby rooney » 31. Jan 2010, 14:53

No, I don't want to change the MAC address of the guest, I want to change the network address of the VirtualBox Host-only ethernet adapter. Each VM has a different MAC, but the VirtualBox Host-only adapter you can find in Settings->Network Connections is always the same.

I solved the problem by changing some entries in the registry.

Regards,
Rooney
rooney
 
Posts: 7
Joined: 10. Mar 2009, 07:33

Re: Changing the MAC address of the VirtualBox Host-Only Adapter

Postby bithajcsar » 31. Jan 2010, 18:46

Hi All,
Maybe my problem is very similar:
I want to use several Host-Only Adapters and for each I want to have some specific IP address. However, VirtualBox always assigns its' default IP address and subnet mask to those adapters independently from the one I set up in the GUI. I tried even enter the correct address into the configuration XML file of the VirtualBox, but at the next start I can see again the default addresses (ipconfig /all) assigned by some VirtualBox features. Therefeor there should be some bug which prevents me to change the IP address of the Host-Only Adapter.
Does anyone know solution of that?

@rooney: Could you tell us what registry entries were relevant for your problem?

Thanks in advance!
Vasy (bithajcsar)
bithajcsar
 
Posts: 2
Joined: 29. Jan 2010, 11:49
Primary OS: MS Windows 7
VBox Version: PUEL
Guest OSses: SuSE, Ubuntu, RedHat, CentOS

Re: Changing the MAC address of the VirtualBox Host-Only Adapter

Postby MarkCranness » 1. Feb 2010, 00:38

rooney wrote:I solved the problem by changing some entries in the registry.

I haven't installed the host-only networking, so I can't check for sure, but there are some config items in menu:
File > Preferences... > Network > (select adapter) > Edit host-only network (screwdriver icon).
(On Mac it's ... > Options I think, rather than Preferences.)
MarkCranness
Volunteer
 
Posts: 875
Joined: 10. Oct 2009, 06:27
Primary OS: MS Windows 7
VBox Version: PUEL
Guest OSses: Windows Server 2008 R2; Ubuntu 11.04; Windows 2000 Server; Windows XP

Re: Changing the MAC address of the VirtualBox Host-Only Adapter

Postby bithajcsar » 1. Feb 2010, 00:52

MarkCranness wrote:
rooney wrote:I solved the problem by changing some entries in the registry.

I haven't installed the host-only networking, so I can't check for sure, but there are some config items in menu:
File > Preferences... > Network > (select adapter) > Edit host-only network (screwdriver icon).
(On Mac it's ... > Options I think, rather than Preferences.)


Exactly those changes are ignored completely in my case. I can not change the IP address of the interface.
bithajcsar
 
Posts: 2
Joined: 29. Jan 2010, 11:49
Primary OS: MS Windows 7
VBox Version: PUEL
Guest OSses: SuSE, Ubuntu, RedHat, CentOS

Re: Changing the MAC address of the VirtualBox Host-Only Adapter

Postby MarkCranness » 1. Feb 2010, 01:53

Just to be 100% sure (sorry), I'm suggesting:
File > Preferences > Network, and NOT
Settings > Network
MarkCranness
Volunteer
 
Posts: 875
Joined: 10. Oct 2009, 06:27
Primary OS: MS Windows 7
VBox Version: PUEL
Guest OSses: Windows Server 2008 R2; Ubuntu 11.04; Windows 2000 Server; Windows XP

Re: Changing the MAC address of the VirtualBox Host-Only Adapter

Postby rooney » 1. Feb 2010, 08:06

MarkCranness wrote:Just to be 100% sure (sorry), I'm suggesting:
File > Preferences > Network, and NOT
Settings > Network


Oh, I see, that is a great feature, can even add an additional interface.



To change the MAC address of the host-only adapter (NOT IP address and NOT the MAC address of your guest) you first have to determine the MAC address of the VirtualBox Host-only adapter. You can do so in the windows host by opening a command shell (start-->run-->cmd) and execute ipconfig -all.
The relevant network interface is listed as "VirtualBox Host-Only Ethernet Adapter" and will have a MAC address starting with 08-xx-xx-xx-xx-xx
Write down this MAC address.

Open your registry (start-->run-->regedit) and search for 08xxxxxxxxxx (without hyphen), whereby x stands for your specific MAC address. Somewhere in HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\... you will find the MAC entry of the ethernet adapter. Change the MAC address and reboot.

That's all!!!
rooney
 
Posts: 7
Joined: 10. Mar 2009, 07:33

Re: Changing the MAC address of the VirtualBox Host-Only Ada

Postby dams » 22. Jun 2013, 18:52

rooney wrote:
Open your registry (start-->run-->regedit) and search for 08xxxxxxxxxx (without hyphen), whereby x stands for your specific MAC address. Somewhere in HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\... you will find the MAC entry of the ethernet adapter. Change the MAC address and reboot.

That's all!!!


And does anywone know how to do this under Linux?
(change the virtualbox host host-only network interface mac address).

Thanks.
dams
 
Posts: 1
Joined: 22. Jun 2013, 18:11

Re: Changing the MAC address of the VirtualBox Host-Only Ada

Postby ankutsa » 24. Jun 2013, 12:22

For Linux simply click the refresh button.
..But after that you need to edit " /etc/udev/rules.d/70-persistent-net.rules" in your Linux and remove all lines. Otherwise new "kernel" names are assigned to the adapters, like "eth5" etc, which may screw up your config if you relied on eth0 for example.
ankutsa
 
Posts: 3
Joined: 23. Jun 2013, 21:36


Return to VirtualBox on Windows Hosts

Who is online

Users browsing this forum: FrankJor and 38 guests