To remove metadata for key "example-key" for a virtual machine instance named "example-instance" in project "example-project", run:
gdcloud compute instances remove-metadata example-instance --project example-project --keys=key1,key2
To remove all metadata from an instance named "example-instance", run:
gdcloud compute instances remove-metadata example-instance --project example-project --all
INDICATEURS FACULTATIFS
--all count If set, all metadata entries are removed.
For example, --all. At least one of the flags --all or --keys is required.
--keys stringArray List of comma-separated key entries that must be removed from the metadata of the virtual machine instance.
For example, --keys=key1, key2. At least one of the flags --all or --keys is required.
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/04 (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/04 (UTC)."],[[["\u003cp\u003eThe \u003ccode\u003egdcloud compute instances remove-metadata\u003c/code\u003e command is used to remove metadata from a virtual machine instance.\u003c/p\u003e\n"],["\u003cp\u003eYou can specify particular metadata keys to remove using the \u003ccode\u003e--keys\u003c/code\u003e flag, providing a comma-separated list.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003e--all\u003c/code\u003e flag allows you to remove all metadata entries from the specified instance at once.\u003c/p\u003e\n"],["\u003cp\u003eAt least one of either \u003ccode\u003e--all\u003c/code\u003e or \u003ccode\u003e--keys\u003c/code\u003e flags are required to run this command.\u003c/p\u003e\n"],["\u003cp\u003eThis tool is part of the broader \u003ccode\u003egdcloud\u003c/code\u003e command-line interface, which also includes global flags like \u003ccode\u003e--configuration\u003c/code\u003e, \u003ccode\u003e--format\u003c/code\u003e, \u003ccode\u003e--project\u003c/code\u003e, and \u003ccode\u003e--quiet\u003c/code\u003e.\u003c/p\u003e\n"]]],[],null,["# gdcloud compute instances remove-metadata\n\nNAME\n----\n\ngdcloud compute instances remove-metadata - Remove metadata for a virtual machine instance.\n\nSYNOPSIS\n--------\n\n gdcloud compute instances remove-metadata INSTANCE_NAME [flags]\n\n### EXAMPLES\n\n To remove metadata for key \"example-key\" for a virtual machine instance named \"example-instance\" in project \"example-project\", run:\n\n gdcloud compute instances remove-metadata example-instance --project example-project --keys=key1,key2\n\n To remove all metadata from an instance named \"example-instance\", run:\n\n gdcloud compute instances remove-metadata example-instance --project example-project --all\n\n### OPTIONAL FLAGS\n\n --all count If set, all metadata entries are removed.\n For example, --all. At least one of the flags --all or --keys is required.\n --keys stringArray List of comma-separated key entries that must be removed from the metadata of the virtual machine instance.\n For example, --keys=key1, key2. At least one of the flags --all or --keys is required.\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/gdch/resources/gdcloud-reference/gdcloud) page."]]