|« PreviousNext »|
|Did this page help you? Yes | No | Tell us about it...|
Once Amazon RDS provisions your DB Instance, you can use any standard SQL client application to connect to the instance. In this example, you connect to a DB Instance running the Microsoft SQL Server database engine using the Microsoft SQL Server command line tools. For information on connecting to a Microsoft SQL Server DB Instance using SSL, see Using SSL with a SQL Server DB Instance. For more information on using Microsoft SQL Server, go to the Microsoft SQL Server website.
This example uses the Microsoft SQL Server Management Studio utility. This utility is part of the Microsoft SQL Server software distribution. To download a stand-alone version of this utility, go to the Microsoft Download Center - Microsoft SQL Server Management Studio Express.
To connect to a DB Instance using Microsoft SQL Server Management Studio
Find the DNS name for your DB Instance
On the My DB Instances page of the AWS Management Console, select the check box next to the DB instance running the Microsoft SQL Server database engine. In the Description tab of the lower panel, note the endpoint and port of the DB instance.
To find the DNS name using the "new look" RDS console UI.
On the DB instances page of the AWS Management Console, select the arrow in the line for the DB instance running the Microsoft SQL Server database engine.
In the Summary information, note the endpoint of the DB instance to use in the next step.
Run Microsoft SQL Server Management Studio.
The Connect to Server dialog box appears.
In the Server type: drop-down list box, select
In the Server name: text field, enter or paste the
endpoint of the DB instance running the Microsoft SQL Server database engine.
Replace the colon separating the port number with a comma. For example, the
Server name could be:
From the Authentication drop-down list box, select
SQL Server Authentication.
Enter the master user name for the DB instance in the Login: text box.
Enter the password for the master user in the Password: text box.
Click the Connect button.
After a few moments, Microsoft SQL Server Management Studio should be connected to your DB instance.
Click the New Query button at the top left of the SQL Server Management Studio window.
A new SQL Query window will open.
Type the following SQL query:
Click the ! Execute button on the SQL Enterprise Manager toolbar to run the query.
You should see a version string returned from your Microsoft SQL Server DB instance displayed in the output window.
There are two common causes for problems if you are having problems connecting to a SQL Server DB instance: the access rules enforced by your firewall and the IP addresses you authorized to access the DB instance in the DB security group (or VPC security group if your DB instance is inside a VPC). If you used Microsoft SQL Server Management Studio and you followed the settings specified in the steps above and you are unable to connect, the problem is most likely the egress or ingress rules on your firewall. If you cannot send out or receive communications over the port you specified when you created the DB instance, you will not be able to connect to the DB instance. Check with your network administrator to determine if the port you specified for your DB instance is allowed to be used for inbound and outbound communication.
Here are a few things to check if you know that you can send and receive communications through your firewall for the port you specified when you created the DB instance.
Could not open a connection to SQL Server - Microsoft SQL
Server, Error: 53 - You must include the port number when you
specify the Server Name when using Microsoft SQL Server Management Studio. For
example, the server name for a DB instance (including the port number) could be:
No connection could be made because the target machine actively refused it - Microsoft SQL Server, Error: 10061 - You were able to reach the DB instance but the connection was refused. This is often caused by the user name or password being incorrect.