To create a DBCluster custom resource with database version PostgreSQL 14 with name "postgresql-db", run:
gdcloud database clusters create postgresql-db \
--database-version=POSTGRESQL_14
To create a DBCluster custom resource with database version Oracle 19 with name "oracle-db" in the project "db", run:
gdcloud database clusters create oracle-db --project=db \
--database-version=ORACLE_19
To create a DBCluster custom resource with database version AlloyDB Omni 15 with name "alloydbomni-db" in the project "db", run:
gdcloud database clusters create alloydbomni-db --project=db \
--database-version=ALLOYDBOMNI_15
必要標記
--admin-password string initial database password for admin user
--database-version string database version of the DBCluster to be created.
選用旗標
--availability-type string level of availability. (zonal or zonal_ha) (default "zonal")
--backup-retention-days int number of days to keep backups since creation (1 ~ 90 days). (default 30)
--cpu int number of cores to be used for the database.
--database-flags string initial database flags
--memory string amount of memory for the database.
--no-backup disables daily backup.
--storage-size string amount of storage allocated to storing data.
--tier string machine type for a DBCluster with preset resources configuration (high-performance, standard or minimal). (default "standard")
[[["容易理解","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-19 (世界標準時間)。"],[[["\u003cp\u003eThis command, \u003ccode\u003egdcloud database clusters create\u003c/code\u003e, is used to create a DBCluster custom resource for different database versions like PostgreSQL, Oracle, and AlloyDB Omni.\u003c/p\u003e\n"],["\u003cp\u003eThe required flags for creating a DBCluster include setting the \u003ccode\u003e--admin-password\u003c/code\u003e and specifying the \u003ccode\u003e--database-version\u003c/code\u003e, such as \u003ccode\u003ePOSTGRESQL_14\u003c/code\u003e, \u003ccode\u003eORACLE_19\u003c/code\u003e, or \u003ccode\u003eALLOYDBOMNI_15\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eOptional flags can be utilized to customize the DBCluster, such as setting the \u003ccode\u003e--availability-type\u003c/code\u003e, \u003ccode\u003e--backup-retention-days\u003c/code\u003e, \u003ccode\u003e--cpu\u003c/code\u003e, \u003ccode\u003e--memory\u003c/code\u003e, \u003ccode\u003e--storage-size\u003c/code\u003e, and \u003ccode\u003e--tier\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe command is compatible with several gdcloud wide flags such as \u003ccode\u003e--configuration\u003c/code\u003e, \u003ccode\u003e--format\u003c/code\u003e, \u003ccode\u003e--help\u003c/code\u003e, \u003ccode\u003e--project\u003c/code\u003e, and \u003ccode\u003e--quiet\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eYou can refer to the \u003ca href=\"/distributed-cloud/hosted/docs/latest/gdch/resources/gdcloud-reference/gdcloud\"\u003egdcloud CLI reference overview\u003c/a\u003e page for more information regarding this command.\u003c/p\u003e\n"]]],[],null,[]]