• 沒有找到結果。

Creating a cluster

在文檔中 Amazon Redshift (頁 79-89)

Creating a cluster

Before you create a cluster, read Overview of Amazon Redshift clusters (p. 31) and Clusters and nodes in Amazon Redshift (p. 31).

NoteA new console is available for Amazon Redshift. Choose either the New console or the Original console instructions based on the console that you are using. The New console instructions are open by default.

New console

One way to learn about creating a cluster is to create a cluster using the console.

To create a cluster

1. Sign in to the AWS Management Console and open the Amazon Redshift console at https://

console.aws.amazon.com/redshift/.

2. On the navigation menu, choose CLUSTERS. The clusters for your account in the current AWS Region are listed. A subset of properties of each cluster is displayed in columns in the list.

3. Choose Create cluster to create a cluster.

4. Follow the instructions on the console page to enter the properties for Cluster configuration.

Choose one of the following methods to size your cluster:

Note

The following step describes an Amazon Redshift console that is running in an AWS Region that supports RA3 node types. For a list of AWS Regions that support RA3 node types, see Overview of RA3 node types in the Amazon Redshift Cluster Management Guide.

• If your AWS Region supports RA3 node types, choose either Production or Free trial to answer the question What are you planning to use this cluster for?

If your organization is eligible, you might be able to create a cluster under the Amazon Redshift free trial program. To do this, choose Free trial to create a configuration with the dc2.large node type. For more information about choosing a free trial, see Amazon Redshift free trial.

• If you don't know how large to size your cluster, choose Help me choose. Doing this starts a sizing calculator that asks you questions about the size and query characteristics of the data that you plan to store in your data warehouse.

If you know the required size of your cluster (that is, the node type and number of nodes), choose I'll choose. Then choose the Node type and number of Nodes to size your cluster for the proof of concept.

5. Follow the instructions on the console page to enter the properties for Cluster details.

NoteIf you are behind a firewall, the database port must be an open port that accepts inbound connections.

6. (Optional) Follow the instructions on the console page to enter properties for Cluster permissions.

Provide cluster permissions if your cluster needs to access other AWS services for you, for example to load data from Amazon S3.

7. Choose Create cluster to create the cluster. The cluster might take several minutes to be ready to use.

Creating a cluster

Additional configurations

When you create a cluster, you can specify additional properties to customize it. You can find more details about some of these properties in the following list.

Virtual private cloud (VPC)

Choose a VPC that has a subnet group. After the cluster is created, the subnet group can't be changed.

Parameter groups

Choose a cluster parameter group to associate with the cluster. If you don't choose one, the cluster uses the default parameter group.

Encryption

Choose whether you want to encrypt all data within the cluster and its snapshots. If you leave the default setting, None, encryption is not enabled. If you want to enable encryption, choose whether you want to use AWS Key Management Service (AWS KMS) or a hardware security module (HSM), and then configure the related settings. For more information about encryption in Amazon Redshift, see Amazon Redshift database encryption (p. 367).

KMS

Choose Use AWS Key Management Service (AWS KMS) if you want to enable encryption and use AWS KMS to manage your encryption key. Also, choose the key to use. You can choose a default key, a key from the current account, or a key from a different account.

NoteIf you want to use a key from another AWS account, then enter the Amazon Resource Name (ARN) for the key to use. You must have permission to use the key. For more information about access to keys in AWS KMS, see Controlling access to your keys in the AWS Key Management Service Developer Guide.

For more information about using AWS KMS encryption keys in Amazon Redshift, see Database encryption for Amazon Redshift using AWS KMS (p. 368).

HSM

Choose HSM if you want to enable encryption and use a hardware security module (HSM) to manage your encryption key.

If you choose HSM, choose values from HSM Connection and HSM Client Certificate. These values are required for Amazon Redshift and the HSM to form a trusted connection over which the cluster key can be passed. The HSM connection and client certificate must be set up in Amazon Redshift before you launch a cluster. For more information about setting up HSM connections and client certificates, see Encryption for Amazon Redshift using hardware security modules (p. 370).

Maintenance track

You can choose whether the cluster version used is the Current, Trailing, or sometimes Preview track.

Monitoring

You can choose whether to create CloudWatch alarms.

Configure cross-region snapshot

You can choose whether to enable cross-Region snapshots.

Original console

You can create a cluster in the AWS Management Console in two ways:

Creating a cluster

• If you're new to Amazon Redshift or just need a basic cluster, use Quick launch cluster. With this approach, you specify only the node type, number of nodes, user name, password, and AWS Identity and Access Management (IAM) role to use for access. For more information, see Creating a cluster by using quick launch cluster (p. 74).

• If you're an existing user or want to customize your cluster, use Launch cluster. For example, use Launch cluster to use a specific virtual private cloud (VPC) or encrypt data in your cluster. For more information, see Creating a cluster by using a launch cluster (p. 74).

Creating a cluster by using quick launch cluster

If you're new to Amazon Redshift or just need a basic cluster, use this streamlined approach. If you're an existing user or want to customize your cluster, see Creating a cluster by using a launch cluster (p. 74).

