Chinaunix首页 | 论坛 | 博客
  • 博客访问: 239583
  • 博文数量: 76
  • 博客积分: 1491
  • 博客等级: 上尉
  • 技术积分: 590
  • 用 户 组: 普通用户
  • 注册时间: 2009-02-06 08:57
文章分类

全部博文(76)

文章存档

2012年(3)

2010年(30)

2009年(43)

分类: 嵌入式

2010-05-07 17:27:20

Linux控制台的用户自动登录


在/sbin目录下新建文件autologin,并往文件写入下面内容:

exec 0/dev/$1 2>&1

cat /etc/issue

shift

exec $*

改变autologin文件的权限执行下面语句:

chmod 777 /sbin/autologin

最后编辑/etc/inittab文件

把类似以下部分

2:2345:respawn:/sbin/getty tty2

修改为

2:2345:respawn:/sbin/autologin tty2 login –f sybase

以上为系统启动时,sybase用户自动登录.

I have added this line in the inittab file:

1:2345:respawn:/bin/login -f root console

I suppose that "console" means ttyS0, as it's defined in the "bootargs" environment variable.


阅读(1992) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~