Saturday, January 26, 2013

Saturday, January 12, 2013

Mount host folders in Ubuntu guest OS

Open Virtualbox Shared Folders settings, add folder, make note of the Name.

In Ubuntu guest OS, create folder wherever (only needs to be done once): mkdir ~/Desktop/Host
Check your id by doing: id
Mount the folder using your uid and gid: sudo mount -t vboxsf Name ~/Desktop/Host -o rw,exec,uid=1000,gid=1000,dev
If you want to unmount later, do: umount ~/Desktop/Host

Always run a script in the terminal

Use this code to always run your script in the terminal. Change gnome-terminal to your desired shell. #!/bin/bash
tty -s; if [ $? -ne 0 ]; then gnome-terminal -e "$0"; exit; fi