"Bridged Adapter" issue while running CentOS 6.3 on VirtualBox.
Posted: 2012/09/03 08:27:13
Hi Folks,
I was fighting with this issue for a long time but failed to find a general solution to it.
Host: Microsoft Windows 7 SP1
Guest: CentOS 6.3
VM: Oracle VirtualBox 4.1
Network Setting on VM guest: "Bridged Adapter"
Issue description:
After fresh installation, network on guest CentOS always shows icon with red "x" on the top-right.
On some PC(my work PC for instance), I can click on that icon and then click "System eth0" in the drop-down menu, then after seconds it starts working.
However, on my home PC, clicking that icon never helps.
I did a lot searching online, found quite a few similar issues and discussions, but still cannot find a solution.
Some weird things I can think about:
- "NAT" mode works fine. But I need "Bridged Adapter";
- I have installed some other Linux distributions on VirtualBox, CentOS is the only one having this kind of issue; Windows guests work well too.
- I created and installed a guest on VirtualBox 4.1.18 the other day, network didn't work. Then I overwrite-updated VirtualBox software to 4.1.20, all of a sudden that guest's network started working flawlessly! No setting was changed at all! However, later I created and installed another guest with all the same settings but it has the same issue again;
- After trying the solutions I found on the Internet, I found out it looks like a DHCP-related issue. When I issue "/etc/init.d/network restart" command, everything shows OK until the last action "Determining IP information for eth0... Failed". I do have a DHCP server (ADSL-router) in my home network and it works fine (I have no other issue with that).
Here is what I have tried:
1. After fresh installation:
[code][root@localhost Desktop]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
BOOTPROTO="dhcp"
HWADDR="08:00:27:44:5B:C5"
NM_CONTROLLED="yes"
ONBOOT="no"
TYPE="Ethernet"
UUID="f8e1217d-11be-48b1-8c45-437cddfe9b0f"
[root@localhost Desktop]# /etc/init.d/network restart
Shutting down interface eth0: Error: Device 'eth0' (/org/freedesktop/NetworkManager/Devices/0) disconnecting failed: This device is not active
[FAILED]
Shutting down loopback interface: [ OK ]
Bringing up loopback interface: [ OK ][/code]
2. Changed "ONBOOT=no" to "ONBOOT=yes"
[code][root@localhost Desktop]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
BOOTPROTO="dhcp"
HWADDR="08:00:27:44:5B:C5"
NM_CONTROLLED="yes"
ONBOOT="yes"
TYPE="Ethernet"
UUID="f8e1217d-11be-48b1-8c45-437cddfe9b0f"
[root@localhost Desktop]# /etc/init.d/network restart
Shutting down interface eth0: Error: Device 'eth0' (/org/freedesktop/NetworkManager/Devices/0) disconnecting failed: This device is not active
[FAILED]
Shutting down loopback interface: [ OK ]
Bringing up loopback interface: [ OK ]
Bringing up interface eth0: Active connection state: activating
Active connection path: /org/freedesktop/NetworkManager/ActiveConnection/2
** (process:3004): WARNING **: _nm_object_get_property: Error getting 'State' for /org/freedesktop/NetworkManager/ActiveConnection/2: (19) Method "Get" with signature "ss" on interface "org.freedesktop.DBus.Properties" doesn't exist
state: unknown
Error: Connection activation failed.
[FAILED][/code]
3. Changed "NM_CONTROLLED=yes" to "no"
[code][root@localhost Desktop]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
BOOTPROTO="dhcp"
HWADDR="08:00:27:44:5B:C5"
NM_CONTROLLED="no"
ONBOOT="yes"
TYPE="Ethernet"
UUID="f8e1217d-11be-48b1-8c45-437cddfe9b0f"
[root@localhost Desktop]# /etc/init.d/network restart
Shutting down loopback interface: [ OK ]
Bringing up loopback interface: [ OK ]
Bringing up interface eth0:
Determining IP information for eth0...PING 10.0.2.2 (10.0.2.2) from 10.0.2.15 eth0: 56(84) bytes of data.
--- 10.0.2.2 ping statistics ---
4 packets transmitted, 0 received, +3 errors, 100% packet loss, time 3002ms
pipe 3
failed.
[FAILED][/code]
I have no idea where that "10.0.x.x" IP address came from. My DHCP server is set to the IP range "192.168.3.X".
4. remove the "NM_CONTROLLED" line
[code]root@localhost Desktop]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
BOOTPROTO="dhcp"
HWADDR="08:00:27:44:5B:C5"
#NM_CONTROLLED="no"
ONBOOT="yes"
TYPE="Ethernet"
UUID="f8e1217d-11be-48b1-8c45-437cddfe9b0f"
[root@localhost Desktop]# /etc/init.d/network restart
Shutting down interface eth0: Device state: 3 (disconnected)
[ OK ]
Shutting down loopback interface: [ OK ]
Bringing up loopback interface: [ OK ]
Bringing up interface eth0: Active connection state: activating
Active connection path: /org/freedesktop/NetworkManager/ActiveConnection/2
^[[24~
** (process:2640): WARNING **: _nm_object_get_property: Error getting 'State' for /org/freedesktop/NetworkManager/ActiveConnection/2: (19) Method "Get" with signature "ss" on interface "org.freedesktop.DBus.Properties" doesn't exist
state: unknown
Error: Connection activation failed.
[FAILED][/code]
Any help?
Thanks a lot.
Jeremy
I was fighting with this issue for a long time but failed to find a general solution to it.
Host: Microsoft Windows 7 SP1
Guest: CentOS 6.3
VM: Oracle VirtualBox 4.1
Network Setting on VM guest: "Bridged Adapter"
Issue description:
After fresh installation, network on guest CentOS always shows icon with red "x" on the top-right.
On some PC(my work PC for instance), I can click on that icon and then click "System eth0" in the drop-down menu, then after seconds it starts working.
However, on my home PC, clicking that icon never helps.
I did a lot searching online, found quite a few similar issues and discussions, but still cannot find a solution.
Some weird things I can think about:
- "NAT" mode works fine. But I need "Bridged Adapter";
- I have installed some other Linux distributions on VirtualBox, CentOS is the only one having this kind of issue; Windows guests work well too.
- I created and installed a guest on VirtualBox 4.1.18 the other day, network didn't work. Then I overwrite-updated VirtualBox software to 4.1.20, all of a sudden that guest's network started working flawlessly! No setting was changed at all! However, later I created and installed another guest with all the same settings but it has the same issue again;
- After trying the solutions I found on the Internet, I found out it looks like a DHCP-related issue. When I issue "/etc/init.d/network restart" command, everything shows OK until the last action "Determining IP information for eth0... Failed". I do have a DHCP server (ADSL-router) in my home network and it works fine (I have no other issue with that).
Here is what I have tried:
1. After fresh installation:
[code][root@localhost Desktop]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
BOOTPROTO="dhcp"
HWADDR="08:00:27:44:5B:C5"
NM_CONTROLLED="yes"
ONBOOT="no"
TYPE="Ethernet"
UUID="f8e1217d-11be-48b1-8c45-437cddfe9b0f"
[root@localhost Desktop]# /etc/init.d/network restart
Shutting down interface eth0: Error: Device 'eth0' (/org/freedesktop/NetworkManager/Devices/0) disconnecting failed: This device is not active
[FAILED]
Shutting down loopback interface: [ OK ]
Bringing up loopback interface: [ OK ][/code]
2. Changed "ONBOOT=no" to "ONBOOT=yes"
[code][root@localhost Desktop]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
BOOTPROTO="dhcp"
HWADDR="08:00:27:44:5B:C5"
NM_CONTROLLED="yes"
ONBOOT="yes"
TYPE="Ethernet"
UUID="f8e1217d-11be-48b1-8c45-437cddfe9b0f"
[root@localhost Desktop]# /etc/init.d/network restart
Shutting down interface eth0: Error: Device 'eth0' (/org/freedesktop/NetworkManager/Devices/0) disconnecting failed: This device is not active
[FAILED]
Shutting down loopback interface: [ OK ]
Bringing up loopback interface: [ OK ]
Bringing up interface eth0: Active connection state: activating
Active connection path: /org/freedesktop/NetworkManager/ActiveConnection/2
** (process:3004): WARNING **: _nm_object_get_property: Error getting 'State' for /org/freedesktop/NetworkManager/ActiveConnection/2: (19) Method "Get" with signature "ss" on interface "org.freedesktop.DBus.Properties" doesn't exist
state: unknown
Error: Connection activation failed.
[FAILED][/code]
3. Changed "NM_CONTROLLED=yes" to "no"
[code][root@localhost Desktop]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
BOOTPROTO="dhcp"
HWADDR="08:00:27:44:5B:C5"
NM_CONTROLLED="no"
ONBOOT="yes"
TYPE="Ethernet"
UUID="f8e1217d-11be-48b1-8c45-437cddfe9b0f"
[root@localhost Desktop]# /etc/init.d/network restart
Shutting down loopback interface: [ OK ]
Bringing up loopback interface: [ OK ]
Bringing up interface eth0:
Determining IP information for eth0...PING 10.0.2.2 (10.0.2.2) from 10.0.2.15 eth0: 56(84) bytes of data.
--- 10.0.2.2 ping statistics ---
4 packets transmitted, 0 received, +3 errors, 100% packet loss, time 3002ms
pipe 3
failed.
[FAILED][/code]
I have no idea where that "10.0.x.x" IP address came from. My DHCP server is set to the IP range "192.168.3.X".
4. remove the "NM_CONTROLLED" line
[code]root@localhost Desktop]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
BOOTPROTO="dhcp"
HWADDR="08:00:27:44:5B:C5"
#NM_CONTROLLED="no"
ONBOOT="yes"
TYPE="Ethernet"
UUID="f8e1217d-11be-48b1-8c45-437cddfe9b0f"
[root@localhost Desktop]# /etc/init.d/network restart
Shutting down interface eth0: Device state: 3 (disconnected)
[ OK ]
Shutting down loopback interface: [ OK ]
Bringing up loopback interface: [ OK ]
Bringing up interface eth0: Active connection state: activating
Active connection path: /org/freedesktop/NetworkManager/ActiveConnection/2
^[[24~
** (process:2640): WARNING **: _nm_object_get_property: Error getting 'State' for /org/freedesktop/NetworkManager/ActiveConnection/2: (19) Method "Get" with signature "ss" on interface "org.freedesktop.DBus.Properties" doesn't exist
state: unknown
Error: Connection activation failed.
[FAILED][/code]
Any help?
Thanks a lot.
Jeremy