How to SSH into your QNAP device
To connect to your QNAP device using SSH, do the following:
- Be sure SSH is enabled. In the Administration interface, go to Network Services, then to Telnet / SSH. Be sure the box Allow SSH connection is checked. Note the port number in the adjacent text box, and change it if desired. If you changed anything, click the Apply button.
- From the system which originates the SSH session, use your ssh command as normal.
- You must ssh in as user admin. By default, the QNAP device refuses ssh connections from any other user ID.
Modifying SSH configuration
SSH configuration is controlled by the file /etc/ssh/sshd_config. This file has a line:
and it is that line which limits SSH logins to the user admin.
Unfortunately it isn't easy to change that file. Firstly, changing configuration files like this is an advanced system administrator act, requiring you to log into the command line of the QNAP. There presently (as of August 2010 on the QNAP TS-219P) is no way to modify settings like this in the web admin UI. Secondly, sshd_config is one of the files which the NAS overwrites from a saved copy each time it starts up. Thus, if you do modify it, your changes will be lost when the NAS restarts.
If you want to modify the behaviour of SSH, you are best off installing the Optware package OpenSSH. As part of this, you will get a new sshd_config which you can modify. The following articles explain how to do this: