Linux command
aws-redshift 命令
文本
复制后可按需替换文件名、目录或参数。
常用示例
List all clusters
aws redshift describe-clusters
Describe a specific cluster
aws redshift describe-clusters --cluster-identifier [cluster_name]
Create a new cluster
aws redshift create-cluster --cluster-identifier [cluster_name] --node-type dc2.large --master-username [admin] --master-user-password [password] --number-of-nodes [2]
Create a single-node cluster
aws redshift create-cluster --cluster-identifier [cluster_name] --node-type dc2.large --master-username [admin] --master-user-password [password] --cluster-type single-node
Resize a cluster
aws redshift resize-cluster --cluster-identifier [cluster_name] --cluster-type multi-node --node-type ra3.xlplus --number-of-nodes [4]
Create a snapshot
aws redshift create-cluster-snapshot --cluster-identifier [cluster_name] --snapshot-identifier [snapshot_name]
Delete a cluster
aws redshift delete-cluster --cluster-identifier [cluster_name] --skip-final-cluster-snapshot
Pause a cluster
aws redshift pause-cluster --cluster-identifier [cluster_name]
说明
aws redshift is a subcommand of the AWS CLI that manages Amazon Redshift, a fully managed petabyte-scale data warehouse service. Redshift uses columnar storage and parallel query execution for fast analytics on large datasets. Clusters consist of leader and compute nodes. The leader node manages connections and query planning, while compute nodes store data and execute queries. Redshift supports SQL queries through standard PostgreSQL drivers. Redshift Serverless provides a pay-per-use option without managing clusters. Data can be loaded from S3, DynamoDB, EMR, or streamed via Firehose.
参数
- describe-clusters
- List clusters and their details.
- create-cluster
- Launch a new cluster.
- delete-cluster
- Terminate a cluster.
- modify-cluster
- Change cluster settings.
- resize-cluster
- Change node type or count.
- pause-cluster
- Pause a cluster to stop billing.
- resume-cluster
- Resume a paused cluster.
- reboot-cluster
- Restart a cluster.
- create-cluster-snapshot
- Create a manual snapshot.
- restore-from-cluster-snapshot
- Create cluster from snapshot.
- describe-cluster-snapshots
- List snapshots.
- --cluster-identifier _name_
- Unique cluster name.
- --node-type _type_
- Instance type (dc2.large, ra3.xlplus, etc.).
- --number-of-nodes _count_
- Number of compute nodes.
- --cluster-type _type_
- single-node or multi-node.
- --master-username _name_
- Admin username.
- --master-user-password _password_
- Admin password.
- --db-name _name_
- Default database name.
FAQ
What is the aws-redshift command used for?
aws redshift is a subcommand of the AWS CLI that manages Amazon Redshift, a fully managed petabyte-scale data warehouse service. Redshift uses columnar storage and parallel query execution for fast analytics on large datasets. Clusters consist of leader and compute nodes. The leader node manages connections and query planning, while compute nodes store data and execute queries. Redshift supports SQL queries through standard PostgreSQL drivers. Redshift Serverless provides a pay-per-use option without managing clusters. Data can be loaded from S3, DynamoDB, EMR, or streamed via Firehose.
How do I run a basic aws-redshift example?
Run `aws redshift describe-clusters` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does describe-clusters do in aws-redshift?
List clusters and their details.