VBoxManageHelp.cpp revision 98fbc4732a9519502e92799ef769789cbdd97dce
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync/* $Id$ */
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync/** @file
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync * VBoxManage - help and other message output.
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync */
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync/*
e64031e20c39650a7bc902a3e1aba613b9415deevboxsync * Copyright (C) 2006-2010 Oracle Corporation
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync *
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync * available from http://www.virtualbox.org. This file is free software;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync * you can redistribute it and/or modify it under the terms of the GNU
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync * General Public License (GPL) as published by the Free Software
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync */
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync/*******************************************************************************
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync* Header Files *
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync*******************************************************************************/
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync#include <VBox/version.h>
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync#include <iprt/buildconfig.h>
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync#include <iprt/ctype.h>
e0778e583cb4a0bdc9bcc48f5957e00a01108388vboxsync#include <iprt/err.h>
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#include <iprt/getopt.h>
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync#include <iprt/stream.h>
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#include "VBoxManage.h"
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsyncvoid showLogo(PRTSTREAM pStrm)
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync{
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync static bool s_fShown; /* show only once */
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync if (!s_fShown)
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync {
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, VBOX_PRODUCT " Command Line Management Interface Version "
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync VBOX_VERSION_STRING "\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "(C) 2005-" VBOX_C_YEAR " " VBOX_VENDOR "\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "All rights reserved.\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync s_fShown = true;
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync }
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync}
b0ad0bbadf3a5b5258acda1bfe16f0ad8bee5ff0vboxsync
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsyncvoid printUsage(USAGECATEGORY u64Cmd, PRTSTREAM pStrm)
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync{
229a63857c5fd2e441a62206eacce4156d0b2a26vboxsync bool fDumpOpts = false;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#ifdef RT_OS_LINUX
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync bool fLinux = true;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#else
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync bool fLinux = false;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#endif
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#ifdef RT_OS_WINDOWS
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync bool fWin = true;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#else
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync bool fWin = false;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#endif
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#ifdef RT_OS_SOLARIS
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync bool fSolaris = true;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#else
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync bool fSolaris = false;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#endif
a0644dbbd30adb9bd2937110d6f016e56c4cc52bvboxsync#ifdef RT_OS_FREEBSD
a0644dbbd30adb9bd2937110d6f016e56c4cc52bvboxsync bool fFreeBSD = true;
a0644dbbd30adb9bd2937110d6f016e56c4cc52bvboxsync#else
a0644dbbd30adb9bd2937110d6f016e56c4cc52bvboxsync bool fFreeBSD = false;
a0644dbbd30adb9bd2937110d6f016e56c4cc52bvboxsync#endif
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#ifdef RT_OS_DARWIN
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync bool fDarwin = true;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#else
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync bool fDarwin = false;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#endif
a2d9f81753c129b5e3bbe3769627dcd25a3724bdvboxsync#ifdef VBOX_WITH_VBOXSDL
a2d9f81753c129b5e3bbe3769627dcd25a3724bdvboxsync bool fVBoxSDL = true;
a2d9f81753c129b5e3bbe3769627dcd25a3724bdvboxsync#else
a2d9f81753c129b5e3bbe3769627dcd25a3724bdvboxsync bool fVBoxSDL = false;
a2d9f81753c129b5e3bbe3769627dcd25a3724bdvboxsync#endif
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd == USAGE_DUMPOPTS)
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync {
229a63857c5fd2e441a62206eacce4156d0b2a26vboxsync fDumpOpts = true;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync fLinux = true;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync fWin = true;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync fSolaris = true;
a0644dbbd30adb9bd2937110d6f016e56c4cc52bvboxsync fFreeBSD = true;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync fDarwin = true;
a2d9f81753c129b5e3bbe3769627dcd25a3724bdvboxsync fVBoxSDL = true;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync u64Cmd = USAGE_ALL;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync }
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "Usage:\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd == USAGE_ALL)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage [-v|--version] print version number and exit\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage [-q|--nologo] ... suppress the logo\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_LIST)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage list [--long|-l] vms|runningvms|ostypes|hostdvds|hostfloppies|\n"
7bf07b1592dfaab1a4fb6d497fd0ff1302fb7585vboxsync#if defined(VBOX_WITH_NETFLT)
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " bridgedifs|hostonlyifs|dhcpservers|hostinfo|\n"
7c1f498692cd2393f8ba68cb62be482495106f93vboxsync#else
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " bridgedifs|dhcpservers|hostinfo|\n"
7c1f498692cd2393f8ba68cb62be482495106f93vboxsync#endif
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " hostcpuids|hddbackends|hdds|dvds|floppies|\n"
4c8907a420ed66a42f729eb08cddf9c1e57f25eavboxsync " usbhost|usbfilters|systemproperties|extpacks\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_SHOWVMINFO)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage showvminfo <uuid>|<name> [--details] [--statistics]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--machinereadable]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage showvminfo <uuid>|<name> --log <idx>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_REGISTERVM)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage registervm <filename>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_UNREGISTERVM)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage unregistervm <uuid>|<name> [--delete]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_CREATEVM)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage createvm --name <name>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--ostype <ostype>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--register]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--basefolder <path> | --settingsfile <path>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--uuid <uuid>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_MODIFYVM)
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync {
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage modifyvm <uuid|name>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--name <name>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--ostype <ostype>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--memory <memorysize in MB>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--pagefusion on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--vram <vramsize in MB>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--acpi on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--ioapic on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--pae on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--hpet on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--hwvirtex on|off]\n"
85bc82f92f4d7a7b95e96d133c4847b2847703dfvboxsync " [--hwvirtexexcl on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--nestedpaging on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--largepages on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--vtxvpid on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--synthcpu on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--cpuidset <leaf> <eax> <ebx> <ecx> <edx>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--cpuidremove <leaf>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--cpuidremoveall]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--hardwareuuid <uuid>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--cpus <number>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--cpuhotplug on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--plugcpu <id>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--unplugcpu <id>]\n"
657b2c9f6d33f08001e5fa6f6e0572dcf0391013vboxsync " [--cpuexecutioncap <1-100>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--rtcuseutc on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--monitorcount <number>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--accelerate3d on|off]\n"
49e54e2ffe0c10864d06e9d1ebe24a8eb1327a6bvboxsync#ifdef VBOX_WITH_VIDEOHWACCEL
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--accelerate2dvideo on|off]\n"
49e54e2ffe0c10864d06e9d1ebe24a8eb1327a6bvboxsync#endif
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--firmware bios|efi|efi32|efi64]\n"
7a29aa5ce149ccd344a2929d2815b8e212690b92vboxsync " [--chipset ich9|piix3]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--bioslogofadein on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--bioslogofadeout on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--bioslogodisplaytime <msec>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--bioslogoimagepath <imagepath>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--biosbootmenu disabled|menuonly|messageandmenu]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--biossystemtimeoffset <msec>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--biospxedebug on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--boot<1-4> none|floppy|dvd|disk|net>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--nic<1-N> none|null|nat|bridged|intnet"
229a63857c5fd2e441a62206eacce4156d0b2a26vboxsync#if defined(VBOX_WITH_NETFLT)
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "|hostonly"
8c58249d7f93d82395aa6c8b31526443892bc375vboxsync#endif
8c58249d7f93d82395aa6c8b31526443892bc375vboxsync#ifdef VBOX_WITH_VDE
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "|\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " vde"
8c58249d7f93d82395aa6c8b31526443892bc375vboxsync#endif
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--nictype<1-N> Am79C970A|Am79C973"
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#ifdef VBOX_WITH_E1000
5453eb2f2719bf3895ac3daeec4c26e0b6e2eb4avboxsync "|\n 82540EM|82543GC|82545EM"
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#endif
9bb98d54790a98dad0ad6d9bdc5d319b6fdf0bffvboxsync#ifdef VBOX_WITH_VIRTIO
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "|\n virtio"
9bb98d54790a98dad0ad6d9bdc5d319b6fdf0bffvboxsync#endif /* VBOX_WITH_VIRTIO */
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--cableconnected<1-N> on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--nictrace<1-N> on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--nictracefile<1-N> <filename>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--nicspeed<1-N> <kbps>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--nicbootprio<1-N> <priority>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--bridgeadapter<1-N> none|<devicename>]\n"
629e8f58c569e4c51a98284c41754fd9f0b973f8vboxsync#if defined(VBOX_WITH_NETFLT)
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--hostonlyadapter<1-N> none|<devicename>]\n"
7c1f498692cd2393f8ba68cb62be482495106f93vboxsync#endif
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--intnet<1-N> <network name>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--natnet<1-N> <network>|default]\n"
8c58249d7f93d82395aa6c8b31526443892bc375vboxsync#ifdef VBOX_WITH_VDE
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--vdenet<1-N> <network>|default]\n"
8c58249d7f93d82395aa6c8b31526443892bc375vboxsync#endif
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--natsettings<1-N> [<mtu>],[<socksnd>],\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [<sockrcv>],[<tcpsnd>],\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [<tcprcv>]]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--natpf<1-N> [<rulename>],tcp|udp,[<hostip>],\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " <hostport>,[<guestip>],<guestport>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--natpf<1-N> delete <rulename>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--nattftpprefix<1-N> <prefix>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--nattftpfile<1-N> <file>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--nattftpserver<1-N> <ip>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--natdnspassdomain<1-N> on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--natdnsproxy<1-N> on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--natdnshostresolver<1-N> on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--nataliasmode<1-N> default|[log],[proxyonly],\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [sameports]]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--macaddress<1-N> auto|<mac>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--mouse ps2|usb|usbtablet\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--keyboard ps2|usb\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--uart<1-N> off|<I/O base> <IRQ>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--uartmode<1-N> disconnected|\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " server <pipe>|\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " client <pipe>|\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " file <file>|\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " <devicename>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--guestmemoryballoon <balloonsize in MB>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--gueststatisticsinterval <seconds>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--audio none|null");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (fWin)
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync {
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#ifdef VBOX_WITH_WINMM
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, "|winmm|dsound");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#else
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, "|dsound");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#endif
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync }
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (fSolaris)
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync {
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, "|solaudio"
5704a317c3b6bdf4b59f6a6ebe45d443296b1995vboxsync#ifdef VBOX_WITH_SOLARIS_OSS
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "|oss"
5704a317c3b6bdf4b59f6a6ebe45d443296b1995vboxsync#endif
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync );
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync }
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (fLinux)
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync {
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, "|oss"
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#ifdef VBOX_WITH_ALSA
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "|alsa"
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#endif
a0644dbbd30adb9bd2937110d6f016e56c4cc52bvboxsync#ifdef VBOX_WITH_PULSE
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "|pulse"
a0644dbbd30adb9bd2937110d6f016e56c4cc52bvboxsync#endif
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync );
a0644dbbd30adb9bd2937110d6f016e56c4cc52bvboxsync }
a0644dbbd30adb9bd2937110d6f016e56c4cc52bvboxsync if (fFreeBSD)
a0644dbbd30adb9bd2937110d6f016e56c4cc52bvboxsync {
229a63857c5fd2e441a62206eacce4156d0b2a26vboxsync /* Get the line break sorted when dumping all option variants. */
229a63857c5fd2e441a62206eacce4156d0b2a26vboxsync if (fDumpOpts)
229a63857c5fd2e441a62206eacce4156d0b2a26vboxsync {
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, "|\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " oss");
229a63857c5fd2e441a62206eacce4156d0b2a26vboxsync }
229a63857c5fd2e441a62206eacce4156d0b2a26vboxsync else
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, "|oss");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#ifdef VBOX_WITH_PULSE
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, "|pulse");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#endif
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync }
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (fDarwin)
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync {
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, "|coreaudio");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync }
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, "]\n");
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--audiocontroller ac97|hda|sb16]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--clipboard disabled|hosttoguest|guesttohost|\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " bidirectional]\n");
cc74f15083bf80fbc96723a89faa06c15d0dead8vboxsync RTStrmPrintf(pStrm,
3933885bc0c2c93436d858a14564c6179ec72872vboxsync " [--vrde on|off]\n"
9ca017ceee656f9d33f2cb6652e401b5f17fcfb7vboxsync " [--vrdeextpack default|<name>\n"
cc74f15083bf80fbc96723a89faa06c15d0dead8vboxsync " [--vrdeproperty <name=[value]>]\n"
36a04912b64bea8318327fe0723535f1b3f041b0vboxsync " [--vrdeport <hostport>]\n"
36a04912b64bea8318327fe0723535f1b3f041b0vboxsync " [--vrdeaddress <hostip>]\n"
3933885bc0c2c93436d858a14564c6179ec72872vboxsync " [--vrdeauthtype null|external|guest]\n"
6e25221ce8ef8e656d1e15eb7ec5cf8ae758ceb2vboxsync " [--vrdeauthlibrary default|<name>\n"
3933885bc0c2c93436d858a14564c6179ec72872vboxsync " [--vrdemulticon on|off]\n"
3933885bc0c2c93436d858a14564c6179ec72872vboxsync " [--vrdereusecon on|off]\n"
3933885bc0c2c93436d858a14564c6179ec72872vboxsync " [--vrdevideochannel on|off]\n"
3933885bc0c2c93436d858a14564c6179ec72872vboxsync " [--vrdevideochannelquality <percent>]\n");
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--usb on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--usbehci on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--snapshotfolder default|<path>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--teleporter on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--teleporterport <port>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--teleporteraddress <address|empty>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--teleporterpassword <password>]\n"
80b09746c07120c881b61b18f30c9c4a2a4af9c5vboxsync#if 0
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--iocache on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--iocachesize <I/O cache size in MB>]\n"
80b09746c07120c881b61b18f30c9c4a2a4af9c5vboxsync#endif
d7c2269005543188a6fb12775f6d416431e39ebcvboxsync#if 0
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--faulttolerance master|standby]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--faulttoleranceaddress <name>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--faulttoleranceport <port>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--faulttolerancesyncinterval <msec>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--faulttolerancepassword <password>]\n"
d7c2269005543188a6fb12775f6d416431e39ebcvboxsync#endif
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync }
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
b8c2e8ba48bd659fa09a06770a7cedfae977d73bvboxsync if (u64Cmd & USAGE_IMPORTAPPLIANCE)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
2355157d3ea6596738c7c74e803220ad1bd6b4a8vboxsync "VBoxManage import <ovf/ova> [--dry-run|-n] [more options]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " (run with -n to have options displayed\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " for a particular OVF)\n\n");
b8c2e8ba48bd659fa09a06770a7cedfae977d73bvboxsync
b8c2e8ba48bd659fa09a06770a7cedfae977d73bvboxsync if (u64Cmd & USAGE_EXPORTAPPLIANCE)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
2355157d3ea6596738c7c74e803220ad1bd6b4a8vboxsync "VBoxManage export <machines> --output|-o <ovf/ova>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--legacy09]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--manifest]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--vsys <number of virtual system>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--product <product name>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--producturl <product url>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--vendor <vendor name>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--vendorurl <vendor url>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--version <version info>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--eula <license text>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--eulafile <filename>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
b8c2e8ba48bd659fa09a06770a7cedfae977d73bvboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_STARTVM)
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync {
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage startvm <uuid>|<name>\n");
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--type gui");
a2d9f81753c129b5e3bbe3769627dcd25a3724bdvboxsync if (fVBoxSDL)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, "|sdl");
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm, "|headless]\n");
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync }
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_CONTROLVM)
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync {
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage controlvm <uuid>|<name>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " pause|resume|reset|poweroff|savestate|\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " acpipowerbutton|acpisleepbutton|\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " keyboardputscancode <hex> [<hex> ...]|\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " setlinkstate<1-N> on|off |\n"
a1a2e3f1c3ca7d6190c90ff67b7995b50b258794vboxsync#if defined(VBOX_WITH_NETFLT)
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " nic<1-N> null|nat|bridged|intnet|hostonly\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [<devicename>] |\n"
a1a2e3f1c3ca7d6190c90ff67b7995b50b258794vboxsync#else /* !RT_OS_LINUX && !RT_OS_DARWIN */
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " nic<1-N> null|nat|bridged|intnet\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [<devicename>] |\n"
a1a2e3f1c3ca7d6190c90ff67b7995b50b258794vboxsync#endif /* !RT_OS_LINUX && !RT_OS_DARWIN */
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " nictrace<1-N> on|off\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " nictracefile<1-N> <filename>\n"
b4bcdbd7ac35c938e6f71a6403fe9f3ebf106a07vboxsync " natpf<1-N> [<rulename>],tcp|udp,[<hostip>],\n"
b4bcdbd7ac35c938e6f71a6403fe9f3ebf106a07vboxsync " <hostport>,[<guestip>],<guestport>\n"
b4bcdbd7ac35c938e6f71a6403fe9f3ebf106a07vboxsync " natpf<1-N> delete <rulename>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " guestmemoryballoon <balloonsize in MB>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " gueststatisticsinterval <seconds>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " usbattach <uuid>|<address> |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " usbdetach <uuid>|<address> |\n");
cc74f15083bf80fbc96723a89faa06c15d0dead8vboxsync RTStrmPrintf(pStrm,
3933885bc0c2c93436d858a14564c6179ec72872vboxsync " vrde on|off |\n");
cc74f15083bf80fbc96723a89faa06c15d0dead8vboxsync RTStrmPrintf(pStrm,
36a04912b64bea8318327fe0723535f1b3f041b0vboxsync " vrdeport <port> |\n"
cc74f15083bf80fbc96723a89faa06c15d0dead8vboxsync " vrdeproperty <name=[value]> |\n"
3933885bc0c2c93436d858a14564c6179ec72872vboxsync " vrdevideochannelquality <percent>\n");
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " setvideomodehint <xres> <yres> <bpp> [display] |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " setcredentials <username> <password> <domain>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--allowlocallogon <yes|no>] |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " teleport --host <name> --port <port>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--maxdowntime <msec>] [--password password]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " plugcpu <id>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " unplugcpu <id>\n"
657b2c9f6d33f08001e5fa6f6e0572dcf0391013vboxsync " cpuexecutioncap <1-100>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync }
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_DISCARDSTATE)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage discardstate <uuid>|<name>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_ADOPTSTATE)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage adoptstate <uuid>|<name> <state_file>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_SNAPSHOT)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage snapshot <uuid>|<name>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " take <name> [--description <desc>] [--pause] |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " delete <uuid>|<name> |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " restore <uuid>|<name> |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " restorecurrent |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " edit <uuid>|<name>|--current\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--name <name>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--description <desc>] |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " showvminfo <uuid>|<name>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
ac2b2ae448fe887af9a3269e40afff11ebb1f9d3vboxsync if (u64Cmd & USAGE_CLOSEMEDIUM)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage closemedium disk|dvd|floppy <uuid>|<filename>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--delete]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
a425b5e790c27d6a1a2cf738802e9034f0764a00vboxsync if (u64Cmd & USAGE_STORAGEATTACH)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage storageattach <uuid|vmname>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --storagectl <name>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --port <number>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --device <number>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--type dvddrive|hdd|fdd]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--medium none|emptydrive|\n"
aeb9498c4d9854ed42b271541d34c7bad97b4c77vboxsync " <uuid>|<filename>|host:<drive>|iscsi]\n"
aed4b2dfb1673c0b476588860c9d27705700ce0dvboxsync " [--mtype normal|writethrough|immutable|shareable|\n"
dc9555b48e3a0576258aa498825c8d10e311cd47vboxsync " readonly|multiattach]\n"
cf289c84a0ecd24e5808b46b70d545cdc2c8805cvboxsync " [--comment <text>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--passthrough on|off]\n"
63b785c3291332a86a9bc473e68f08121368898bvboxsync " [--bandwidthgroup <name>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--forceunmount]\n"
aeb9498c4d9854ed42b271541d34c7bad97b4c77vboxsync " [--server <name>|<ip>]\n"
aeb9498c4d9854ed42b271541d34c7bad97b4c77vboxsync " [--target <target>]\n"
aeb9498c4d9854ed42b271541d34c7bad97b4c77vboxsync " [--port <port>]\n"
aeb9498c4d9854ed42b271541d34c7bad97b4c77vboxsync " [--lun <lun>]\n"
aeb9498c4d9854ed42b271541d34c7bad97b4c77vboxsync " [--encodedlun <lun>]\n"
aeb9498c4d9854ed42b271541d34c7bad97b4c77vboxsync " [--username <username>]\n"
aeb9498c4d9854ed42b271541d34c7bad97b4c77vboxsync " [--password <password>]\n"
aeb9498c4d9854ed42b271541d34c7bad97b4c77vboxsync " [--intnet]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
bddad5eeab93a98d4ea571ccdf016531bb4318advboxsync
bddad5eeab93a98d4ea571ccdf016531bb4318advboxsync if (u64Cmd & USAGE_STORAGECONTROLLER)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage storagectl <uuid|vmname>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --name <name>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--add ide|sata|scsi|floppy|sas]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--controller LSILogic|LSILogicSAS|BusLogic|\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " IntelAHCI|PIIX3|PIIX4|ICH6|I82078]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--sataideemulation<1-4> <1-30>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--sataportcount <1-30>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--hostiocache on|off]\n"
bf88068260ded16af90b7da4867240fbdd9c8017vboxsync " [--bootable on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--remove]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
bddad5eeab93a98d4ea571ccdf016531bb4318advboxsync
63b785c3291332a86a9bc473e68f08121368898bvboxsync if (u64Cmd & USAGE_BANDWIDTHCONTROL)
63b785c3291332a86a9bc473e68f08121368898bvboxsync RTStrmPrintf(pStrm,
63b785c3291332a86a9bc473e68f08121368898bvboxsync "VBoxManage bandwidthctl <uuid|vmname>\n"
63b785c3291332a86a9bc473e68f08121368898bvboxsync " --name <name>\n"
63b785c3291332a86a9bc473e68f08121368898bvboxsync " [--add disk|network]\n"
63b785c3291332a86a9bc473e68f08121368898bvboxsync " [--limit <megabytes per second>\n"
63b785c3291332a86a9bc473e68f08121368898bvboxsync " [--delete]\n"
63b785c3291332a86a9bc473e68f08121368898bvboxsync "\n");
63b785c3291332a86a9bc473e68f08121368898bvboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_SHOWHDINFO)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage showhdinfo <uuid>|<filename>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_CREATEHD)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage createhd --filename <filename>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --size <megabytes>|--sizebyte <bytes>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--format VDI|VMDK|VHD] (default: VDI)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--variant Standard,Fixed,Split2G,Stream,ESX]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_MODIFYHD)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage modifyhd <uuid>|<filename>\n"
aed4b2dfb1673c0b476588860c9d27705700ce0dvboxsync " [--type normal|writethrough|immutable|shareable|\n"
dc9555b48e3a0576258aa498825c8d10e311cd47vboxsync " readonly|multiattach]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--autoreset on|off]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--compact]\n"
5434d84d270a73565d8c3bed826cb4f95aba317bvboxsync " [--resize <megabytes>|--resizebyte <bytes>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_CLONEHD)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage clonehd <uuid>|<filename> <outputfile>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--format VDI|VMDK|VHD|RAW|<other>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--variant Standard,Fixed,Split2G,Stream,ESX]\n"
5b298681ed3a24f71adcf7b557d3b0f850967bbfvboxsync " [--existing]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_CONVERTFROMRAW)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage convertfromraw <filename> <outputfile>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--format VDI|VMDK|VHD]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--variant Standard,Fixed,Split2G,Stream,ESX]\n"
1a3c29d55b3cf1f6d60f53b8e3c33161ca97cd95vboxsync#ifndef RT_OS_WINDOWS
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage convertfromraw stdin <outputfile> <bytes>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--format VDI|VMDK|VHD]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--variant Standard,Fixed,Split2G,Stream,ESX]\n"
1a3c29d55b3cf1f6d60f53b8e3c33161ca97cd95vboxsync#endif
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_GETEXTRADATA)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage getextradata global|<uuid>|<name>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " <key>|enumerate\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_SETEXTRADATA)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage setextradata global|<uuid>|<name>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " <key>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [<value>] (no value deletes key)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_SETPROPERTY)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
95a6be61815bc19c98d76c390b164600364b3e3dvboxsync "VBoxManage setproperty machinefolder default|<folder> |\n"
3933885bc0c2c93436d858a14564c6179ec72872vboxsync " vrdeauthlibrary default|<library> |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " websrvauthlibrary default|null|<library> |\n"
9ca017ceee656f9d33f2cb6652e401b5f17fcfb7vboxsync " vrdeextpack null|<library> |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " loghistorycount <value>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_USBFILTER_ADD)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage usbfilter add <index,0-N>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --target <uuid>|<name>|global\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --name <string>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --action ignore|hold (global filters only)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--active yes|no] (yes)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--vendorid <XXXX>] (null)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--productid <XXXX>] (null)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--revision <IIFF>] (null)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--manufacturer <string>] (null)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--product <string>] (null)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--remote yes|no] (null, VM filters only)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--serialnumber <string>] (null)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--maskedinterfaces <XXXXXXXX>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_USBFILTER_MODIFY)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage usbfilter modify <index,0-N>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --target <uuid>|<name>|global\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--name <string>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--action ignore|hold] (global filters only)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--active yes|no]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--vendorid <XXXX>|\"\"]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--productid <XXXX>|\"\"]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--revision <IIFF>|\"\"]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--manufacturer <string>|\"\"]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--product <string>|\"\"]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--remote yes|no] (null, VM filters only)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--serialnumber <string>|\"\"]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--maskedinterfaces <XXXXXXXX>]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_USBFILTER_REMOVE)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage usbfilter remove <index,0-N>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --target <uuid>|<name>|global\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_SHAREDFOLDER_ADD)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage sharedfolder add <vmname>|<uuid>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --name <name> --hostpath <hostpath>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--transient] [--readonly] [--automount]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_SHAREDFOLDER_REMOVE)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage sharedfolder remove <vmname>|<uuid>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --name <name> [--transient]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#ifdef VBOX_WITH_GUEST_PROPS
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_GUESTPROPERTY)
7e8c58de93a6432f55ba0f4550c02a47b4302effvboxsync usageGuestProperty(pStrm);
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#endif /* VBOX_WITH_GUEST_PROPS defined */
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
d450629f624308cb06e59a13554c697afea563d8vboxsync#ifdef VBOX_WITH_GUEST_CONTROL
d450629f624308cb06e59a13554c697afea563d8vboxsync if (u64Cmd & USAGE_GUESTCONTROL)
7e8c58de93a6432f55ba0f4550c02a47b4302effvboxsync usageGuestControl(pStrm);
d450629f624308cb06e59a13554c697afea563d8vboxsync#endif /* VBOX_WITH_GUEST_CONTROL defined */
d450629f624308cb06e59a13554c697afea563d8vboxsync
500b54ffef573903725ee90aa3db3485fc6a5840vboxsync if (u64Cmd & USAGE_DEBUGVM)
500b54ffef573903725ee90aa3db3485fc6a5840vboxsync {
500b54ffef573903725ee90aa3db3485fc6a5840vboxsync RTStrmPrintf(pStrm,
500b54ffef573903725ee90aa3db3485fc6a5840vboxsync "VBoxManage debugvm <uuid>|<name>\n"
5f32a23884cca588e95be86778770d60cbc529f7vboxsync " dumpguestcore --filename <name> |\n"
c6960665b76a45ed0489be4f3b4685a3170c3f8dvboxsync " info <item> [args] |\n"
500b54ffef573903725ee90aa3db3485fc6a5840vboxsync " injectnmi |\n"
c6960665b76a45ed0489be4f3b4685a3170c3f8dvboxsync " osdetect |\n"
c6960665b76a45ed0489be4f3b4685a3170c3f8dvboxsync " osinfo |\n"
4c8907a420ed66a42f729eb08cddf9c1e57f25eavboxsync " statistics [--reset] [--pattern <pattern>]\n"
4c8907a420ed66a42f729eb08cddf9c1e57f25eavboxsync " [--descriptions]\n"
500b54ffef573903725ee90aa3db3485fc6a5840vboxsync "\n");
500b54ffef573903725ee90aa3db3485fc6a5840vboxsync }
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (u64Cmd & USAGE_METRICS)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage metrics list [*|host|<vmname> [<metric_list>]]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " (comma-separated)\n\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage metrics setup\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--period <seconds>] (default: 1)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--samples <count>] (default: 1)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--list]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [*|host|<vmname> [<metric_list>]]\n\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage metrics query [*|host|<vmname> [<metric_list>]]\n\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage metrics enable\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--list]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [*|host|<vmname> [<metric_list>]]\n\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage metrics disable\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--list]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [*|host|<vmname> [<metric_list>]]\n\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage metrics collect\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--period <seconds>] (default: 1)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--samples <count>] (default: 1)\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--list]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--detach]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [*|host|<vmname> [<metric_list>]]\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
aeb9498c4d9854ed42b271541d34c7bad97b4c77vboxsync
7bf07b1592dfaab1a4fb6d497fd0ff1302fb7585vboxsync#if defined(VBOX_WITH_NETFLT)
ec9dc23c50665e8603e1be5a9b6b6fd4c4d949d4vboxsync if (u64Cmd & USAGE_HOSTONLYIFS)
ec9dc23c50665e8603e1be5a9b6b6fd4c4d949d4vboxsync {
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage hostonlyif ipconfig <name>\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " [--dhcp |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --ip<ipv4> [--netmask<ipv4> (def: 255.255.255.0)] |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --ipv6<ipv6> [--netmasklengthv6<length> (def: 64)]]\n"
98fbc4732a9519502e92799ef769789cbdd97dcevboxsync# if !defined(RT_OS_SOLARIS)
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " create |\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " remove <name>\n"
ec9dc23c50665e8603e1be5a9b6b6fd4c4d949d4vboxsync# endif
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
ec9dc23c50665e8603e1be5a9b6b6fd4c4d949d4vboxsync }
ec9dc23c50665e8603e1be5a9b6b6fd4c4d949d4vboxsync#endif
d1fcf24d24368926be13484524a9e378070a9157vboxsync
d1fcf24d24368926be13484524a9e378070a9157vboxsync if (u64Cmd & USAGE_DHCPSERVER)
d1fcf24d24368926be13484524a9e378070a9157vboxsync {
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync RTStrmPrintf(pStrm,
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage dhcpserver add|modify --netname <network_name> |\n"
7bf07b1592dfaab1a4fb6d497fd0ff1302fb7585vboxsync#if defined(VBOX_WITH_NETFLT)
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --ifname <hostonly_if_name>\n"
7bf07b1592dfaab1a4fb6d497fd0ff1302fb7585vboxsync#endif
4c8907a420ed66a42f729eb08cddf9c1e57f25eavboxsync " [--ip <ip_address>\n"
4c8907a420ed66a42f729eb08cddf9c1e57f25eavboxsync " --netmask <network_mask>\n"
4c8907a420ed66a42f729eb08cddf9c1e57f25eavboxsync " --lowerip <lower_ip>\n"
4c8907a420ed66a42f729eb08cddf9c1e57f25eavboxsync " --upperip <upper_ip>]\n"
4c8907a420ed66a42f729eb08cddf9c1e57f25eavboxsync " [--enable | --disable]\n\n"
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "VBoxManage dhcpserver remove --netname <network_name> |\n"
7bf07b1592dfaab1a4fb6d497fd0ff1302fb7585vboxsync#if defined(VBOX_WITH_NETFLT)
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync " --ifname <hostonly_if_name>\n"
7bf07b1592dfaab1a4fb6d497fd0ff1302fb7585vboxsync#endif
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync "\n");
d1fcf24d24368926be13484524a9e378070a9157vboxsync }
eaa687a9ede02b3b161a4595f7e42590a2e1b932vboxsync if (u64Cmd & USAGE_EXTPACK)
eaa687a9ede02b3b161a4595f7e42590a2e1b932vboxsync {
eaa687a9ede02b3b161a4595f7e42590a2e1b932vboxsync RTStrmPrintf(pStrm,
4c8907a420ed66a42f729eb08cddf9c1e57f25eavboxsync "VBoxManage extpack install <tarball> |\n"
4c8907a420ed66a42f729eb08cddf9c1e57f25eavboxsync " uninstall [--force] <name> |\n"
4c8907a420ed66a42f729eb08cddf9c1e57f25eavboxsync " cleanup\n"
eaa687a9ede02b3b161a4595f7e42590a2e1b932vboxsync "\n");
eaa687a9ede02b3b161a4595f7e42590a2e1b932vboxsync }
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync}
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync/**
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync * Print a usage synopsis and the syntax error message.
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync * @returns RTEXITCODE_SYNTAX.
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync */
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsyncRTEXITCODE errorSyntax(USAGECATEGORY u64Cmd, const char *pszFormat, ...)
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync{
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync va_list args;
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync showLogo(g_pStdErr); // show logo even if suppressed
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#ifndef VBOX_ONLY_DOCS
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync if (g_fInternalMode)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync printUsageInternal(u64Cmd, g_pStdErr);
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync else
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync printUsage(u64Cmd, g_pStdErr);
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync#endif /* !VBOX_ONLY_DOCS */
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync va_start(args, pszFormat);
3a8aa22ef125135ef67bfc396771bcee15ef02dfvboxsync RTStrmPrintf(g_pStdErr, "\nSyntax error: %N\n", pszFormat, &args);
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync va_end(args);
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync return RTEXITCODE_SYNTAX;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync}
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync/**
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync * errorSyntax for RTGetOpt users.
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync *
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync * @returns RTEXITCODE_SYNTAX.
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync *
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync * @param fUsageCategory The usage category of the command.
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync * @param rc The RTGetOpt return code.
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync * @param pValueUnion The value union.
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync */
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsyncRTEXITCODE errorGetOpt(USAGECATEGORY fUsageCategory, int rc, union RTGETOPTUNION const *pValueUnion)
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync{
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync /*
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync * Check if it is an unhandled standard option.
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync */
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync if (rc == 'V')
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync {
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync RTPrintf("%sr%d\n", VBOX_VERSION_STRING, RTBldCfgRevision());
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync return RTEXITCODE_SUCCESS;
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync }
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync if (rc == 'h')
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync {
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync showLogo(g_pStdErr);
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync#ifndef VBOX_ONLY_DOCS
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync if (g_fInternalMode)
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync printUsageInternal(fUsageCategory, g_pStdOut);
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync else
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync printUsage(fUsageCategory, g_pStdOut);
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync#endif
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync return RTEXITCODE_SUCCESS;
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync }
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync /*
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync * General failure.
1ce069685b24d243eb0464f46d4c56b250c64445vboxsync */
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync showLogo(g_pStdErr); // show logo even if suppressed
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync#ifndef VBOX_ONLY_DOCS
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync if (g_fInternalMode)
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync printUsageInternal(fUsageCategory, g_pStdErr);
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync else
824ae3158a8b8f8233fec3f5a12c81f139933698vboxsync printUsage(fUsageCategory, g_pStdErr);
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync#endif /* !VBOX_ONLY_DOCS */
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync if (rc == VINF_GETOPT_NOT_OPTION)
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync return RTMsgErrorExit(RTEXITCODE_SYNTAX, "Invalid parameter '%s'", pValueUnion->psz);
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync if (rc > 0)
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync {
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync if (RT_C_IS_PRINT(rc))
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync return RTMsgErrorExit(RTEXITCODE_SYNTAX, "Invalid option -%c", rc);
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync return RTMsgErrorExit(RTEXITCODE_SYNTAX, "Invalid option case %i", rc);
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync }
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync if (rc == VERR_GETOPT_UNKNOWN_OPTION)
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync return RTMsgErrorExit(RTEXITCODE_SYNTAX, "Unknown option: %s", pValueUnion->psz);
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync if (pValueUnion->pDef)
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync return RTMsgErrorExit(RTEXITCODE_SYNTAX, "%s: %Rrs", pValueUnion->pDef->pszLong, rc);
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync return RTMsgErrorExit(RTEXITCODE_SYNTAX, "%Rrs", rc);
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync}
a55af63ead2dcca370bfc0dfe49771d9dcc61b93vboxsync
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync/**
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync * Print an error message without the syntax stuff.
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync *
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync * @returns RTEXITCODE_SYNTAX.
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync */
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsyncRTEXITCODE errorArgument(const char *pszFormat, ...)
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync{
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync va_list args;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync va_start(args, pszFormat);
9b1bd65f02252ae2d62078951eeac9df809bbdfdvboxsync RTMsgErrorV(pszFormat, args);
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync va_end(args);
53c715b46bccd175005ee523f7acc7962cfcdf94vboxsync return RTEXITCODE_SYNTAX;
2711c80499bbd95e3da4a6cd2dffd9f81a5dce98vboxsync}