Difference between revisions of "Aws rds describe-db-instances"

From wikieduonline
Jump to navigation Jump to search
 
(59 intermediate revisions by 3 users not shown)
Line 3: Line 3:
 
https://awscli.amazonaws.com/v2/documentation/api/latest/reference/rds/describe-db-instances.html
 
https://awscli.amazonaws.com/v2/documentation/api/latest/reference/rds/describe-db-instances.html
  
 +
* <code>aws rds describe-db-instances | egrep -w "DBInstanceIdentifier|[[Address]]|[[PubliclyAccessible]]|[[DBInstanceStatus]]"</code>
 +
* <code>aws rds describe-db-instances | egrep "DBInstanceIdentifier|[[AllocatedStorage]]"</code>
 
* <code>aws rds describe-db-instances | [[grep -w]] [[DBInstanceIdentifier]]</code>
 
* <code>aws rds describe-db-instances | [[grep -w]] [[DBInstanceIdentifier]]</code>
 
* <code>aws rds describe-db-instances | grep [[Address]]</code>
 
* <code>aws rds describe-db-instances | grep [[Address]]</code>
 +
* <code>aws rds describe-db-instances | egrep -iw "[[Address]]|[[SubnetIdentifier]]"</code>
 
* <code>aws rds describe-db-instances | grep [[MultiAZ]]</code>
 
* <code>aws rds describe-db-instances | grep [[MultiAZ]]</code>
 +
* <code>aws rds describe-db-instances | grep [[MasterUsername]]</code>
 
* <code>[[aws rds describe-db-instances --db-instance-identifier MY_DB_NAME]]</code>
 
* <code>[[aws rds describe-db-instances --db-instance-identifier MY_DB_NAME]]</code>
 
* <code>[[aws rds describe-db-instances --output table]]</code>
 
* <code>[[aws rds describe-db-instances --output table]]</code>
 
* <code>[[aws rds describe-db-instances --output text --query]] 'DBInstances[*].[DBInstanceArn,Engine,[[DBInstanceIdentifier]],[[DBInstanceStatus]]]'</code>
 
* <code>[[aws rds describe-db-instances --output text --query]] 'DBInstances[*].[DBInstanceArn,Engine,[[DBInstanceIdentifier]],[[DBInstanceStatus]]]'</code>
 +
* <code>aws rds describe-db-instances | grep [[DBInstanceStatus]]</code>
 +
 +
* <code>aws rds describe-db-instances | [[jq -r]] '.DBInstances[0].Endpoint.Address'</code>
 +
* <code>aws rds describe-db-instances | grep -i [[PreferredMaintenanceWindow]]</code>
 +
* <code>aws rds describe-db-instances | grep -i [[PerformanceInsightsEnabled]]</code>
 +
* <code>aws rds describe-db-instances | grep -i [[StorageEncrypted]]</code>
 +
* <code>aws rds describe-db-instances | grep -i [[AutoMinorVersionUpgrade]]</code>
 +
* <code>aws rds describe-db-instances | grep -i [[PubliclyAccessible]]</code>
 +
* <code>aws rds describe-db-instances | egrep -i "Address|[[VpcId]]"</code>
 +
 +
 +
 +
== [[Replication]] ==
 +
* <code>[[aws rds]] describe-db-instances | grep [[ReadReplicaSourceDBInstanceIdentifier]]</code>
 +
* <code>[[aws rds]] describe-db-instances | grep -w Status</code>
 +
* <code>[[aws rds]] describe-db-instances | grep -w StatusType</code>
 +
 +
== [[Storage]] data ==
 +
* <code>[[aws rds]] describe-db-instances | egrep "DBInstanceIdentifier|[[AllocatedStorage]]"</code>
 +
 +
* <code>[[StorageType]]</code>: https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_Storage.html
 +
** Standard: magnetic (also known as standard)
 +
** [[io1]]: provisioned IOPS [[SSD]] (also known as io1)
 +
