Problem scenario: You are running Linux 7.x in Oracle VirtualBox on a Windows Professional 7 laptop. In the Linux server, you try to ping an IP address. You get "connect: Network is unreachable."
1. In the Oracle VirtualBox window of the server, go to Devices -> Network Settings -> Adapter 1
a) Go to Attached To: and choose "NAT"
b) Check the box for "Cable Connected"
2. On the client, modify this file /etc/sysconfig/network-scripts/ifcfg-enp0s3
a) Add these two lines, with no spaces, above the "ONBOOT" stanza without deleting other lines:
b) Change the "ONBOOT" stanza to be yes, like this (with no spaces):
c) Save the changes.
3. Reboot the client
4. If you are still having problems, you may want to see this posting.