嵌入式爱好者

imx6 Linux4.1.15版本自动登录root用户方法

2021-11-29 09:45| 发布者: whl| 查看: 620| 评论: 0

类目: 知识库  >  I.MX6系列产品     文档编号: 571

修改/etc/init.d/rmnologin.sh文件
在:exit 0上边添加一行/bin/login -f root 效果如下:

#!/bin/sh
### BEGIN INIT INFO
# Provides:          rmnologin
# Required-Start:    $remote_fs $all
# Required-Stop: 
# Default-Start:     2 3 4 5
# Default-Stop:
# Short-Description: Remove /etc/nologin at boot
# Description:       This script removes the /etc/nologin file as the
#                    last step in the boot process, if DELAYLOGIN=yes.
#                    If DELAYLOGIN=no, /etc/nologin was not created by
#                    bootmisc earlier in the boot process.
### END INIT INFO

if test -f /etc/nologin.boot
then
rm -f /etc/nologin /etc/nologin.boot
fi
/bin/login -f root
: exit 0


已解决

未解决

只是看看

最新评论

QQ|小黑屋| 飞凌嵌入式 ( 冀ICP备12004394号-1 )

GMT+8, 2025-4-20 18:58

Powered by Discuz! X3.4

© 2001-2013 Comsenz Inc.

返回顶部