So until now I have setup everything for deploying rails project to my ec2 centos instance.
while doing some stuff I did the following changes in
etc/ssh/sshd_config
PubkeyAuthentication yes
PasswordAuthentication yes
#PubkeyAuthentication yes
#PasswordAuthentication yes
and unfortunately at same time logged out from the server.
and this is the moment when I realized how stupid I am.
while attempting to ssh into server, it says
Permission denied (publickey,gssapi-keyex,gssapi-with-mic)
anyone please advise any other possible way to solve this problem.
also I hear about following stuff.
stopping the ec2 instance
detach its volume
attach it to new instance (created in the same zone)
do correct the stupidity
attach the volume again to original instance
But Unluckily I have limited permissions to my account at aws consloe right now.
Related
I'm trying to setup Realm Object Server on Amazon EC2.
I've used the public AMI on North Virginia, and I have a running instance. I'm doing all this from Europe as most of my users are in the USA.
Now I'm trying to access ec2-xx-xx-xx-xx.compute-1.amazonaws.com:9080.
I've tried to open the different ports as indicated but I feel that what I've done is incorrect.
I've also tried to open all traffic but I still have a timeout on the page. I'm probably doing something wrong here, I'm not sure what.
Thanks for your help!
Thanks for trying out our AWS AMI! It would be helpful to know the AMI ID that you ran, as that can help us track down problems for others. In fact, we've released new AMIs this morning. Check our website for the latest available AMI IDs.
In the meantime, can you check if the realm-object-server service is running? You can check this via SSH and by running:
sudo service realm-object-server status
So I managed to make things work!
I guess my issue is that I was somehow on the wrong security group.
When looking at your running instances, be sure to hit your security group at the right of the instance row, in order to be able to configure the correct one.
Then, configure a Custom TCP Rule with port 9080.
That's it!
I set the permission of the root folder to 7777. From that point, I was not able to connect to it using putty/ssh by making use of the .ppk/.pem file. Previously, I was able to connect. But after this particular action, I am not able to connect.
Can someone tell me how to solve of this issue?
Here is an example of screw up your linux EC2 and remount it from another instance to fix it.
https://aws.amazon.com/articles/5213606968661598
Why toy with the sticky bit?
I have Apache server running on Centos5.4 Ec2 instance. Unfortunately while removing Bash from Centos, it also removed basic shared libraries.
Now afterward I can't SSH to that EC2 instance but Apache server is still running (I can access my site through URL).
Any idea how can I get the SSH access back? or can repair Centos Ec2 instance?
Thanks!
You can always contact the AWS support directly. They are very accommodating. send a message to them and they will recover your access, if it is doable from their end.
You may call, or you may send a message from your AWS account.
I added a bad script in startup script, turned out this script is blocking and hence ubuntu instance can't boot up to ssh server and I can't ssh into it. Is there a way for me to go to the server console (like from VGA port)? like go to single-user mode or safe mode and fix it?
Thanks in advance.
I don't know of any way to obtain server console access or change boot modes on the EC2 instances...
I had the same issue sometime ago, and I ended up creating a temporary EC2 instance, mounting the root device from the original (failing) EC2 there, modifying the files, then reattaching the device and destroying the temporary instance. Note: you may end up paying more depending on which instance type you launch.
I am trying to access aws ec2 instance from putty and winscp but it is not getting connected to the instance. It was getting accessed previously in normal for but dont know from few days it is nt been accesible.
Please can anyone help me with its solution.
Thanks in advance
There is possibility that the aws instance may get hanged to the possible solution is to restart the aws instance. But make sure we take the backup of the current instance and restart the hanged instance and after successful restarting deleted the duplicate instance.