To create a cluster by using a quick launch cluster

1. Sign in to the AWS Management Console and open the Amazon Redshift console at https://

console.aws.amazon.com/redshift/.

Important

If you use IAM user credentials, make sure that the user has the necessary permissions to perform the cluster operations. For more information, see Controlling access to IAM users in the Amazon Redshift Cluster Management Guide.

2. Choose the AWS Region where you want to create the cluster, for example US West (Oregon).

3. On the Amazon Redshift dashboard, choose Quick launch cluster.

4. On the Cluster specifications page, enter the following values and then choose Launch cluster:

Node type: Choose dc2.large.

Number of compute nodes: Keep the default value of 2.

Master user name: Keep the default value of awsuser.

Master user password and Confirm password: Enter a password for the master user account.

Database port: Accept the default value of 5439.

Available IAM roles: Choose myRedshiftRole.

A confirmation page appears. The cluster takes a few minutes to be created. Choose Close to return to the list of clusters.

5. On the Clusters page, choose the cluster that you just launched and review the Cluster Status information. Make sure that Cluster Status is available and Database Health is healthy before you try to connect to the database.

Creating a cluster by using a launch cluster

If you're an existing Amazon Redshift user or want to customize your cluster, use the following procedure to launch your cluster. If you're new to Amazon Redshift or just need a basic cluster, see Creating a cluster by using quick launch cluster (p. 74).

Creating a cluster

To create a cluster by using a launch cluster

1. Sign in to the AWS Management Console and open the Amazon Redshift console at https://

console.aws.amazon.com/redshift/.

2. Choose Launch Cluster.

3. On the Cluster Details page, specify values for the following options, and then choose Continue.

Cluster Identifier

Type a unique name for your cluster.

Cluster identifiers must meet the following conditions:

• They must contain 1–63 alphanumeric characters or hyphens.

• Alphabetic characters must be lowercase.

• The first character must be a letter.

• They can't end with a hyphen or contain two consecutive hyphens.

• They must be unique for all clusters within an AWS account.

Database Name

Type a name if you want to create a database with a custom name (for example, mydb). This field is optional. A default database named dev is created for the cluster whether or not you specify a custom database name.

Database names must meet the following conditions:

• They must contain 1–64 alphanumeric characters.

• They must contain only lowercase letters.

• A database name can't be a reserved word. For more information, see Reserved Words in the Amazon Redshift Database Developer Guide.

Database Port

Type a port number through which you plan to connect from client applications to the database.

The port number must be included in the connection string when opening JDBC or ODBC connections to the databases in the cluster.

The port number must meet the following conditions:

• It must contain only numeric characters.

• It must fall in the range 1150–65535. The default port is 5439.

• It must specify an open port that accepts inbound connections, if you are behind a firewall.

Master User Name

Type an account name for the master user of the database.

Master user names must meet the following conditions:

• They must contain 1–128 alphanumeric characters.

• The first character must be a letter.

• A master user name can't be a reserved word. For more information, see Reserved Words in the Amazon Redshift Database Developer Guide.

Master User Password and Confirm Password

Type a password for the master user account, and then retype it to confirm the password.

Creating a cluster

In the following screenshot, examplecluster is the cluster identifier, no custom database name is specified, 5439 is the port, and masteruser is the master user name.

4. On the Node Configuration page, specify values for the following options, and then choose Continue.

Node Type

Choose a node type. When you choose a node type, the page displays information that corresponds to the selected node type, such as CPU, Memory, Storage, and I/O Performance.

Cluster Type

Choose a cluster type. When you do, the maximum number of compute nodes for the selected node and cluster type appears for Maximum, and the minimum number appears for Minimum.

If you choose Single Node, you have one node that shares leader and compute functionality.

If you choose Multi Node, specify the number of compute nodes that you want for the cluster in Number of Compute Nodes.

In the following screenshot, the dc1.large node type is selected for a Multi Node cluster with two compute nodes.

Creating a cluster

5. On the Additional Configuration page, specify values for the following options, and then choose Continue.

a. For Provide the optional additional configuration details below, configure the following options:

Cluster Parameter Group

Choose a cluster parameter group to associate with the cluster. If you don't choose one, the cluster uses the default parameter group.

Encrypt Database

Choose whether you want to encrypt all data within the cluster and its snapshots. If you leave the default setting, None, encryption is not enabled. If you want to enable encryption, choose whether you want to use AWS Key Management Service (AWS KMS) or a hardware security module (HSM), and then configure the related settings. For more information about encryption in Amazon Redshift, see Amazon Redshift database encryption (p. 367).

KMS

Choose KMS if you want to enable encryption and use AWS KMS to manage your encryption key. In Master Key, choose (default) aws/redshift to use a default customer managed key or choose another key from your AWS account.

NoteIf you want to use a key from another AWS account, choose Enter a key ARN from Master Key. Then type the Amazon Resource Name (ARN) for the key to use. You must have permission to use the key. For more information about access to keys in AWS KMS, see Controlling access to your keys in the AWS Key Management Service Developer Guide.

