Create or restore a MySQL Managed Database

Provision a MySQL Managed Database

Use this operation to create a new MySQL Managed Database.

  • New instances can take 10 to 15 minutes to deploy.

  • When you create a new MySQL Managed Database, our partner Aiven automatically enables disk encryption on each cluster.

  • All Managed Databases include automatic, daily backups. Up to seven backups are automatically stored for each Managed Database, providing restore points for each day of the past week.

  • All Managed Databases include automatic updates, which apply security patches to the underlying operating system of the MySQL Managed Database. Configure the maintenance window for these updates with the Update a managed MySQL database operation.

  • If your database cluster is configured with a single node, downtime occurs during maintenance updates. You should adjust the window to match a time that's the least disruptive to your application and users. Also consider upgrading to a high availability plan to avoid any maintenance downtime.

  • Major upgrades are optional until the service reaches end of service, and can be done in place.

  • A successful request triggers a database_create event.

Beta Virtual Private Cloud (VPC) support

You can create a MySQL Managed Database in a VPC using the private_network object in the request. Talk to your Akamai account team for more details.

📘

Currently, VPC subnets associated with Managed Database instances don't automatically block outbound connections outside the subnet. To limit network exposure, you should configure Cloud Firewall rules to explicitly deny outbound connections beyond the intended subnet. For more details on configuring rules, see the Cloud Firewall documentation.

Restore a MySQL Managed Database

Include the fork object in the request to target a backed-up database.

📘

Restoring from a backup creates a second running cluster, which incurs billing. Delete the first cluster after the restore is complete, to avoid this billing.

👍

There's a tutorial

We offer an example API workflow you can follow to restore a Managed Database backup.

Permissions and scopes

To call this operation, you need the following:

  • Identity and access permissions. Your user needs these roles assigned. Learn more.

    • Roles: account_database_creator
  • OAuth scopes. Your user needs these scopes assigned. Learn more.

    • Scopes: databases:read_write

CLI

linode-cli databases mysql-create \
  --label example-db1 \
  --region us-east \
  --type g6-dedicated-2 \
  --cluster_size 3 \
  --engine mysql/8.0.26 \
  --engine_config.binlog_retention_period 600 \
  --engine_config.mysql.connect_timeout 10 \
  --engine_config.mysql.default_time_zone +03:00 \
  --ssl_connection true \
  --allow_list 203.0.113.1 \
  --allow_list 192.0.1.0/24

Learn more

Path Params
string
enum
required

Enum Call either the v4 URL, or v4beta for operations still in Beta.

Allowed:
Body Params

Managed MySQL Database request object.

allow_list
array of strings
length ≥ 0

Controls access to the Managed Database.

  • Individually included IP addresses or CIDR ranges can access the Managed Database while all other sources are blocked.

  • A standalone value of 0.0.0.0/0 allows all IP addresses access to the Managed Database.

  • An empty array ([]) blocks all public and private connections to the Managed Database.

allow_list
integer
enum
Defaults to 1

The number of Linode instance nodes deployed to the Managed Database, from 1 to 3. Consider these points when setting a cluster_size:

  • Choose 3 nodes to create a high availability cluster that consists of one primary node and two standby nodes.

  • A 2 node cluster is only available with a dedicated plan. It consists of one primary node and one standby node.

Allowed:
string
required

The Managed Database engine in engine/version format.

engine_config
object

Advanced parameters you can apply to a MySQL Managed Database, via our partner Aiven's specification. Only include the objects for parameters you want to set in your database. Omit objects for parameters you don't want to define or change.

📘

Aiven may offer additional parameters in their specification, or accept different values and ranges. Currently, only the parameters and settings covered here are supported for use in a MySQL Managed Database. You can also run the List MySQL Managed Database advanced parameters operation to see an up-to-date list.

fork
object

Include this object to restore a Managed Database by forking from a backup.

  • If you include this object, all other fields are optional.

  • Don't include this object if you're creating a new Managed Database.

string
required
length between 3 and 32

Filterable A name used to identify the Managed Database. This needs to be unique per Managed Database engine type. For example, you could use database_1, database_2, and database_3 for three unique MySQL Managed Databases. You can also use these same names for three unique PostgreSQL Managed Databases. However, you can't repeat any of these names for either engine type.

private_network
object | null

Beta Restricts access on a MySQL Managed Database to a specific Virtual Private Cloud (VPC) configured for the cluster.

string
required

Filterable The unique identifier for the region where the Managed Database lives.

boolean
Defaults to true

Currently required to be true. Whether to require SSL credentials to establish a connection to the Managed Database. Run the Get managed MySQL database credentials operation for access information.

string
required

Filterable The Linode Instance type used by the Managed Database for its nodes.

Responses

Language
Credentials
LoadingLoading…
Response
Choose an example:
application/json