I am not able to login with AWS ec2 Bitnami instance.
I have created new keypair for the ec2-instance and i have converted the keypair into ppk with the puttygen.
I have tried to use the login with the different user name like bitnami, ec2-user, ubuntu, root but i cant get any success i have read many blogs amazon document, bitnami document but and apply there that process but still not get success.
I have created new user group and provided access for the ssh, http, https with there defult port.
Server Details.
Instance type : m1.small
Description : https://bitnami.com
Status : available
Platform : Ubuntu
Image Size : 10GB
Visibility : Public
bitnami-magento-1.9.0.1-0-linux-ubuntu-12.04.4-x86_64-ebs
Whenever i am trying to login with the ssh i get the error message.
Disconnected: No supported authentication methods available (server sent: publickey)
Help is very much appreciated.
Thanks
This looks like your public key file is got some issue. I am guessing it should be the puTTY bug which requires an extra newline character at the end of the key file.
When creating the public key, open it in puTTYgen and copy and paste (this will make the key to be formatted in one line along with a newline) it to your authorized_keys and try to login.
For more information, read a similar question
Related
My secretary created a new instance in Amazon using their EC2 server but lost the .pem file. Doing research online I was able to go to the instance system settings/get system log and retrieve some type of password there. The instance system log shows something like this:
2019/04/15 12:15:19Z: Username: Username
2019/04/15 12:15:19Z: Password: <Password>
It is a very long code of random characters.
Is there any way I can use this to log in via remote desktop or is there a way to decrypt it? I tried several decryption methods online and they said this was not a valid "hash"...whatever this means. I am not a technical person so I need hopefully a response in layman terms.
It appears that you are connecting to a Windows instance. When a new Amazon EC2 Windows instance is launched, a program on the AMI (disk image) automatically generates a random Administrator password. This is done so that you can access the instance, but nobody else can.
To keep the password secret, the program encrypts the password with the keypair nominated when the instance was launched. The encrypted password is passed back to AWS via the console. That is the string of 'random characters' you saw.
To decrypt the password, you can use the Get Windows Password feature, which requires you to supply the nominated keypair. It will then decrypt the password, which can be used to login to the instance as Administrator.
Since you no longer have the keypair, you cannot decrypt the password and therefore cannot login to the server. This is good! This proves that security works, because you would not want other people to be able to login to the server.
So, can do you regain access?
Refer to the steps on: I need to reset the administrator password on a Windows Server instance in Amazon EC2
Basically, there are two methods:
If Systems Manager is enabled for the instance, you can run a "rescue" script
Otherwise, there is a series of scripts that assist with the process of:
Detaching the disk
Attaching it to another instance
Resetting a configuration on the disk
Reattaching the disk to the original instance
The second process is a bit like plugging a USB disk into another computer to change a file (except that EC2 disks are managed differently).
I have an EC2 server on AWS. I created a key pair upon first time connecting to the server (following whatever default steps on the console).
Now I want to login to the same server from a different machine. What is the best way to do so? Do I have to email my public key to the other machine?
I tried to create more key pairs on the AWS console, but can't figure out to additional key pairs to the server. Is that even possible?
Update:
This is not a duplicate question. My goal is not to associate two key pairs with one server. I am trying to find a way to login to a server from a different computer, whether to use the same key pair, another key pair or even a different user.
When an Amazon EC2 instance is launched from an Amazon Linux AMI (and several other Linux AMIs, too), the public half of the keypair selected at launched will automatically be copied to:
/home/users/ec2-user/.ssh/authorized_keys
When you later attempt to login to the ec2-user by providing the private half of the keypair, the two halves will be compared and, if they match, you will be permitted to login as that user.
You can allow another person to login to the ec2-user by either:
Giving them the same private keypair (bad for security), OR
By creating a keypair for them (via ssh-keygen) and adding the public half of that keypair to the above file
Alternatively, you could create a new user on the machine for them, then add the keypair to the above file within their user directory.
See: Add New User Accounts with SSH Access to a Linux Instance
So, to login to that EC2 instance from a different computer, you will need the private keypair on that different computer. It's just like a password.
Or, you could create a new keypair on that computer and copy the public keypair to the authorized_keys file on the target instance.
All of this is really Linux stuff, rather than something specific to Amazon EC2.
It is not possible to create multiple key pairs for an ec2 server; however you can create multiple users and through that give access.
Id advice creating multiple users and giving access via ssh with key authentication. I have included a link below with the walkthrough.
With that being said you Create a new user, then
allocate permissions and privileges. Next you generate a key - certificate. And finally, you associate the certificate to the user.
https://debian-administration.org/article/530/SSH_with_authentication_key_instead_of_password
Can someone help me fix this issue. I am connected few hours before but then when I tried to rename a folder using Putty I got disconnected and got this error.
Error: Disconnected: No supported authentication methods available (server sent: publickey)
I've tried the following solutions I got from the net.
- Re-gen private key
- Convert .pem to .ppk
- Move .ppk to other folder that all user has permission
- Use the ff username user,root,bitnami,ec2-user
- I tried it in Cyberduck, Winscp, filezilla, Putty
Thank you I hope someone can help me.
bitnami developer here.
Depending on which platform you are working you could download again the .pem file in order to connect to your server.
If you are working on any of our launchpads (https://aws.bitnami.com/, https://google.bitnami.com/, etc.) you have the option
to download you .pem key, so it's not necessary to regenerate the key.
On the other hand, if you are working on the amazon ec2 console and you did not download the private key pair of your server in the moment of the creation of the machine you won't be able to connect to it again unless you create another machine.
In order to reconnect to the server you should download again the key files and use it with putty/filezilla/etc. Make sure you put the correct ip of the server or you won't have access to it.
I have AWS EC2 instance. I am using filezilla 3.8.0 but I cannot connect instance, filezilla doesnt accept account type normal and asking password. When I type user name ubunbu and password blank I received following message:
Disconnected: No supported authentication methods available (server sent: publickey)
I inserted pem key and converted ppk key also. My staff can connect but I cant. What is wrong?
Thanks
It happens in AWS EC2. As EC2 provide Connection through an SFTP need some other methods.
Firstly the CONNECTION will be in FTP as default. Need to change to SFTP.
Then instead of directly giving host name and password, it must be done in Site manager. Step by step procedure given below:
So the steps for troubleshooting:
Go to Filezilla's Settings
SFTP
Add Key File (Give the ppk converted key file or FZ will convert the pem ket)
Then take File in Filezilla
Go to
File
Site Manager
New Site
Give any name (ec2-amazon)
In General, give host name 'Public DNS' (eg: ec2-34-423.ap-southeast...)
Change the Protocol to SFTP
Logon Type: Normal
User : ec2-user or ubuntu - depends
Clear Password
Connect!
Hope you will be connected. Happy Hosting...:)
More specifically here's a screenshot of the dialog where you are supposed to add your ssh private key.
Try the following configuration in filezilla,
set Logon type = Interactive,Protocal = SFTP, and attach keyfile to filezilla SFTP setting from MenuBar -> Edit -> Settings ->SFTP -> Add Key File.
Hope this helps.
I was facing the same problem-
I follow up #Amith Ajith answer but found my setting was as it, is.
I choose a file as privatekey.pem which i generated.
Change "Transfer setting" as active
it worked for me.
I have followed Amazon instructions to the letter and it does not work.
ec2-api-tools-1.3-34128 - this is the api tools that I got from Amazon
Set it up following instructions. Checked everything to make sure I follow instructions. When I try to use it, I only get: "invalid.blabla" depending on what command do I try to use.
Anybody with this problem?
I deleted all my instances and all key pairs.
Created new ones (instance and key pair).
Setup putty all over again like instructions say I should do
(creating .ppk file and everything).
Still the problem remains.
When I try to connect to my ec2 instance using putty
I get "login as : " ????????
Also, I am using windows vista.
Is this a problem.
Thanks
Had this same problem. I found that in putty I had to do three things (only 2 of which are mentioned in the amazon guide at http://docs.amazonwebservices.com/AmazonEC2/gsg/2007-01-19/putty.html)
provide the converted private key in the ssh -> Auth section
provide the dns name or IP
go to Connection -> Data and enter "ec2-user" as the Auto-login username
Hope this saves someone else 20 mins!
Did you make sure that you put "root" as the auto-login account in the "Data" section?
A mistake I made than gave me the same error message was setting
"root#ec2-.eu-west-1.compute.amazonaws.com" as the value in the "Host Name (or IP Address)" field in putty.
You need to specify "ubuntu#ec2-.eu-west-1.compute.amazonaws.com".