For Elementary OS 18.04 guest under MacOS host.
Open terminal inside the VM and type:
$ sudo apt -y update
$ sudo apt -y upgrade
$ sudo apt -y install dkms build-essential
$ sudo reboot
After reboot, open terminal again inside the VM and type:
$ sudo apt install -y virtualbox-guest-additions-iso
$ sudo apt install -y virtualbox-guest-x11
$ sudo adduser $USER vboxusers
$ sudo adduser $USER vboxsf
Shutdown the VM.
- Create a shared folder in Virtualbox on host computer.
- Boot up vm.
- cd
/media/sf_<shared folder name>inside the VM.
Now you should have access to the shared folder.