Virtualbox linux mac guest

How To Install Ubuntu On Virtualbox Mac

Virtualbox is open-source free software that can host Windows, Linux, macOS, and other operating systems in a virtual machine. It is owned by Oracle company. It can be installed and run on macOS, Linux, and Windows. In this article, we will focus on how to install Virtualbox on macOS, and we will create a virtual machine that installs Ubuntu on the Virtualbox mac version. It will also tell you how to resolve some common issues when you install Ubuntu on the Virtualbox mac version like below.

  1. How to enable copy & paste between hosts ( macOS ) and guests (ubuntu virtual machine os).
  2. How can you find and execute ubuntu applications in guest os?
  3. How to fix error “host os (macOS) can not ping guest os (ubuntu virtual machine)”.
  4. How to fix keyboard not working error.

1. Install Virtualbox For Mac.

  1. First of all, you should download the Virtualbox MacOS version.
  2. Then install the Virtualbox macOS version by clicking the downloaded dmg file. Follow the setup wizard to successfully install it.

2. Install Ubuntu On Virtualbox ( Mac Version ) Virtual Machine.

  1. Launch Virtualbox on macOS.
  2. Create a new virtual machine by clicking the New button, then input a virtual machine name in the Name input text box, select the guest OS type ( Linux ) from the Type drop-down list. Then select guest OS version Ubuntu(64 – bit) in the Version drop-down list.
  3. In the next wizard, click the Continue button and adjust the virtual machine’s hard disk size, memory size, and CPU processor number.
  4. After you adjust all the settings, the new ubuntu virtual machine is ready to install.
  5. Before you install Ubuntu Linux OS, you should download the ubuntu iso file to a local folder.
  6. Click to select the virtual machine in the left virtual machine list panel, click the Settings tab button at the top menu bar, then click the Storage tab button at the popup window top menu bar.
  7. Select the laser disk in the left Storage Devices list panel, then click the laser disk icon behind the Optical Drive label on the right side and click Choose Virtual Optical Disk File… menu item to select the ubuntu iso file which you had downloaded in step 5.
  8. Select the virtual machine on the Virtualbox left side and click the right mouse key, then click Start —> Normal Start menu item in the popup menu list to launch ubuntu Linux os install process.
  9. After some text scrolling on the screen, it will pop up the ubuntu installation welcome GUI wizard.
  10. In the first wizard dialog, there are two buttons Try Ubuntu and Install Ubuntu. The Try Ubuntu button will let you use the ubuntu os from the iso file without modifying the virtual machine disk files. The Install Ubuntu button will install ubuntu Linux os on the virtual machine.
  11. Choose the Keyboard layout language which you are preferred in the next wizard dialog, then click the Continue button.
  12. The next wizard dialog will let you choose what software will be installed in ubuntu os. I choose the Normal installation radio button, it will install a web browser, utilities, office software, games and media players, etc.
  13. In the next wizard dialog, if you do not need the data in the virtual machine anymore, and you want the installer to manage disk partitions, you can choose the Erase disk and install Ubuntu radio button, this will use all default settings(partition settings, etc) for this ubuntu os. If you want to manage the virtual machine disk partition by yourself, you can choose the Something else radio button to customize the ubuntu os installation.
  14. The final step is to create a user account that is used to log in to ubuntu. Please remember the username and password carefully.
  15. Now ubuntu Linux os has been installed on Virtualbox virtual machine successfully. Our version is the ubuntu 18.04.1 desktop version. When you start it and log in with your account, you can find it is stable like MacOS and it is easy to use as Windows. In the next article, we will tell you how to configure SSH in the Ubuntu Linux OS and how to login into it remotely.
Читайте также:  Ns error failure 0x80004005 virtualbox astra linux

3. Find And Execute Application In Ubuntu Linux OS.

  1. When you want to run ubuntu applications, you can follow the below steps.
  2. Click the Show Applications button at the bottom left corner of the ubuntu os desktop.
  3. Input application name ( for example Terminal ) in the search box at the top, then the related application will be displayed below it. Click the application icon to start it.

4. Enable Copy & Paste Between Host (Local Machine) And Guest (Virtual Machine) OS.

  1. To enable copy and paste between host and guest OS, you need to follow the below steps.
  2. Start the Virtualbox virtual machine, and click Devices —> Insert Guest Additions CD image… menu item at the top of the VirtualBox VM toolbar.
  3. Then it will mount a disk in the guest Ubuntu virtual machine OS like below, it will prompt you to run it, click the Run button and this will install the guest additions cd image.
"VBox_GAs_S.2.18" contains software intended to be automatically started. Would you like to run it? If you don't trust this location or aren't sure, press Cancel. Cancel Run
Unable to insert the virtual optical disk /Applications/VirtualBox.app/Contents/MacOS/VBoxGuestAdditions.iso into the machine Ubuntu. Could not mount the media/drive '/Applications/VirtualBox.app/Contents/MacOS/VBoxGuestAdditions.iso' (VERR_PDM_MEDIA_LOCKED).

