armbian平台ubuntu环境下telnet安装及启动,给pantherX2增加一个应急通道

armbian平台ubuntu环境下telnet安装及启动,给pantherX2增加一个应急通道

一、首先查看telnet运行状态

#netstat -a | grep telnet

bash 复制代码
输出为空,表示没有开启该服务

这个可以不运行,有的没有安装netstat命令

二、安装openbsd-inetd 和 telnetd

bash 复制代码
apt-get install openbsd-inetd
apt-get install apt-utils
apt-get install telnetd
apt-get install xinetd
apt-get install telnet

三、修改配置,nano /etc/xinetd.d/telnet,填入以下内容

bash 复制代码
service telnet
{
    disable = no
    flags = REUSE
    socket_type = stream
    wait = no
    user = root
    server = /usr/sbin/in.telnetd
    server_args = -h
    log_on_failure += USERID
}

四、开启root用户,修改etc/pam.d/login

bash 复制代码
nano etc/pam.d/login
用#号注释掉pam_securetty.so所在行

五、自启动文件及重启生效

启动文件在/etc/systemd/system/multi-user.target.wants/inetd.service

bash 复制代码
[Unit]
Description=Internet superserver
Documentation=man:inetd(8)
After=network-online.target
Wants=network-online.target
ConditionPathExists=/etc/inetd.conf

[Service]
Type=notify
ExecStart=/usr/sbin/inetd
ExecReload=/bin/kill -HUP $MAINPID
Restart=on-failure
WatchdogSec=5
KillMode=process

[Install]
WantedBy=multi-user.target

重启

bash 复制代码
systemctl restart inetd
相关推荐
s090713611 分钟前
ZYNQ7000 AXI DMA 接收中断(S2MM_introut)全解析:从硬件原理到Linux驱动开发
linux·驱动开发·dma·zynq
IT231023 分钟前
抖音作品自动化监控工具
运维·自动化
camellias_23 分钟前
ubuntu(二)ubuntu18.04安装mysql8
linux·ubuntu·adb
藤谷性能24 分钟前
Ubuntu 22.04:安装串口调试助手CoolTerm
linux·运维·ubuntu·串口·coolterm
路溪非溪37 分钟前
如何使用sysfs来排查驱动问题
linux·arm开发·驱动开发
丶伯爵式42 分钟前
Ubuntu 新装后常用设置
linux·运维·ubuntu
@LuckY BoY42 分钟前
deepin 系统的导航栏或任务栏不见了
运维·服务器
哼?~44 分钟前
Socket编程准备
linux·网络
羌俊恩1 小时前
Vim modeline 命令执行漏洞(CVE-2026-34714)修复指导
linux·编辑器·vim·漏洞·cve-2026-34714
wang09071 小时前
Linux性能优化之中断
linux·运维·性能优化