You are here: Tools > GMTool > Command groups > Admin

Admin

The admin command group allows you to administrate virtual devices.

This feature is only available with Indie and Business licenses.

Commands available within this group are:

  • templates: lists all online and offline available virtual device templates and their basic properties (name, screen size and Android version). Options available for this command are:
    • --full: displays all properties of the virtual device templates (name, UUID, description, Android version, API level, Genymotion version, screen width, height, density and DPI, number of CPUs, RAM, internal storage, telephony, Android navigation bar visibility, virtual keyboard).
    • -f|--force-refresh: forces a refresh of the template list from the server.
      By default, the template list is stored locally to avoid too many server requests.
  • create <TEMPLATE_NAME> | <TEMPLATE_UUID> <VIRTUAL_DEVICE_NAME>: creates a virtual device from the specified template.

    If some shared virtual devices have the same name as other templates, you must specify the template UUID instead of the template name. You can retrieve the UUID using gmtool admin templates --full

    The default template configuration can be overridden by specifying optional arguments. Options available for this command are:

    • --density=<SCREEN_DENSITY>: sets the screen density of the virtual device.
      The value must be the density in pixels per inch or the name of the corresponding bucket, as shown in the table below.
    • Density values
      Density bucket namePixels per inch
      ldpi120
      mdpi160
      tvdpi213
      hdpi240
      xhdpi320
      420dpi420
      xxhdpi480
      560dpi560
      xxxhdpi640

    • --width=<SCREEN_WIDTH>: sets the screen width of the virtual device.
    • --height=<SCREEN_HEIGHT>: sets the screen height of the virtual device.
    • --virtualkeyboard=<on|off>: activates or deactivates the virtual keyboard.
    • --navbar=<on|off>: displays or hides the Android navigation bar in the virtual device.
    • --nbcpu=<NUMBER_OF_CPUs>: sets the number of processors used by the virtual device.
    • --ram=<RAM_IN_MB>: sets the memory space allocated to the virtual device in MB.
    • --network-mode=<nat|bridge>: sets the host network interface mode for the virtual device.
    • --bridged-if=<BRIDGED_INTERFACE>: when network mode is bridge, sets the bridged interface for the virtual device.
    • --sysprop=<PROPERTY:VALUE>: sets one build system property of the virtual device. Available properties are: MODEL, PRODUCT, MANUFACTURER, BOARD, BRAND, DEVICE, DISPLAY, SERIAL, TYPE, FINGERPRINT, TAGS. You can set multiple system properties. Values of each property are detailed in developer.android.com.
  • edit <VIRTUAL_DEVICE_NAME>: edits the specified virtual device with optional arguments. Options available for this command are:
    • --density=<SCREEN_DENSITY>: sets the screen density of the virtual device. For more information about density values, please refer to table Density values.
    • --width=<SCREEN_WIDTH>: sets the screen width of the virtual device.
    • --height=<SCREEN_HEIGHT>: sets the screen height of the virtual device.
    • --virtualkeyboard=<on|off>: activates or deactivates the virtual keyboard.
    • --navbar=<on|off>: displays or hides the Android navigation bar in the virtual device.
    • --nbcpu=<NUMBER_OF_CPUs>: sets the number of processors used by the virtual device.
    • --ram=<RAM_IN_MB>: sets the memory space allocated to the virtual device in MB.
    • --network-mode=<nat|bridge>: sets the host network interface mode for the virtual device.
    • --bridged-if=<BRIDGED_INTERFACE>: when network mode is bridge, sets the bridged interface for the virtual device.
    • --sysprop=<PROPERTY:VALUE>: sets one build system property of the virtual device. Available properties are: MODEL, PRODUCT, MANUFACTURER, BOARD, BRAND, DEVICE, DISPLAY, SERIAL, TYPE, FINGERPRINT, TAGS. You can set multiple system properties. Values of each property are detailed in developer.android.com.
  • delete <VIRTUAL_DEVICE_NAME>: deletes the specified virtual device.
  • clone <ORIGINAL_VIRTUAL_DEVICE_NAME> <NEW_VIRTUAL_DEVICE_NAME>: duplicates the specified original virtual device to a new virtual device.
  • list: lists all virtual devices. Options available for this command are:
    • --running: lists running virtual devices.
    • --off: lists turned off virtual devices.
  • details [<VIRTUAL_DEVICE_NAME_1>] [<VIRTUAL_DEVICE_NAME_2>]: returns the properties of one or more specified virtual devices. If no virtual device is specified, returns the properties of all virtual devices.
  • start <VIRTUAL_DEVICE_NAME>: starts the specified virtual device. This command is not available with --cloud.
  • stop <VIRTUAL_DEVICE_NAME>: stops the specified virtual device. This command is not available with --cloud.
  • stopall: stops all virtual devices.
  • factoryreset <VIRTUAL_DEVICE_NAME>: restores the specified virtual device to factory state.
  • logzip: generates an archive of all Genymotion log files. Option -n|--name <VIRTUAL_DEVICE_NAME> [LOG_ARCHIVE_PATH] generates a log archive of the specified virtual device, at the defined location.

    If an archive file already exists, it will be overwritten.

  • startdisposable <TEMPLATE_NAME> | <TEMPLATE_UUID> <VIRTUAL_DEVICE_NAME>: creates and starts a virtual device from the specified template. The default template configuration can be overridden by specifying optional arguments (see the list of optional arguments available in the create command). A disposable device is a device that is automatically created when you start it, and automatically deleted when you stop it. To set the connection on a specific port, you can define option --adb-serial-port <PORT> with a port comprised between 1024 and 65535.
    This command is only available with --cloud.
  • If some shared virtual devices have the same name as other templates, you must specify the template UUID instead of the template name. You can retrieve the UUID using gmtool admin templates --full

  • stopdisposable <VIRTUAL_DEVICE_NAME>: stops and deletes the specified virtual device started with startdisposable. This command is only available with --cloud.