Ubuntu上的Telnet服務默認使用 23端口。這是Telnet協議的標準端口,用于遠程登錄和管理網絡設備。
sudo apt-get install telnetd
修改配置文件:
編輯 /etc/xinetd.conf 或 /etc/xinetd.d/telnet 文件,確保服務配置正確。
例如,在 /etc/xinetd.d/telnet 文件中添加或確認以下內容:
service telnet {
disable no flags
REUSE
socket_type stream
wait
no user root
server /usr/sbin/in.telnetd
log_on_failure USERID
}
sudo service xinetd restart
或者
sudo /etc/init.d/xinetd restart
盡管Telnet在某些特定場景下仍然有用,但由于其安全性問題,建議盡可能使用更安全的SSH協議進行遠程訪問。