Synology NAS DSM 6.2 root access

Lately I been searching over internet for guide to get access to my Synology NAS root privelage.

Luckily I had found some and I summarized the one works on mine unit as below.

Before you do all this, make sure you have Putty and WinSCP both the programs on your computer. As you need both of these programs to do this.

Once you had both program ready, you need to login into your NAS to enable the SSH port at the setting. And you can change the SSH port to 220 (default port is 22).

Then open the Putty program, fill the Host Name with your NAS local address and select SSH with change the default port to 220. Then click open.

In the Putty box:
  1. Login with your current administrative user account and password
  2. You will see "admin@NAS". Type : sudo -i (then click enter) ; then type your current administrative password again
  3. The screen show "root@NAS". This is where you activate and set the root password. By setting the root password
  4. Type : sudo synouser -setpw root newroot (then click enter). And now you have created your root password as "newroot". You can replace this "newroot" to the password you preferred.
  5. On "root@NAS", type : cd .. (then click enter)
  6. Then type: vi /etc/ssh/sshd_config (then click enter)
  7. You will see many texts and lines appear.
  8. Try to scroll up and search for this line: #PermitRootLogin yes
  9. Remove # char
  10. Then save by press Shift + Z button,
  11. Release the Z button, but still holding the Shift, and press again Shift + Z button
  12. And now type reboot (then click enter)
  13. Wait for at least 2 mins to fully reboot your NAS.
Once NAS fully reboot, launch WinSCP program. Login with your NAS with:
Protocol: SCP ; Port : SSH (not FTP Port) ; Account: root ; Password:newroot

And now you can access to your NAS with root privilege and able to do the file editing.

Below are the full video showing all the steps above.


Comments


  1. 36/5000
    hello does not work with dsm 6.2.3 25426

    ReplyDelete
    Replies

    1. # Authentication:

      #LoginGraceTime 2m
      PermitRootLogin yes <----- need to make sure you remove the prohibit-password
      #StrictModes yes
      #MaxAuthTries 6
      #MaxSessions 10

      Delete

Post a Comment

Popular posts from this blog

How to install ES File Explorer on Hypptv Set Top Box

Install Window 10 on Synology Virtual Machine with DSM 6.2