Unable to login from GUI in CentOS 6.3

2

I'm facing a weird problem now. Unable to login to the desktop and use the GUI. This problem is somewhat similar to Not able to login through the GUI but there weren't any autologon system enabled. I do can login as root in the GUI and see the desktop, also there is no problem in login via tty2 for the user! So that means the account is active, not locked account and has a login shell assigned in /etc/passwd. I tried changing the passwd, did passwd -U username but all went futile.

Here is the output of `/var/log/secure

Dec 22 10:06:17 aczire sshd[2219]: Server listening on 0.0.0.0 port 22.
Dec 22 10:06:17 aczire sshd[2219]: Server listening on :: port 22.
Dec 22 10:06:21 aczire polkitd(authority=local): Registered Authentication Agent for   session /org/freedesktop/ConsoleKit/Session1 (system bus name :1.29 [/usr/libexec/polkit-gnome-authentication-agent-1], object path /org/gnome/PolicyKit1/AuthenticationAgent, locale en_US.UTF-8)
Dec 22 10:06:36 aczire pam: gdm-password[2713]: pam_unix(gdm-password:session): session opened for user aczire by (uid=0)
Dec 22 10:06:36 aczire polkitd(authority=local): Unregistered Authentication Agent for session /org/freedesktop/ConsoleKit/Session1 (system bus name :1.29, object path /org/gnome/PolicyKit1/AuthenticationAgent, locale en_US.UTF-8) (disconnected from bus)
Dec 22 10:06:37 aczire pam: gdm-password[2713]: pam_unix(gdm-password:session): session closed for user aczire
Dec 22 10:06:40 aczire polkitd(authority=local): Registered Authentication Agent for session /org/freedesktop/ConsoleKit/Session3 (system bus name :1.45 [/usr/libexec/polkit-gnome-authentication-agent-1], object path /org/gnome/PolicyKit1/AuthenticationAgent, locale en_US.UTF-8)
Dec 22 10:07:02 aczire login: pam_unix(login:session): session opened for user root by LOGIN(uid=0)
Dec 22 10:07:02 aczire login: ROOT LOGIN ON tty2

Jimson Kannanthara James

Posted 2012-12-22T05:25:55.717

Reputation: 498

Answers

0

Hmmm, the problem seemed to be from the LD_PRELOAD variable in the bash_profile. When removed, it got logged in successfully.

Jimson Kannanthara James

Posted 2012-12-22T05:25:55.717

Reputation: 498

2

I think someone created /etc/nologin file

If it is there then just delete that /etc/nologin file and try to login

 If the file /etc/nologin  exists, login will allow access only to
 root. Other users will be shown the contents of this file and their
 logins will be refused.

Another Method

nologin file works because of PAM (Pluggable authentication module)

If you comment on below line in /etc/pam.d/gdm-password

#account     required      pam_nologin.so

Then no need to delete /etc/nologin file

NOTE: Be careful while editing this file, always keep a backup.

That's why in your /var/log/secure file its showing about pam (Dec 22 10:06:36 aczire pam: gdm-password[2713]:)

max

Posted 2012-12-22T05:25:55.717

Reputation: 3 329