Created
July 7, 2018 21:46
-
-
Save albarki/3588354ef11a137e199e29381fb07de1 to your computer and use it in GitHub Desktop.
Get List of RDS instances from All regions
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for region in `aws ec2 describe-regions --output text | cut -f3` | |
do | |
echo -e "\nListing RDS in region:'$region'..." | |
aws rds describe-db-instances \ | |
--region $region \ | |
--query 'DBInstances[*].[DBInstanceIdentifier,ReadReplicaDBInstanceIdentifiers]' | |
done |
Is there a script (sql) to list all db on rds instane
for region in `aws ec2 describe-regions --output text | cut -f4`
do
echo -e "\nListing RDS in region:'$region'..."
aws rds describe-db-instances \
--region $region \
--query 'DBInstances[*].[DBInstanceIdentifier,ReadReplicaDBInstanceIdentifiers]' --output text | cat
done
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks for the script. I had to cut it to column 4