For more information about using AWS KMS encryption keys in Amazon Redshift, see Database encryption for Amazon Redshift using AWS KMS (p. 368).

HSM

Choose HSM if you want to enable encryption and use a hardware security module (HSM) to manage your encryption key.

If you choose HSM, choose values from HSM Connection and HSM Client Certificate.

These values are required for Amazon Redshift and the HSM to form a trusted connection over which the cluster key can be passed. The HSM connection and client certificate must be set up in Amazon Redshift before you launch a cluster. For more information about setting up HSM connections and client certificates, see Encryption for Amazon Redshift using hardware security modules (p. 370).

Creating a cluster

b. For Configure Networking Options, you configure whether to launch your cluster in a virtual private cloud (VPC) or outside a VPC. The option you choose affects the additional options available in this section. Amazon Redshift uses the EC2-VPC and EC2-Classic platforms to launch clusters. Your AWS account determines which platform or platforms are available to you for your cluster. For more information, see Supported platforms in the Amazon EC2 User Guide for Linux Instances.

Choose a VPC

• To launch your cluster in a virtual private cloud (VPC), choose the VPC you want to use.

You must have at least one Amazon Redshift subnet group set up to use VPCs. For more information, see Amazon Redshift cluster subnet groups (p. 102).

• To launch your cluster outside a VPC, choose Not in VPC. This option is available only to AWS accounts that support the EC2-Classic platform. Otherwise, you must launch your cluster in a VPC.

Cluster Subnet Group

Select the Amazon Redshift subnet group in which to launch the cluster.

Note

This option is available only for clusters in a VPC.

Publicly Accessible

Choose Yes to enable connections to the cluster from outside of the VPC in which you launch the cluster. Choose No if you want to limit connections to the cluster from only within the VPC.

Note

This option is available only for clusters in a VPC.

Choose a Public IP Address

If you set Publicly Accessible to Yes, choose No here to have Amazon Redshift to provide an Elastic IP (EIP) for the cluster. Alternatively, choose Yes if you want to use an EIP that you have created and manage. If you have Amazon Redshift create the EIP, it is managed by Amazon Redshift.

Creating a cluster

NoteThis option is available only for clusters in a VPC where Publicly accessible is Enabled.

Elastic IP

Select the EIP that you want to use to connect to the cluster from outside of the VPC.

NoteThis option is available only for clusters in a VPC where Publicly Accessible and Choose a Public IP Address are Yes.

Availability Zone

Choose No Preference to have Amazon Redshift choose the Availability Zone that the cluster is created in. Otherwise, choose a specific Availability Zone.

Enhanced VPC Routing

Choose Yes to enable enhanced VPC routing. Enhanced VPC routing might require some additional configuration. For more information, see Enhanced VPC routing in Amazon Redshift (p. 289).

c. For Optionally, associate your cluster with one or more security groups, specify values for the following options:

VPC Security Groups

Choose a VPC security group or groups for the cluster. By default, the chosen security group is the default VPC security group. For more information about VPC security groups, see Security groups for your VPC in the Amazon VPC User Guide.

NoteThis option is only available if you launch your cluster in the EC2-VPC platform.

Cluster Security Groups

Choose an Amazon Redshift security group or groups for the cluster. By default, the chosen security group is the default security group. For more information about cluster security groups, see Amazon Redshift cluster security groups (p. 490).

NoteThis option is only available if you launch your cluster in the EC2-Classic platform.

d. For Optionally create a basic alarm for this cluster, configure the following options, and then choose Continue:

Create CloudWatch Alarm

Choose Yes if you want to create an alarm that monitors the disk usage of your cluster, and then specify values for the corresponding options. Choose No if you don't want to create an alarm.

Creating a cluster

Disk Usage Threshold

Choose a percentage of average disk usage that has been reached or exceeded at which the alarm should trigger.

Use Existing Topic

Choose No if you want to create a new Amazon Simple Notification Service (Amazon SNS) topic for this alarm. In the Topic box, edit the default name if necessary. For Recipients, type the email addresses for any recipients who should receive the notification when the alarm triggers.

Choose Yes if you want to choose an existing Amazon SNS topic for this alarm, and then in the Topic list, choose the topic that you want to use.

e. For Optionally, select your maintenance track for this cluster, choose Current or Trailing.

If you choose Current, your cluster is updated with the latest approved release during your maintenance window. If you choose Trailing, your cluster is updated with the release that was approved previously.

6. On the Review page, review the details of the cluster. If everything is satisfactory, choose Launch Cluster to start the creation process. Otherwise, choose Back to make any necessary changes, and then choose Continue to return to the Review page.

NoteSome cluster properties, such as the values for Database Port and Master User Name, cannot be modified later. If you need to change them, choose Back to change them now.

The following screenshot shows a summary of various options chosen during the cluster launch process.

Creating a cluster

7. After you initiate the creation process, choose Close. The cluster might take several minutes to be ready to use.

You can monitor the status of the operation in the performance dashboard.

在文檔中 Amazon Redshift (頁 79-89)