Connect to the server using SSH
Obtain SSH credentials
What SSH username should I use for secure shell access to my application?
SSH username: bitnami
Obtain SSH credentials from the AWS Console
If you are using the AWS console, you have either created and downloaded an SSH key pair or uploaded one the first time you deployed a server. Check the following sections to know where the SSH keys can be created or uploaded on the AWS console:
-
Log in to the AWS Cloud Console.
-
Select the “Compute -> EC2” option.
-
If required, use the region selector in the top right corner to switch to the region where your instance was launched.
-
In the left navigation bar, click the “Network & Security -> Key Pairs” menu item.
-
In the resulting page, you will see a list of the Key Pairs that are already uploaded to the console and available to use when launching an instance.
From this screen you can also create a new Key Pair that you can download later:
Or import one from your computer:
NOTE: If you did not associate a key pair with your AWS server, you will not be able to log in to it. In this case, contact AWS support and follow their instructions to gain SSH access to your server.
Obtain SSH credentials from Amazon Lightsail
Amazon Lightsail provides a default SSH key pair for connecting to your instance that you can download at any time. Optionally, you can change this during the deployment process. To do so:
-
Log in to Amazon Lightsail.
-
Click “Create instance” to launch a new server.
-
In the “Create an instance” resulting screen, scroll down until the “OPTIONAL -> Change SSH key pair” section.
Click on the link to see the “SSH key pair manager”:
-
Click “Create New” to create a new SSH key pair for your new server:
Enter a name for your new SSH key and click “Generate key pair”:
Or
-
Click “Upload New” to upload an existing SSH key pair from your computer:
Connect through a browser
Connect through a browser from Amazon Lightsail
If you are using Amazon Lightsail, it is possible to connect to your instance through SSH directly from your browser. Follow these instructions:
-
From the Amazon Lightsail dashboard, in the “Instances” section, select the instance you would like to connect.
-
Click the terminal icon you will see in the right corner of the instance.
Or
In both cases, it will open a terminal in a new tab.
Connect with an SSH client
TIP: Refer to these instructions to learn how to obtain your SSH credentials.
Connect with an SSH client on Windows using an SSH key
Watch the following video to learn how to easily connect to the server on Windows:
In order to access your server via SSH tunnel you need an SSH client. In the instructions below we have selected PuTTY, a free SSH client for Windows and UNIX platforms. To access the server via SSH tunnel using PuTTY on a specific port using an SSH tunnel, you need to have it configured in order to allow connections to your server.
-
Step 1: Obtain PuTTY
- Download the PuTTY ZIP archive from its website.
- Extract the contents to a folder on your desktop.
- Double-click the putty.exe file to bring up the PuTTY configuration window.
-
Step 2: Convert your PEM private key to PPK format (optional)
If your private key is in .pem format, it is necessary to convert it to PuTTY’s own .ppk format before you can use it with PuTTY. If your private key is already in .ppk format, you may skip this step.
Follow the steps below to convert your .pem private key to .ppk format:
-
Launch the PuTTY Key Generator by double-clicking the puttygen.exe file in the PuTTY installation directory.
-
Click the “Load” button and select the private key file in .pem format.
-
Once the private key has been imported, click the “Save private key” button to convert and save the key in PuTTY’s .ppk key file format.
-
-
Step 3: Configure PuTTY
-
Double-click the putty.exe file to bring up the PuTTY configuration window.
-
In the PuTTY configuration window, enter the host name or public IP address of your server into the “Host Name (or IP address)” field, as well as into the “Saved Sessions” field. Then, click “Save” to save the new session so you can reuse it later.
-
Obtain your SSH credentials in order to allow the authentication against the server. Refer to the FAQ to learn how to obtain your SSH credentials for your client.
-
In the “Connection -> SSH -> Auth” section, browse to the private key file (.ppk) you’ve previously obtained in the step above.
-
In the “Connection -> Data” section, enter the username bitnami into the “Auto-login username” field, under the “Login details” section.
-
In the “Session” section, click on the “Save” button to save the current configuration.
-
Select the session you want to start (in case that you have saved more than one session) and click the “Open” button to open an SSH session to the server.
PuTTY will first ask you to confirm the server’s host key and add it to the cache. Go ahead and click “Yes” to this request (learn more).
-
You should now be logged in to your server. Here is an example of what you’ll see:
TIP: In case of difficulties using PuTTY, refer to the official documentation for troubleshooting advice and resolution for common error messages.
Connect with an SSH client on Linux and Mac OS X using an SSH key
Linux and Mac OS X come bundled with SSH clients by default. In order to log in to your server, follow the steps below:
-
Open a new terminal window on your local system (for example, using “Finder -> Applications -> Utilities -> Terminal” in Mac OS X or the Dash in Ubuntu).
-
Set the permissions for your private key file (.pem) to 600 using a command like the one below. Refer to the FAQ to learn how to obtain your SSH credentials.
$ chmod 600 KEYFILE
-
Connect to the server using the following command:
$ ssh -i KEYFILE bitnami@SERVER-IP
Remember to replace KEYFILE in the previous commands with the path to your private key file (.pem), and SERVER-IP with the public IP address or hostname of your server.
-
Your SSH client might ask you to confirm the server’s host key and add it to the cache before connecting. Accept this request by typing or selecting “Yes” (learn more).
You should now be logged in to your server. Here is an example of what you’ll see: