====== Virtualbox ====== Menu perdu: Ctrl droit (host) + Home Guest additions: * [[https://forums.virtualbox.org/viewtopic.php?t=15679|HOWTO: Install Linux Guest Additions + Xorg config]] Shared folders: * [[https://forums.virtualbox.org/viewtopic.php?t=15868|HOWTO: Use Shared Folders]] on Linux ===== Networking ===== ==== SSH into a VirtualBox Linux guest from your host ==== Accès réseau à une machine virtuelle depuis le réseau hôte: Configurer le réseau de la VM en mode Pont (Bridge) : {{:informatique:informatique:ssh_into_a_virtualbox_linux_guest_from_your_host_-_config_reseau.png?nolink&480|}} ===== VBoxManage ===== [[http://www.virtualbox.org/manual/ch08.html|Chapter 8. VBoxManage]] ==== clonehd ==== This command duplicates a registered virtual hard disk image to a new image file with a new unique identifier (UUID). The new image can be transferred to another host system or imported into VirtualBox again using the Virtual Media Manager. VBoxManage clonehd | [--format VDI|VMDK|VHD|RAW|] [--variant Standard,Fixed,Split2G,Stream,ESX] [--existing] * [[http://www.virtualbox.org/manual/ch08.html#vboxmanage-clonevdi|Chapter 8. VBoxManage - clonehd]] * [[http://www.virtualbox.org/manual/ch05.html#cloningvdis|Chapter 5. Virtual storage - Cloning disk images]] ==== modifyhd ==== With the **–compact** option, can be used to compact disk images, i.e. remove blocks that only contains zeroes. This will shrink a dynamically expanding image again; it will reduce the physical size of the image without affecting the logical size of the virtual disk. Compaction works both for base images and for diff images created as part of a snapshot. For this operation to be effective, it is required that free space in the guest system first be zeroed out using a suitable software tool. For Windows guests, you can use the sdelete tool provided by Microsoft. Execute **sdelete -z** (faster than -c) in the guest to zero the free disk space before compressing the virtual disk image. Please note that compacting is currently only available for VDI images. A similar effect can be achieved by zeroing out free blocks and then cloning the disk to any other dynamically expanding format. You can use this workaround until compacting is also supported for disk formats other than VDI. * [[https://docs.microsoft.com/en-us/sysinternals/downloads/sdelete|SDelete]] chez microsoft.com * [[http://technet.microsoft.com/fr-fr/sysinternals/bb897443.aspx|SDelete v1.51]] * [[http://download.cnet.com/SDelete/3000-2092_4-95740.html|SDelete v1.6]] ==== sethduuid ==== Changer l'UUID d'une image disk: VBoxManage internalcommands sethduuid WARNING: This is a development tool and shall only be used to analyse problems. It is completely unsupported and will change in incompatible ways without warning.