Linux VM on MAC cannot connect to Network NAT

Discussions related to using VirtualBox on Mac OS X hosts.

Linux VM on MAC cannot connect to Network NAT

Postby sath274 » 15. Oct 2021, 07:59

]Hi,

I am trying to setup Oracle Linux 7.8 VM on my Big Sur Mac. I only have a Wifi connection in the host Mac machine.

1. Here is my settings on the VM
mac-linux-vm-network-issue-1.jpg
mac-linux-vm-network-issue-1.jpg (122.34 KiB) Viewed 1653 times


2. Here is the screenshot of the error I see in the VM
[attachment=0]mac-linux-vm-network-issue-2.jpg[/attachment
Attachments
mac-linux-vm-network-issue-2.jpg
mac-linux-vm-network-issue-2.jpg (102.84 KiB) Viewed 1653 times
sath274
 
Posts: 3
Joined: 15. Oct 2021, 07:28

Re: Linux VM on MAC cannot connect to Network NAT

Postby scottgus1 » 15. Oct 2021, 18:49

Please check under the Advanced dropdown to see if the "cable" is connected.

Otherwise, please Start the VM from full power off, not save-state. Run until you see the problem happen, then shut down the VM from within the VM OS if possible. If not possible, close the Virtualbox window for the VM with the Power Off option set.

Please right-click the VM in the main Virtualbox window's VM list, choose Show Log. Save the far left tab's log, zip the log file, and post the zip file, using the forum's Upload Attachment tab.

Also, please right-click the VM in the main Virtualbox window's VM list, choose "Show in Explorer/Finder/File Manager". In the window that opens, zip the VM's .vbox file (not the .vbox-prev file), and post the zip file, using the forum's Upload Attachment tab. (Please make sure all file extensions are shown, so you will be able to see the .vbox extension easier.)

Finally, in both host and VM, provide the output of "ip address" in each OS's terminal.
scottgus1
Site Moderator
 
Posts: 13756
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: Linux VM on MAC cannot connect to Network NAT

Postby sath274 » 15. Oct 2021, 21:43

HI @scottgus1,

1. Yes cable is connected option is enabled.

2. logs attached.
oralin78-2021-10-16-01-01-00.log.zip
(29.86 KiB) Downloaded 6 times


3. zip of .vbox attached
oralin78.vbox.zip
(1.54 KiB) Downloaded 5 times


4.ip address output attached
in the guest, only lo, enp0s3 and enp0s8 are listed.

host-ifconfig.txt
(3.5 KiB) Downloaded 4 times
sath274
 
Posts: 3
Joined: 15. Oct 2021, 07:28

Re: Linux VM on MAC cannot connect to Network NAT

Postby scottgus1 » 15. Oct 2021, 23:48

sath274 wrote:in the guest, only lo, enp0s3 and enp0s8 are listed.

Do you have an 'ip address' or 'ifconfig' from inside the guest?
scottgus1
Site Moderator
 
Posts: 13756
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: Linux VM on MAC cannot connect to Network NAT

Postby sath274 » 16. Oct 2021, 06:05

Here is the screenshot of IP address from the guest.
Attachments
if-address-guest.jpg
if-address-guest.jpg (107.09 KiB) Viewed 1550 times
sath274
 
Posts: 3
Joined: 15. Oct 2021, 07:28

Re: Linux VM on MAC cannot connect to Network NAT

Postby scottgus1 » 18. Oct 2021, 17:36

OK, thanks for the info.

The "ip address" from the VM shows both enp0s8 and enp0s3 not receiving IP addresses.

The VM's .vbox file shows this for network setup:
<Network>
<Adapter slot="0" enabled="true" MACAddress="080027CFA2FA">
<DisabledModes>
<InternalNetwork name="intnet"/>
<HostOnlyInterface name="vboxnet0"/>
</DisabledModes>
<NATNetwork name="NatNetwork"/>
</Adapter>
<Adapter slot="1" enabled="true" MACAddress="0800272503AB" type="82540EM">
<DisabledModes>
<InternalNetwork name="intnet"/>
<NATNetwork name="NatNetwork"/>
</DisabledModes>
<BridgedInterface name="en0: Wi-Fi (Wireless)"/>
</Adapter>
</Network>


Please note there is a "DisabledModes" XML block for each adapter showing what has been used before and are not being used now, and a line following "</DisabledModes>" which shows what the VM's adapter is now set to.

Curious, that despite the first picture above, none of the VMs have been set to NAT. One is now set to NAT Network, which can be broken if settings have been made at the wrong time, and the other is Bridged to a Wi-Fi adapter (Bridged doesn't always work with Wi-Fi adapters.)

Additionally, we don't know what has been done to the VM OS's settings regarding network adapters.

Let's check Virtualbox on your host and basic network using a new VM with a plain vanilla unchanged Ubuntu OS.

Please download Ubuntu's latest GUI desktop ISO. Make a new VM for it without changing any of the VM's settings: just let Virtualbox set up the VM the way it wants to. Then install the Ubuntu ISO's OS, and see if it can get internet in the Ubuntu web browser.
scottgus1
Site Moderator
 
Posts: 13756
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux


Return to VirtualBox on Mac OS X Hosts

Who is online

Users browsing this forum: No registered users and 23 guests