2.2.4-Vista[Host]-ubuntu[Guest]-Where is Guest share folder?

Discussions related to using VirtualBox on Windows hosts.
Post Reply
JeZ-l-Lee
Posts: 81
Joined: 22. Jun 2009, 23:46
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows(R) XP Pro SP3 32bit

2.2.4-Vista[Host]-ubuntu[Guest]-Where is Guest share folder?

Post by JeZ-l-Lee »

2.2.4-Vista[Host]-ubuntu[Guest]-Where is Guest share folder?

Hi,

I Googled alot and could not find this information.
I setup the share folder in the Virtual Machine, but I do not know how to setup in ubuntu Guest.
Image
Thanks...

JeZ+Lee
SLNTHERO@aol.com
JeZ-l-Lee
Posts: 81
Joined: 22. Jun 2009, 23:46
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows(R) XP Pro SP3 32bit

Re: 2.2.4-Vista[Host]-ubuntu[Guest]-Where is Guest share folder?

Post by JeZ-l-Lee »

fla wrote:Prerequisites:
I will assume that you have already correctly installed VirtualBox guest additions for Linux and you also have already choosen the folder to share, user maual is giving perfet instructions for that and i cannot do better here.

Open your text editor and write the following text

Code: Select all

#!/bin/bash

case "$1" in
    start)
        /bin/mount -t vboxsf -o uid=username,gid=username winshare /mnt/winshare
        ;;
    stop)
         # No-op
         ;;
     *)
         echo "Usage: vboxshare [start|stop]" >&2
         exit 3
         ;;
esac
substitute username with your actual username and winshare with the name of your shared folder. Save the file as vboxshare and give it execute permissions with

Code: Select all

chmod +x vboxshare
From now on we need to be root so use

Code: Select all

su root
in debian or

Code: Select all

sudo su
in ubuntu, and start paying attention to what we do, it's gonna be dangerous :-).

Create the folder where we are going to mount, so

Code: Select all

mkdir /mnt/winshare
substitute winshare with the name of your shared folder.

Copy the script we did to the /etc/init.d/ directory with

Code: Select all

cp vboxshare /etc/init.d/
Register the script to be started at boot with

Code: Select all

update-rc.d vboxshare defaults
Ok we have finished just reboot and cross your fingers the folder sould be readable and writeble in /mnt/winshare or whatever the name you gave it.

If something goes wrong you can unregister the script we created as root with

Code: Select all

update-rc.d -f  vboxshare remove
Post Reply