這是因爲在server端設置的/etc/sshd_config文件中,需要設置爲:
AllowTcpForwarding 應該設置爲yes纔可。
如果沒有設置爲yes的話,用戶就只能通過sftp訪問指定目錄,而且不能進行ssh登錄.
只有把 AllowTcpForwarding no 改爲 AllowTcpForwarding yes ,用戶才能通過ssh登錄然後訪問目錄。
這是因爲在server端設置的/etc/sshd_config文件中,需要設置爲:
AllowTcpForwarding 應該設置爲yes纔可。
如果沒有設置爲yes的話,用戶就只能通過sftp訪問指定目錄,而且不能進行ssh登錄.
只有把 AllowTcpForwarding no 改爲 AllowTcpForwarding yes ,用戶才能通過ssh登錄然後訪問目錄。