5. Resolve Can Not Ping Virtual Machine OS Issue.

    1. Now the Ubuntu virtual machine has been installed and you have created an admin account for it. You can log in to the system with that account. But when you want to access it from another machine, you should first find the ubuntu virtual machine’s external IP address with the command ifconfig .
    2. Open a terminal in ubuntu, and run ifconfig command in it.
    [email protected]:~$ ifconfig enp0s3: flags=4163 mtu 1500 inet 192.168.0.107 netmask 255.255.255.0 broadcast 192.168.0.255

    change-virtualbox-virtual-machine-network-adapter-type

  1. If you get the error message Command ‘ifconfig’ not found, you can run the command $ sudo apt install net-tools to install it.
  2. The IP address after inet is just the IP v4 IP address of this virtual machine.
  3. But when you ping this IP address from your host os, it will show a request timeout error, this is because your virtual machine is not configured correctly.
  4. Open the virtual machine Settings dialog again, then click Network —> Adapter1. Change the Attached to: drop-down list value from NAT to Bridged Adapter. Then restart the ubuntu os, now you can ping the ubuntu os from host os.
Читайте также:  Узнать характеристики компьютера astra linux

6. How To Fix Keyboard Not Working Error.

  1. Sometimes you may encounter a keyboard does not respond error after pressing the Enter key at the beginning of the installation.
  2. Solution 1: Turn off the virtual machine, then open the VM Settings dialog, click Display —> Screen, adjust Video Memory to a big number such as 128M.
  3. Solution 2: Open the VM Settings dialog, click the System button at the top area, then increase the Base Memory value to a bigger number such as 4GB.
  4. Solution 3: Open the VM Settings dialog, click User Interface —> Input dropdown list, uncheck and check the checkbox before the Keyboard item.
  5. Solution 4: Install VirtualBox extension package that fits your VirtualBox version ( How To Install Virtualbox Extension Pack Correctly ). Check whether USB3 has been enabled in the Virtual Machine, if not then enable it. Exit and power off all VirtualBox instances, then run command VBoxManage setextradata «$Your_Virtual_Machine_Name» VBoxInternal2/EfiGraphicsResolution X in a command-line window. You can refer article How To Fix Mouse And Keyboard Stuck After Install Mac OS On VirtualBox

7. How To Fix MacOS VirtualBox Ubuntu Virtual Machine Stop At UEFI Interactive Shell Issue.

7.1 Question.

  1. I installed the VirtualBox on my MacBookPro, and create a Ubuntu virtual machine on it.
  2. When the virtual machine installation process is finished, it requires me to restart the virtual machine.
  3. I restart the Ubuntu virtual machine as expected and install software on it, but suddenly the virtual machine exited.
  4. When the virtual machine restart, it stops at the UEFI Interactive Shell screen. I can not restart the Ubuntu virtual machine since then.
  5. I open the Ubuntu VM’s Settings window, then click the Storage item, I find the Ubuntu installation iso file has been removed automatically.
  6. Then I select and attach the Ubuntu installation iso file again to the VM. I can install it again, but the error still exists.
Читайте также:  Linux для nexus 5

7.2 Answer1.

  1. I think you had better save the Ubuntu VM’s state after you install it successfully, but not restart the VM.
  2. After that when you run it, the VM starts from the state that you can run it.
  3. I think you can do it when you close the VM window, there is a choice to save the machine state, choose it and it will be ok.

7.3 Answer2.

  1. Open your Ubuntu VM’s Settings dialog, then click the System —> Motherboard tab.
  2. Check whether you have checked the Enable EFI (special OSes only) checkbox, if not checked then you need to check it.
  3. Then restart your Ubuntu virtual machine again.

7.4 Answer3.

  1. I think maybe this issue is because of the Ubuntu VM’s low swap memory not because of the virtual box.
  2. You can check the Ubuntu VM’s swap memory usage with the command htop.
  3. First, install the Ubuntu htop library with the command sudo apt install htop.
  4. Then run the command htop, then you can see the swap memory usage on the screen top area.
  5. If the swap memory has been fully used, then you can run the command below to increase the swap memory size.
# turn off swap. sudo swapoff -a # increase the swap file to 6 GB. sudo dd if=/dev/zero of=/swapfile bs=1G count=6 # change the swap file permission. sudo chmod 0600 /swapfile # create swap with the file. sudo mkswap /swapfile # activate the swap file. sudo swapon /swapfile

Источник

Share folders from the host Mac OS to a guest Linux system in VirtualBox [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.

This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.

1 Answer 1

You’ll need the latest version of VirtualBox (4.3.10) with Guest Additions installed in Ubuntu.

  • With the Virtual Machine powered off and selected in VirtualBox, go to: Machine > Settings . > Shared Folders
  • For “Folder Path”, click the icon to browse for the folder you want to share.
  • For “Folder Name”, enter a name to describe the share.
  • Click “OK” and start the virtual machine again.
  • Create a mount point which is basically an empty folder.
  • Fire up the terminal and type: sudo mount -t vboxsf folder_name path_to_mount_point folder_name is the name you typed in earlier to describe the share
  • You should be able to browse the shared folder now.

In case of difficulties mounting the same, such as the following error:

mount: wrong fs type, bad option, bad superblock on mydata, missing codepage or helper program, or other error (for several filesystems (e.g. nfs, cifs) you might need a /sbin/mount. helper program) In some cases useful info is found in syslog - try dmesg | tail or so 

perform the following steps:

sudo rm /sbin/mount.vboxsf sudo ln -s /opt/VBoxGuestAdditions-4.3.10/lib/VBoxGuestAdditions/mount.vboxsf /sbin/mount.vboxsf 

Источник

Оцените статью
Adblock
detector