Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I am running Fedora 15 on VirtualBox 4 and I am failing to reach the internet:

$ ping
connect: Network is unreachable

Firefox also refuses, telling me "Server not found".

Running sudo service network restart and restarting the VM didn't help.

share|improve this question
How do you expect to be connected? Since this is in VirtualBox, tell us what network settings you've set for this VM in VirtualBox. And tell us what you've configured in the Fedora system. –  Gilles Jun 3 '11 at 18:15
Other than removing NetworkManager, I haven't done anything else network-related. –  Tshepang Jun 3 '11 at 18:35
@Tshepang: Errm, if you haven't configured anything to replace Network Manager, how do you expect to have a network setup at all? So maybe your question is “how do I set up simple network connectivity under Fedora?”, and you need to say at least whether you want a static address or DHCP. –  Gilles Jun 3 '11 at 18:38
So, have you configured a networking file then? –  Faheem Mitha Jun 3 '11 at 20:10
@FaheemMitha: No config at all. I expected this to work because I think I didn't configure anything previously. –  Tshepang Jun 3 '11 at 22:25

2 Answers 2

There are at least 2 things to check/configure for the guest to have access to the internet.

  1. The settings in the fedora guest. They live in /etc/sysconfig/network-scripts. There is one for each interface. Configure the one that you want to access the internet.

  2. The network device configured in the VirtualBox settings (Devices => Network Adapters). Here is an example from an Ubuntu host.

    • The "Bridged adapter" setting means that the guest transparently sees the network as if it had access to the host network adapter (which has actually set itself in promiscuous mode and is just forwarding the IOs for the guest's MAC address).
    • eth0 is the interface of the host. It is up to you to decide how it will be seen in the guest.
    • You need to uncheck/check the 'Cable connected' checkbox manually each time the host connectivity is becoming active.

VBox guest network adapters

share|improve this answer
I changed to Bridged Adapter, and it didn't work. –  Tshepang Jun 4 '11 at 10:30

@Tshepang, one thing you definitely need to do is configure a bridge interface (br0 below) on the host. Here is the current version of my /etc/network/interfaces. VirtualBox is the only reason I have it configured as a bridge. Do you have it set up like this? I got this from somewhere on the net. I forget where, but if you really want I can probably dig up a link for you. I took a look at my Fedora 14 VirtualBox guest, and it doesn't look like I configured any networking stuff there. So try making this change and see if it makes any difference. On my machine eth1 is the main ethernet interface.

# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
#allow-hotplug eth1
#iface eth1 inet dhcp

auto br0
iface br0 inet dhcp
        bridge_ports eth1
        bridge_fd 0
        bridge_maxwait 0
share|improve this answer
I don't even have the file /etc/network/interface, and I thought that was a Debian thing. You sure you didn't mix things up? –  Tshepang Jun 5 '11 at 16:06
Your host is Debian, right? I'm talking about configuration on the host. And Debian always has /etc/network/interfaces. –  Faheem Mitha Jun 5 '11 at 16:23
Oh, I thought you were referring to the guest. I read that first sentence too quickly. –  Tshepang Jun 5 '11 at 18:32
Doing service networking start gives Cannot find device "br0". Do I have to do some more configuration? –  Tshepang Jun 5 '11 at 18:36
@Tshepang: Do you have bridge-utils installed? –  Faheem Mitha Jun 5 '11 at 19:31

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.