Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

So I am new to Amazon AWS and trying to figure out how I can manage my server. I have installed CentOS 6 64 bit and trying to find out a way to login as root via SSH. I have created a key pair and downloaded it but I am not sure what else I can do from there.

Any ideas on how to get SSH access to my server (what programs to use) and how I can enable root? I currently have Putty, PuttyGen and WINSCP to use.

share|improve this question
1  
Logging it with root via SSH is "Doing it Wrong". There is, quite simply, no good reason why you should need to do this. Tell us your use case here and we'll see if there's a better and more secure way you can accomplish it. –  EEAA Oct 14 '13 at 21:25
    
I've only known how to login and use this user. What user would I login with instead of root for the EC2? I also need to install cPanel as root too: docs.cpanel.net/twiki/bin/view/AllDocumentation/… –  user1804933 Oct 14 '13 at 21:28

1 Answer 1

You'll need to ensure that 'PermitRootLogin' is set to yes in your /etc/ssh/sshd_config file to allow remote root logins. I would strongly discourage this however, as it is exremely bad practice, and highly insecure to allow remote root logins.

When you are logged in as a normal user, you can use the 'sudo' command to temporarily elevate yourself to root privileges on a per command basis, or even run 'sudo su -' to run a root shell. The sudo command is configured in the /etc/sudoers file. I recommend reading this link for further information on sudo and how to configure it:

http://unix.stackexchange.com/questions/11285/how-does-sudo-work

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.