一、给串口添加密码
在/etc/inittab
注释掉自动以root登陆
#::respawn:/sbin/getty -L ttyS000 115200 vt100 -n root -I “Auto login as root …”
添加:
::sysinit:/bin/hostname noname
::respawn:-/bin/login
hostname 是用来设置主机名称,可用uname -n 查看。
二、网上有些方法:
::respawn:/sbin/getty -L ttyS000 115200 vt100
但经过测试,其超时会直接无需密码登陆。
三、在第三步前,需要现设置密码。方法如下
user 是登陆用户名,一般都是root