A step by step process on how to add or import an existing SSH Key in WHM to access your account with root privileges.
Login to the server via SSH and check whether any key has been created or not. If not then create it using your desired encryption.
Run the following command to create SSH key on the server.
ssh-keygen -t rsa
ssh-keygen -t dsa
The default path for your key has been saved in:
Once the SSH key is created please follow the below steps to import in WHM:
Step 1: Sign in to WHM and come on Home -> Security Center -> Manage root’s SSH Keys.
Step 2: Then, Press the Import Key button
Step 3: In the first field, enter a Name for the key which you want to import.
Step 4: Insert the public key in the parallel field.
Step 5: Press the Import.
Note: One does not require the Password and Private Key fields.
At this point, you have to authorize that key for the root user. To accomplish this, return to Manage root’s SSH Keys and click the Manage Authorization button next to the key you have just added.
Lastly, click on the Authorize button. Now you can login to your server as root by using this key.
If you want to more about WHM: How to Change FTP Servers through WHM