Showing posts with label VirtualBox. Show all posts
Showing posts with label VirtualBox. Show all posts

Thursday, 6 November 2014

Virtualbox: How to mount shared folder

create shared folder on host:
Settings / Shared Folders / Adds a new shared folder definition. /
  Folder Path: C:/shared
  Folder Name: shared
  mark: "Auto-mount" and "Make Permanent"
 

Manually mount shared folder:
mount shared folder on guest os (linux):

# mkir /mnt/shared
# usermod -G vboxsf -a oracle
# mount.vboxsf shared /mnt/shared


Auto-mount shared folder on start-up:
# mkir /mnt/shared
/etc/fstab:
shared   /mnt/shared   vboxsf   defaults  0   0

Virtualbox: copy/paste between host-guest doesn't work (solved)

Solution (doesn't work):

Virtualbox copy/paste between host-guest doesn't work:
Settings-->Storage-->SATA Controller and 2. 'Solid-state drive' is checked

DIDN'T WORK


Solution #2:

Settings / General / Advanced:
   Shared Clipboard: Bidirectional
   Drag'n'Drop: Bidirectional

Saturday, 29 June 2013

Virtualbox: failed to start

Error: failed to open session for the virtual machine ... not match the value ...

Solution: vboxmanage internalcommands sethduuid foo.vdi ########-####-###-####-########

Sunday, 6 January 2013

VirtualBox: how to resize a virtual (dynamic) disk

The existing disk should be dynamic and not fixed.
Resize the existing virtual disk to ~50GB:
$ VBoxManage modifyhd disk_foo.vdi --resize 50000
Use GParted to allocated the free space to the existing partition: download the cd iso version of GParted, create a new virtual machine with virtual cd rom the GParted iso and set its disk the disk_foo.vdi. GParted linux distribution will boot, will recognize the disk disk_foo.vdi. Then from the GParted program allocate the free space to the existing partition.

Tuesday, 10 May 2011

VirtualBox: Resize vdi

Assume the hard disk of the existing vm old_small.vdi is full and we want to resize it.


Create a new vm with the hard disk size you want. Call it new_big (the output is called new_big.vdi).




Then execute the following cmd:
$ VBoxManage clonehd --existing old_small.vdi new_big.vdi

That's it ;)



Sunday, 8 May 2011

VirtualBox: How to create a shared folder between Linux (Ubuntu) host os and Windows 7 or Linux (Ubuntu) guest os

Requirements: install Guest Additions and shutdown the vm

assume name of vm is WindowsVM and you want to share folder home/micharg/SharedVMFolder


on Linux (Ubuntu) Host OS:
$ mkdir /home/micharg/SharedVMFolder
$ VBoxManage sharedfolder add "WindowsVM" --name "SharedVMFolder" --hostpath "/home/micharg/SharedVMFolder"
$ VBoxManage startvm WindowsVM




on Linux (Ubuntu) Guest OS:
$ mkdir /home/vmuser/SharedVMFolder
$ sudo mount -t vboxsf -o uid=aromero SharedVMFolder /home/vmuser/SharedVMFolder


on Windows 7 Guest OS:
Nothing more to do ;) Just go to Network and you will see the shared the new shared folder SharedVMFolder in pc VBOXSRV

Resize a virtual machine (vdi)

Assume we want to resize small.vdi into big.vdi. Then create a new virtual machine (with gui or shell) with name big.vdi with the disk size of our will and execute the following command:

$ VBoxManage clonehd --existing /path/to/small.vdi /path/to/big.vdi

Friday, 29 April 2011

Friday, 22 April 2011

Connect remotely to VM (RDP)



Enable RDP (Remote Desktop Protocol) for the vm you want to connect to:
$ sudo VBoxManage modifyvm vmName --vrde on

Connect to running vm:
$ rdesktop -a 16 192.168.0.100



References
http://www.howtoforge.com/vboxheadless-running-virtual-machines-with-virtualbox-4.0-on-a-headless-opensuse-11.3-server-p2



VirtualBox Virtual Applicances links

Install VirtualBox Guest Additions


$ sudo apt-get install build-essential linux-headers-`uname -r`
$ sudo mount /dev/cdrom1 /mnt
$ sudo bash /mnt/VBoxLinuxAdditions-x86.run



convert vmdk to vdi

$ VBoxManage clonehd vm.vmdk vm.vdi --format VDI

VirtualBox 4.0.10 PUEL installation (Ubuntu 11.04) with extensions


There are two versions of VirtualBox:
  • OSE (Open Source Edition) 
  • PUEL (Personal Use and Evaluation License) 
    • closed-source
    • USB support
    • RDP server (i.e. you can connect to remote virtual machines from any RDP client)
    • USB over RDP (i.e. a remote pc can access the USB devices connected to the pc where VirtualBox is installed)