** [[gp2]]: General Purpose SSD (also known as gp2)
 +
* <code>[[StorageEncrypted]], [[MaxAllocatedStorage]]</code>
 +
 
  [[arn]]:aws:rds:eu-central-1:4523523466:db:my_branches_name postgres  my_branches_name available
 
  [[arn]]:aws:rds:eu-central-1:4523523466:db:my_branches_name postgres  my_branches_name available
 +
[[PostgreSQL version|Version]]:
 +
* <code>aws rds describe-db-instances | egrep -w "[[EngineVersion]]|DBInstanceIdentifier"</code>
  
Output:
+
== Example Output ==
 
<pre>
 
<pre>
 
{
 
{
Line 33: Line 65:
  
 
* <code>Engine: mysql, postgres</code>
 
* <code>Engine: mysql, postgres</code>
 
[[Storage]] data:
 
* <code>[[AllocatedStorage]]</code>
 
* <code>[[StorageType]]: standard, [[io1]] and [[gp2]].</code>
 
* <code>[[StorageEncrypted]], [[MaxAllocatedStorage]]</code>
 
  
 
== Related terms ==
 
== Related terms ==
* <code>[[DBINSTANCES]]</code>
+
* <code>[[aws rds describe-db-clusters]]</code>
* <code>[[DBInstanceStatus]]</code>
+
* <code>[[DBINSTANCES]]</code>, <code>[[DBInstanceStatus]]</code>, <code>[[DBInstanceIdentifier]]</code>, <code>[[MasterUsername]]</code>
* <code>[[DBInstanceIdentifier]]</code>
 
* <code>[[MasterUsername]]</code>
 
 
* <code>[[aws cloudformation list-stacks --stack-status-filter]] CREATE_COMPLETE</code>
 
* <code>[[aws cloudformation list-stacks --stack-status-filter]] CREATE_COMPLETE</code>
 +
* [[Connect to database]]: <code>[[psql]], [[mysql]]</code>
 +
* <code>[[aws rds describe-db-proxies]]</code>
 +
* <code>[[aws rds describe-db-log-files]]</code>
 
* <code>[[aws list all]]</code>
 
* <code>[[aws list all]]</code>
* [[VpcId]]: <code>aws rds describe-db-instances | grep VcpId</code>
+
* <code>[[aws cloudwatch get-metric-statistics]]</code>
 +
* <code>[[aws redshift describe-clusters]]</code>
 +
* <code>[[InvalidDBSubnetGroupStateFault]]</code>
 +
* <code>[[aws rds describe-db-engine-versions]]</code>
 +
* <code>[[aws rds describe-db-security-groups]]</code>
 +
* <code>[[gcloud sql instances describe]]</code>
  
 
== See also ==
 
== See also ==
 
* {{aws rds}}
 
* {{aws rds}}
 +
* {{Terraform RDS}}
  
 
[[Category:AWS]]
 
[[Category:AWS]]

Latest revision as of 11:29, 28 December 2022

https://awscli.amazonaws.com/v2/documentation/api/latest/reference/rds/describe-db-instances.html


Replication[edit]

Storage data[edit]

arn:aws:rds:eu-central-1:4523523466:db:my_branches_name	postgres  my_branches_name	available

Version:

  • aws rds describe-db-instances | egrep -w "EngineVersion|DBInstanceIdentifier"

Example Output[edit]

{
    "DBInstances": [
        {
            "DBInstanceIdentifier": "mydbinstancecf",
            "DBInstanceClass": "db.t3.small",
            "Engine": "mysql",
            "DBInstanceStatus": "available",
            "MasterUsername": "masterawsuser",
            "Endpoint": {
                "Address": "mydbinstancecf.abcexample.us-east-1.rds.amazonaws.com",
                "Port": 3306,
                "HostedZoneId": "Z2R2ITUGPM61AM"
            },
            ...some output truncated...
        }
    ]
}
  • Engine: mysql, postgres

Related terms[edit]

See also[edit]

Advertising: