Issue setting up Oracle Linux 7.9 on newest Vbox

Discussions related to using VirtualBox on Mac OS X hosts.
Post Reply
Magister1838
Posts: 4
Joined: 12. Jun 2021, 06:50

Issue setting up Oracle Linux 7.9 on newest Vbox

Post by Magister1838 »

Hi all,

I am trying to set up Oracle Linux Virtualization Manager VM on my work's Macbook, to follow along with a linux system administration course. The end goal is to have the OLVM manage 3 VMs. I am pulling my hair out, because I cannot figure out why the host and guest cannot talk to eachother.

I was able to successfully set up NAT and have the guest download updates, ping 8.8.8.8, etc. I also set up bridged networking and was able to ping 8.8.8.8 (my standard test), but still unable to ping or see the host. The bridged ip for the guest was 192.168.0.157, the host was 192.168.0.161, so on the same subnet. The guest did not show in the host ARP table (checked with arp -a).

I finally got DHCP working with Host-only adapter and vboxnet0. The guest IP is 192.168.56.3/24. It can ping and download updates but still I cannot ping the guest OS from the host OS.

Initially, the guest was not receiving DHCP. I had to delete the Linux vm and virtualbox, reinstall Vbox and the guest OS.

The reason for needing the guest and host to communicate is, there is an administration portal accessed via web browser. Linux 7.9 is configured with minimal install, so only command line.

There may be something obvious I am missing. I am a beginner with linux, working in data centers so trying to brush up my skills. Any advise will be appreciated.
Magister1838
Posts: 4
Joined: 12. Jun 2021, 06:50

Re: Issue setting up Oracle Linux 7.9 on newest Vbox

Post by Magister1838 »

The main goal right now is to get the host and guest communicating, so I can navigate to the administration portal inside the guest from my host browser
Magister1838
Posts: 4
Joined: 12. Jun 2021, 06:50

Re: Issue setting up Oracle Linux 7.9 on newest Vbox

Post by Magister1838 »

Issue resolved...

After setting up NAT and host-only networks in adapter 1 and adapter 2, passing an IP to NAT (VBoxManage modifyvm "VMNAME" --natnet1 "192.168.100.0/24") and setting the IP in the vm (ip addr add 192.168.100.0/24 dev enp0s3), i was able to connect from the host to the guest.

I needed to update the host's /etc/hosts file to include the FQDN translation of the IP address < -- > FQDN name, as the name could not resolve on its own with out a DNS server
scottgus1
Site Moderator
Posts: 20965
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: Issue setting up Oracle Linux 7.9 on newest Vbox

Post by scottgus1 »

Good on ya for fixing your problem! And thanks for letting us know.

See Virtualbox Networks: In Pictures for the various networks Virtualbox provides.

FWIW Windows OS's often block ping in their built-in firewalls. Perhaps Mac does too? That could be why you could not ping your host OS from the VM. (That NAT, Bridged and Host-Only all failed to ping is a clue to me to check if the host OS firewall was blocking ping.) Also check if the VM OS has a ping-blocking firewall enabled.

NAT will set up a "router" between the host and the guest, causing need for port forwarding to allow the host to talk to the VM. (So you cannot ping a NAT-connected VM from the host, as there's no port to open for ping.)

Being able to ping out of a VM to anything in the real world, like 8.8.8.8, demonstrates that the Virtualbox network is working, and the other communications problems are the result of configuration problems in one or more of the OS's involved (like the host firewall blocking ping).

FWIW the default IP address NAT gives to the VM, 10.0.2.15, would have worked just fine for comms between host and VM, as long as the correct ports were opened in NAT's Port Forwarding button. (I've done comms through default-IP NAT on many occasions, though on a Windows host). Bridged and Host-Only also both worked, getting reasonable IP addresses.

I suspect something else besides Virtualbox was preventing the ping test.
Magister1838
Posts: 4
Joined: 12. Jun 2021, 06:50

Re: Issue setting up Oracle Linux 7.9 on newest Vbox

Post by Magister1838 »

Thank you for the information! I hope this helps someone else with similar problems.

There *was* something in system preferences that virtualbox was trying to access. It was not specified if VBOX was trying to get to the firewall or other settings. I opened security and privacy and there was a notification in the bottom, near the lock icon, saying oracle vbox was trying to access something. I gave it permissions, which probably opened up the firewall rules for vbox.
Post Reply