Advertisement
Guest User

Untitled

a guest
May 26th, 2019
137
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. # Enable ssh root login access
  2.  
  3. Set a new password for the `root` user.
  4.  
  5. ```shell
  6. sudo passwd
  7. ```
  8.  
  9. Now open for editing ssh daemon's config file `/etc/ssh/sshd_config`.
  10.  
  11. Set `PermitRootLogin` value to `yes` to enable logging is as root.
  12.  
  13. ```
  14. PermitRootLogin yes
  15. ```
  16.  
  17. Also check value of `PasswordAuthentication`. If it is set to `no` then set to `yes` for security reasons.
  18.  
  19. ```
  20. PasswordAuthentication yes
  21. ```
  22.  
  23. Then restart ssh service:
  24.  
  25. ```shell
  26. service ssh restart
  27. ```
  28.  
  29. Now you can log in to your server as `root` user.
  30.  
  31. ```
  32. ssh root@domain.com
  33. ```
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement