1、编辑文件

[root@CentOS6 ~]# vim /etc/gdm/custom.conf

GDM configuration storage
[daemon]
AutomaticLoginEnable=true #使能自动登录
AutomaticLogin=root #指定自动登录的用户
[security]

[xdmcp]

[greeter]

[chooser]

[debug]

2、reboot

重启之后就不需要输入登录用户和密码了。