To delete an instance named "example-instance" in project "example-project", run:
gdcloud compute instances delete example-instance --project example-project
INDICATEURS FACULTATIFS
--delete-disks DISK_TYPE The types of disks to delete with instance deletion regardless of the
disks' auto-delete configuration on the VM instance. When this flag is
provided, the auto-delete bits on the attached disks are modified
accordingly before the instance deletion request is issued.
DISK_TYPE must be one of:
all: All disks
boot: Only the disks where first partition is reserved for the root filesystem
data: Only non-boot disks
The default is to leave the auto-delete bits on the attached disks unchanged.
--keep-disks DISK_TYPE The types of disks to NOT delete with instance deletion regardless of
the disks' auto-delete configuration on the VM instance. When this flag
is provided, the auto-delete bits on the attached disks are modified
accordingly before the instance deletion request is issued.
DISK_TYPE must be one of:
all: All disks
boot: Only the disks where first partition is reserved for the root filesystem
data: Only non-boot disks
The default is to leave the auto-delete bits on the attached disks unchanged.
OPTIONS GCLOUD GÉNÉRALES
Ces options sont disponibles pour toutes les commandes : --configuration, --format, --help, --project, --quiet.
Sauf indication contraire, le contenu de cette page est régi par une licence Creative Commons Attribution 4.0, et les échantillons de code sont régis par une licence Apache 2.0. Pour en savoir plus, consultez les Règles du site Google Developers. Java est une marque déposée d'Oracle et/ou de ses sociétés affiliées.
Dernière mise à jour le 2025/09/05 (UTC).
[[["Facile à comprendre","easyToUnderstand","thumb-up"],["J'ai pu résoudre mon problème","solvedMyProblem","thumb-up"],["Autre","otherUp","thumb-up"]],[["Difficile à comprendre","hardToUnderstand","thumb-down"],["Informations ou exemple de code incorrects","incorrectInformationOrSampleCode","thumb-down"],["Il n'y a pas l'information/les exemples dont j'ai besoin","missingTheInformationSamplesINeed","thumb-down"],["Problème de traduction","translationIssue","thumb-down"],["Autre","otherDown","thumb-down"]],["Dernière mise à jour le 2025/09/05 (UTC)."],[],[],null,["# gdcloud compute instances delete\n\nNAME\n----\n\ngdcloud compute instances delete - Delete virtual machine instances.\n\nSYNOPSIS\n--------\n\n gdcloud compute instances delete INSTANCE_NAME [flags]\n\n### EXAMPLES\n\n To delete an instance named \"example-instance\" in project \"example-project\", run:\n\n gdcloud compute instances delete example-instance --project example-project\n\n### OPTIONAL FLAGS\n\n --delete-disks DISK_TYPE The types of disks to delete with instance deletion regardless of the\n disks' auto-delete configuration on the VM instance. When this flag is\n provided, the auto-delete bits on the attached disks are modified\n accordingly before the instance deletion request is issued.\n \n DISK_TYPE must be one of:\n all: All disks\n boot: Only the disks where first partition is reserved for the root filesystem\n data: Only non-boot disks\n The default is to leave the auto-delete bits on the attached disks unchanged.\n --keep-disks DISK_TYPE The types of disks to NOT delete with instance deletion regardless of\n the disks' auto-delete configuration on the VM instance. When this flag\n is provided, the auto-delete bits on the attached disks are modified\n accordingly before the instance deletion request is issued.\n \n DISK_TYPE must be one of:\n all: All disks\n boot: Only the disks where first partition is reserved for the root filesystem\n data: Only non-boot disks\n The default is to leave the auto-delete bits on the attached disks unchanged.\n\n### GDCLOUD WIDE FLAGS\n\nThese flags are available to all commands: `--configuration`, `--format`, `--help`, `--project`, `--quiet`.\n\nFor more information, see the [gdcloud CLI reference overview](/distributed-cloud/hosted/docs/latest/appliance/resources/gdcloud-reference/gdcloud) page."]]