Skip to main content

instances

Creates, updates, deletes, gets or lists an instances resource.

Overview

Nameinstances
TypeResource
Idlinode.databases.instances

Fields

The following fields are returned by SELECT queries:

Returns a paginated list of all accessible Managed Databases on your account.

NameDatatypeDescription
idintegerRead-only A unique ID that can be used to identify and reference the Managed Database.
allow_listarrayControls 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.
cluster_sizeintegerThe number of Linode instance nodes deployed to the Managed Database. - Choose 3 nodes to create a high availability cluster that consists of one primary node and two replica nodes. - A 2 node cluster is only available with a dedicated plan. It consists of one primary node and one replica node.
createdstring (date-time)Read-only When this Managed Database was created. (example: 2022-01-01T00:01:01)
encryptedbooleanRead-only Whether the Managed Databases is encrypted. Currently required to be true.
enginestringFilterable, Read-only The Managed Database engine type. (example: mysql)
forkobjectDetails on the database that was the target of the fork. This only exists if the database was restored by creating a fork from another MySQL or PostgreSQL database.
hostsobjectRead-only The primary and secondary hosts for the Managed Database. These are assigned after provisioning is complete.
instance_uristringRead-only Append this to https://api.linode.com to run commands for the Managed Database. (example: /v4/databases/mysql/instances/123)
labelstringFilterable A unique, user-defined string referring to the Managed Database. This string needs to be unique per Managed Database engine type. (example: example-db)
membersobjectRead-only A mapping between IP addresses and strings designating them as primary or failover.
oldest_restore_timestring (date-time)Read-only The oldest time to which a database can be restored. (example: 2024-10-03 20:48:05)
platformstringFilterable, Read-only The back-end platform for relational databases used by the service. (example: rdbms-default)
portintegerRead-only The access port for this Managed Database.
regionstringFilterable The Region ID for the Managed Database. (example: us-east)
statusstringFilterable, Read-only The operating status of the Managed Database. (example: active)
total_disk_size_gbintegerRead-only The total disk size of the database, in GB.
typestringFilterable The Linode Instance type used by the Managed Database for its nodes. (example: g6-dedicated-2)
updatedstring (date-time)Read-only When this Managed Database was last updated. (example: 2022-01-01T00:01:01)
updatesobjectConfiguration settings for automated patch update maintenance for the Managed Database.
used_disk_size_gbintegerRead-only The amount of space currently in use in the database, in GB.
versionstringFilterable The Managed Database engine version. (example: 8.0.26)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_databases_instancesselectpage, page_sizeDisplay all Managed Databases accessible to your user, regardless of engine type. For more detailed information on a particular database instance, make a request to its instance_uri.

Learn more...

Learn more...

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
pageintegerThe page of a collection to return.
page_sizeintegerThe number of items to return per page.

SELECT examples

Display all Managed Databases accessible to your user, regardless of engine type. For more detailed information on a particular database instance, make a request to its instance_uri.

Learn more...

Learn more...

SELECT
id,
allow_list,
cluster_size,
created,
encrypted,
engine,
fork,
hosts,
instance_uri,
label,
members,
oldest_restore_time,
platform,
port,
region,
status,
total_disk_size_gb,
type,
updated,
updates,
used_disk_size_gb,
version
FROM linode.databases.instances
WHERE page = '{{ page }}'
AND page_size = '{{ page_size }}';