Owner of Vbox Shared Folder
First I am quite new to Ubuntu and trying to commit myself to it as a PHP developer. Well, I am running on a guest Xubuntu 12.10 system based on Windows7 host.
I shared my web_projects folder and managed to access it by adding my ubuntu user to vboxsf group under /media folder. I symlink a folder inside web_projects as virtual host but it simply says access denied because owner of shared folder is root. What I need to do is changing default owner of vbox shared folder so I can reach them through apache.
I made some digging that ends up with:
yahya@ubuntu:~$ sudo mount -t sf_web_projects -o uid=1000,gid=1000 share /home/yahya/mirror
mount: unknown filesystem type 'sf_web_projects'
Re: Owner of Vbox Shared Folder
I recommend this procedure:
1) Be sure that GuestAdditions are installed in VM.
2) Define a shared folder on the VB menu. For example, I have defined the folder "d:\share" with the name "share". Important: do not tick the Auto-Mount option!!!.
3) Create the mount point in VM:
4) Edit file /etc/rc.local
sudo mkdir /media/share
and add the command mount:
gksudo gedit /etc/rc.local
Save and exit.
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
# In order to enable or disable this script just change the execution
# By default this script does nothing.
mount.vboxsf -w -o uid=1000,gid=1000 share /media/share
Finally reboot the VM and check if the shared folder is automounted properly.
You can define symlinks typing commands similar to this:
ln -s /media/share share