Please note that the contents of this offline web site may be out of date. To access the most recent documentation visit the online version .
Note that links that point to online resources are green in color and will open in a new window.
We would love it if you could give us feedback about this material by filling this form (You have to be online to fill it)



Disk Commands

Contents

adddisk

adddisk                      Create new persistent disks.

                             Specify multiple disks as multiple arguments.
                             Multiple disks will be created in parallel.

                             Usage: gcutil [--global_flags] adddisk
                             [--command_flags] <disk-name-1> ... <disk-name-n>

                             Flags for adddisk:

gcutil_lib.disk_cmds:
  --description: An optional description for this disk.
    (default: '')
  --size_gb: Sets the size of this disk, in GB. The default size is 500 GB. If
    source_snapshot is also specified, This value must be greater than or equal
    to the size of the disk from which the source_snapshot was created.
    (an integer)
  --source_image: Specifies a source image for this disk, making this a root
    persistent disk. If you set this option, you cannot specify a
    source_snapshot.
  --source_snapshot: Specifies the source snapshot for this disk. If you set
    this option, you cannot specify a source_image.
  --[no]wait_until_complete: Specifies that gcutil should wait until the disk is
    successfully created before it returns.
    (default: 'false')
  --zone: The zone for this request.

gflags:
  --flagfile: Insert flag definitions from the given file into the command line.
    (default: '')
  --undefok: comma-separated list of flag names that it is okay to specify on
    the command line even if the program does not define a flag with that name.
    IMPORTANT: flags in this list that have arguments MUST use the --flag=value
    format.
    (default: '')

attachdisk

attachdisk                   Attach a persistent disk to a VM instance.

                             Usage: gcutil [--global_flags] attachdisk
                             [--command_flags] <instance-name>

                             Flags for attachdisk:

gcutil_lib.instance_cmds:
  --disk: [Required] The name of a disk to be attached to the instance. The name
    may be followed by a comma-separated list of name=value pairs specifying
    options. Legal option names are 'deviceName', to specify the disk's device
    name, and 'mode', to indicate whether the disk should be attached READ_WRITE
    (the default) or READ_ONLY;
    repeat this option to specify a list of values
    (default: "['']")
  --zone: [Required] The zone for this request.

gflags:
  --flagfile: Insert flag definitions from the given file into the command line.
    (default: '')
  --undefok: comma-separated list of flag names that it is okay to specify on
    the command line even if the program does not define a flag with that name.
    IMPORTANT: flags in this list that have arguments MUST use the --flag=value
    format.
    (default: '')

deletedisk

deletedisk                   Delete one or more persistent disks.

                             Specify multiple disks as space-separated entries.
                             If multiple disk names are specified, the disks
                             will be deleted in parallel.

                             Usage: gcutil [--global_flags] deletedisk
                             [--command_flags] <disk-name-1> ... <disk-name-n>

                             Flags for deletedisk:

gcutil_lib.command_base:
  -f,--[no]force: Override the "Delete disk" prompt
    (default: 'false')

gcutil_lib.disk_cmds:
  --zone: The zone for this request.

gflags:
  --flagfile: Insert flag definitions from the given file into the command line.
    (default: '')
  --undefok: comma-separated list of flag names that it is okay to specify on
    the command line even if the program does not define a flag with that name.
    IMPORTANT: flags in this list that have arguments MUST use the --flag=value
    format.
    (default: '')

detachdisk

detachdisk                   Detach a persistent disk from a VM instance.

                             Usage: gcutil [--global_flags] detachdisk
                             [--command_flags] <instance-name>

                             Flags for detachdisk:

gcutil_lib.instance_cmds:
  --device_name: [Required] The device name of a persistent disk to detach from
    the instance. The device name is specified at instance creation time and may
    not be the same as the persistent disk name.;
    repeat this option to specify a list of values
    (default: "['']")
  --zone: [Required] The zone for this request.

gflags:
  --flagfile: Insert flag definitions from the given file into the command line.
    (default: '')
  --undefok: comma-separated list of flag names that it is okay to specify on
    the command line even if the program does not define a flag with that name.
    IMPORTANT: flags in this list that have arguments MUST use the --flag=value
    format.
    (default: '')

getdisk

getdisk                      Get a machine disk.

                             Usage: gcutil [--global_flags] getdisk
                             [--command_flags] <disk-name>

                             Flags for getdisk:

gcutil_lib.disk_cmds:
  --zone: The zone for this request.

gflags:
  --flagfile: Insert flag definitions from the given file into the command line.
    (default: '')
  --undefok: comma-separated list of flag names that it is okay to specify on
    the command line even if the program does not define a flag with that name.
    IMPORTANT: flags in this list that have arguments MUST use the --flag=value
    format.
    (default: '')

listdisks

listdisks                    List the disks for a project.

                             Usage: gcutil [--global_flags] listdisks
                             [--command_flags]

                             Flags for listdisks:

gcutil_lib.command_base:
  --columns: A comma-separated list of the desired columns to display. If 'all'
    is specified, then all possible columns will be included. Valid columns are
    <all|name|description|zone|status|source-snapshot|size-gb>.
    (a comma separated list)
  --[no]fetch_all_pages: Deprecated flag.
    (default: 'true')
  --filter: Filter expression for filtering listed resources. See gcutil
    documentation for syntax of the filter expression here:
    http://developers.google.com/compute/docs/gcutil/tips#filtering
  --max_results: Maximum number of items to list [Default is to fetch all].
    (a positive integer)

gcutil_lib.disk_cmds:
  --zone: The zone for this request.

gcutil_lib.gcutil_flags:
  --sort_by: <name|-name|zone|-zone|status|-status|size-gb|-size-gb>: Sort
    output results by the given field name. Field names starting with a "-" will
    lead to a descending order.

gflags:
  --flagfile: Insert flag definitions from the given file into the command line.
    (default: '')
  --undefok: comma-separated list of flag names that it is okay to specify on
    the command line even if the program does not define a flag with that name.
    IMPORTANT: flags in this list that have arguments MUST use the --flag=value
    format.
    (default: '')

setinstancediskautodelete

setinstancediskautodelete    Changes the auto-delete flag on a disk attached to
                             instance.

                             Usage: gcutil [--global_flags]
                             setinstancediskautodelete [--command_flags]
                             <instance-name>

                             Flags for setinstancediskautodelete:

gcutil_lib.instance_cmds:
  --[no]auto_delete: [Required] The new value of auto-delete flag for the given
    disk.
  --device_name: The device name of a persistent disk to update on the instance.
    If not specified, this will default to the instance name.
  --zone: [Required] The zone for this request.

gflags:
  --flagfile: Insert flag definitions from the given file into the command line.
    (default: '')
  --undefok: comma-separated list of flag names that it is okay to specify on
    the command line even if the program does not define a flag with that name.
    IMPORTANT: flags in this list that have arguments MUST use the --flag=value
    format.
    (default: '')

Authentication required

You need to be signed in with Google+ to do that.

Signing you in...

Google Developers needs your permission to do that.