0
I have a web server running on Oracle Linux 6.4 on VirtualBox. It has an eth1
address of 10.0.2.15
. I want to be able to run a web server from this virtual machine, but I can’t access the virtual machine from my host. The guest OS also can’t reach the Internet; I can’t ping Google.
Currently, the network adapter in virtual machine settings is configured as NAT. Here’s the file at /etc/sysconfig/network-scripts/ifcfg-eth1
:
DEVICE=eth1
TYPE=Ethernet
#UUID=47fc2dd9-bca4-4912-95b5-7939b3e0ebf5
ONBOOT=yes
NM_CONTROLLED=no
BOOTPROTO=dhcp
HWADDR=08:00:27:06:9c:d5
DEFROUTE=yes
PEERDNS=yes
PEERROUTES=yes
IPV4_FAILURE_FATAL=yes
IPV6INIT=no
NAME="System eth1"
LAST_CONNECT=1392385849
How do I need to configure my networking, both in the virtual machine settings and on the guest OS?
EDIT
ifconfig:
# ifconfig
eth1 Link encap:Ethernet HWaddr 08:00:27:06:9C:D5
inet addr:10.0.2.15 Bcast:10.0.2.255 Mask:255.255.255.0
inet6 addr: fe80::a00:27ff:fe06:9cd5/64 Scope:Link
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:21 errors:0 dropped:0 overruns:0 frame:0
TX packets:90 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:3731 (3.6 KiB) TX bytes:6688 (6.5 KiB)
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:12 errors:0 dropped:0 overruns:0 frame:0
TX packets:12 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:720 (720.0 b) TX bytes:720 (720.0 b)
virbr0 Link encap:Ethernet HWaddr 52:54:00:B9:22:2C
inet addr:192.168.122.1 Bcast:192.168.122.255 Mask:255.255.255.0
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
Sorry to hear about this. Can you please edit the question to add more details. Such as what is the output of
ifconfig
and perhaps the contents of/etc/network/interfaces
? Also perhaps some details on your networking setup. Are you connected to a router? If so how? and what make/model? – JakeGould – 2015-10-13T15:34:39.947@JakeGould added the output of
ifconfig
. There is no/etc/network/interfaces
file, and I don't know the networking setup, other than I'm running a local VM in virtual box and I'm behind a proxy. – ewok – 2015-10-13T16:08:33.667If you are behind a proxy then that's probably your problem. – qasdfdsaq – 2015-10-15T11:21:38.957