By sriram on Jul 16, 2009
Here is how I did it
Within your host machine (whether Mac OS X or Windows), you will need to open Virtual Box settings for your guest image and then click on Shared Folders and select to a share a location that you would like to share.
Now, you will need to boot up Open Solaris as guest and will need to install the new guest additions. Here is how you can do so
a) From the top level Virtual Box menu, click on Devices and then click on Install Guest Additions. This will cause Virtual Box to mount Guest additions ISO image.
b) Now, open a command line terminal to install this new guest additions.
- Before proceeding to install the new version of guest additions, let us check if there are any old versions already installed on the system
- sriramn@opensolaris:-~$> pfexec pkginfo -i | grep SUNWvboxguest
- If the above command returned any output, then you will need to remove the previous guest additions like :
- sriramn@opensolaris:-~$> pfexec pkgrm SUNWvboxguest
- Now, you will need to install the latest Virtual Box guest additions package. To do so, you will need to select 'Install Guest Additions..' item from VirtualBox -> Devices menu item.
- sriramn@opensolaris:-~$> pfexec pkgadd -d /media/VBOXADDITIONS\*/VBoxSolarisAdditions.pkg
c) Depending upon your configuration, you might have to reboot your Open Solaris guest.
If you would like to try out Open Solaris on your laptop for the first time, then Virtual Box is a great way to do so. You can get latest builds of OpenSolaris from here and here is a nice screen cast on how to use Virtual Box.
d) Finally, you will need to run the following command within OpenSolaris guest to mount the location that you decided to share from your host (in my case, it is Mac OS's ~/Public ) directory. I was able to do this as shown below
Also, if you would like this particular location to be mounted every time you boot your OpenSolaris guest, you could also add this below line to your /etc/
Now, if you need to copy any file from your OpenSolaris (guest) VM to your host machine , you could simply do something like
sriramn@opensoaris:~$ pfexec cp ~/Documents/foo /Public/Drop\\ Box/
Hope you find this useful.