[[["わかりやすい","easyToUnderstand","thumb-up"],["問題の解決に役立った","solvedMyProblem","thumb-up"],["その他","otherUp","thumb-up"]],[["わかりにくい","hardToUnderstand","thumb-down"],["情報またはサンプルコードが不正確","incorrectInformationOrSampleCode","thumb-down"],["必要な情報 / サンプルがない","missingTheInformationSamplesINeed","thumb-down"],["翻訳に関する問題","translationIssue","thumb-down"],["その他","otherDown","thumb-down"]],["最終更新日 2025-08-28 UTC。"],[],[],null,["# Manage features through metadata\n================================\n\nThis page describes how to manage some Vertex AI Workbench instance features\nby modifying the instance's metadata key-value pairs.\n\nMetadata keys\n-------------\n\nFor information about features and their respective metadata keys,\nsee the following table.\n\nMetadata managed by Compute Engine\n----------------------------------\n\nSome of the metadata keys are predefined by Compute Engine. For more\ninformation, see\n[Predefined metadata\nkeys](/compute/docs/metadata/predefined-metadata-keys).\n\nProtected metadata keys\n-----------------------\n\nSome metadata keys are reserved for system use only. If you assign\nvalues to these metadata keys, the new values will be overwritten by the\nsystem values.\n\nReserved metadata keys include and are not limited to:\n\n- `data-disk-uri`\n- `enable-oslogin`\n- `framework`\n- `notebooks-api`\n- `notebooks-api-version`\n- `nvidia-driver-gcs-path`\n- `proxy-url`\n- `restriction`\n- `shutdown-script`\n- `title`\n- `version`\n\nCreate an instance with specific metadata\n-----------------------------------------\n\nYou can create a Vertex AI Workbench instance with specific metadata\nby using the Google Cloud console, the Google Cloud CLI,\nTerraform, or the Notebooks API. \n\n### Console\n\nWhen you create a Vertex AI Workbench instance, you can add\nmetadata in the **Environment** section of **Advanced options**.\n\n### gcloud\n\nWhen you create a Vertex AI Workbench instance, you can add\nmetadata by using the following command: \n\n```bash\ngcloud workbench instances create INSTANCE_NAME --metadata=KEY=VALUE\n```\n\n### Terraform\n\nTo add metadata, create the resource with metadata key-value pairs.\n\n\u003cbr /\u003e\n\nTo learn how to apply or remove a Terraform configuration, see\n[Basic Terraform commands](/docs/terraform/basic-commands).\n\n\u003cbr /\u003e\n\n resource \"google_workbench_instance\" \"default\" {\n name = \"workbench-instance-example\"\n location = \"us-central1-a\"\n\n gce_setup {\n machine_type = \"n1-standard-1\"\n vm_image {\n project = \"cloud-notebooks-managed\"\n family = \"workbench-instances\"\n }\n metadata = {\n key = \"value\"\n }\n }\n }\n\n### Notebooks API\n\nUse the [`instances.create`](/vertex-ai/docs/workbench/reference/rest/v2/projects.locations.instances/create)\nmethod with metadata values to manage the corresponding features.\n\nUpdate an instance's metadata\n-----------------------------\n\nYou can update the metadata of a Vertex AI Workbench instance\nby using the Google Cloud console, the Google Cloud CLI,\nTerraform, or the Notebooks API. \n\n### Console\n\nTo update the metadata of a Vertex AI Workbench instance,\ndo the following:\n\n1. In the Google Cloud console, go to the **Instances** page.\n\n [Go to Instances](https://console.cloud.google.com/vertex-ai/workbench/instances)\n2. In the list of instances, click the name of the instance that you want\n to update.\n\n3. On the **Instance details** page, click **Software and security**.\n\n4. In the **Metadata** section, update the metadata key-value pairs that\n you want to change.\n\n5. Click **Submit**.\n\n### gcloud\n\nYou can update the metadata on a Vertex AI Workbench instance\nby using the following command: \n\n```bash\ngcloud workbench instances update INSTANCE_NAME --metadata=KEY=VALUE\n```\n\n### Terraform\n\nYou can change the metadata key-value pairs to manage\nthe corresponding features on Vertex AI Workbench instances.\n\n\u003cbr /\u003e\n\nTo learn how to apply or remove a Terraform configuration, see\n[Basic Terraform commands](/docs/terraform/basic-commands).\n\n\u003cbr /\u003e\n\n resource \"google_workbench_instance\" \"default\" {\n name = \"workbench-instance-example\"\n location = \"us-central1-a\"\n\n gce_setup {\n machine_type = \"n1-standard-1\"\n vm_image {\n project = \"cloud-notebooks-managed\"\n family = \"workbench-instances\"\n }\n metadata = {\n key = \"updated_value\"\n }\n }\n }\n\n### Notebooks API\n\nUse the [`instances.patch`](/vertex-ai/docs/workbench/reference/rest/v2/projects.locations.instances/patch)\nmethod with metadata values and `gce_setup.metadata` in the `updateMask`\nto manage the corresponding features.\n\nRemove metadata from an instance\n--------------------------------\n\nYou can remove metadata from a Vertex AI Workbench instance\nby using the Google Cloud console, the Google Cloud CLI,\nTerraform, or the Notebooks API. \n\n### Console\n\nTo remove metadata from a Vertex AI Workbench instance,\ndo the following:\n\n1. In the Google Cloud console, go to the **Instances** page.\n\n [Go to Instances](https://console.cloud.google.com/vertex-ai/workbench/instances)\n2. In the list of instances, click the name of the instance that you want\n to modify.\n\n3. On the **Instance details** page, click **Software and security**.\n\n4. In the **Metadata** section, to the right of a key-value pair that\n you want to delete, click\n delete **Delete**.\n\n5. Click **Submit**.\n\n### gcloud\n\nYou can remove metadata from a Vertex AI Workbench instance\nby using the following command: \n\n```bash\ngcloud workbench instances update INSTANCE_NAME --metadata=KEY\n```\n\n### Terraform\n\nYou can remove metadata key-value pairs to manage the\ncorresponding features of a Vertex AI Workbench instance.\n\n\u003cbr /\u003e\n\nTo learn how to apply or remove a Terraform configuration, see\n[Basic Terraform commands](/docs/terraform/basic-commands).\n\n\u003cbr /\u003e\n\n resource \"google_workbench_instance\" \"default\" {\n name = \"workbench-instance-example\"\n location = \"us-central1-a\"\n\n gce_setup {\n machine_type = \"n1-standard-1\"\n vm_image {\n project = \"cloud-notebooks-managed\"\n family = \"workbench-instances\"\n }\n metadata = {\n }\n }\n }\n\n### Notebooks API\n\nUse the [`instances.patch`](/vertex-ai/docs/workbench/reference/rest/v2/projects.locations.instances/patch)\nmethod with the metadata value set to an empty string and\n`gce_setup.metadata` in the `updateMask` to remove the\ncorresponding feature."]]