For the complete documentation index, see llms.txt. This page is also available as Markdown.

create

Create a PostgreSQL cluster

Usage

ionosctl dbaas postgres cluster create [flags]

Aliases

For postgres command:

[pg pgsql postgresql psql]

For cluster command:

[c]

For create command:

[c]

Description

Create a new PostgreSQL cluster.

The cluster attaches to a private LAN inside one of your virtual datacenters (VDC), so at minimum you must supply the network connection (--datacenter-id, --lan-id, --cidr) and the credentials for the initial database user (--db-username, --db-password). Every other property has a sensible default (PostgreSQL 15, 1 instance, 2 cores, 4GB RAM, 20GB HDD storage, ASYNCHRONOUS replication).

--location is the physical region the instances live in and cannot be changed later; if omitted it is inherited from the datacenter's location.

Sizing constraints: --instances 1-5 (1 master + n-1 read-standbys), --cores min 1, --ram min 4GB (must be a multiple of 1024MB), --storage-size 10GB-2TB.

To seed the cluster from an existing backup instead of an empty database (a clone), add --backup-id, and optionally --recovery-time to replay to a point in time within that backup's recovery window.

Provisioning is asynchronous: the cluster returns immediately in a non-AVAILABLE state. Wait for AVAILABLE (e.g. via 'cluster get') before creating additional databases or users.

Required values to run command:

  • Datacenter Id

  • Lan Id

  • CIDR (IP and subnet)

  • Credentials for the database user: Username and Password

Options

Examples

Last updated

Was this helpful?