0

I am using CentOS 7 and I had Java 1.7 installed with openjdk in my system but I wanted Java 8 so I removed Java 1.7 by the command:

yum remove java-1.*

Then I installed java normally by tar.gz package everything works normally until I restarted the system. The problem is that whenever I enter the password in my login screen the screen comes back again to the same login screen its like a loop I type the password enter it then a blank screen shows for seconds and then login screen appears again.

I can't seem to figure out what to do where to start looking the problem.

  • Can you log in as root? Can you log in at a console? Press Ctl-Alt-F2 (or F3 etc) until you see a text login prompt. Try logging in there. Try logging in as root user. If you get in, run (as root) setenforce 0 and then return to the GUI (Ctl-Alt-F1) and try logging in again. Also, check permissions on your home directory. It's unlikely that the change of Java caused this as CentOS's desktop doesn't depend on Java - it's more likely that you've accidentally changed something else or a completely unconnected issue has arisen at the same time. But I could be wrong :-) – garethTheRed Oct 17 '15 at 9:33
1

That sounds like something in your graphical environment (maybe your window manager) would like to have that Java version, or it is looking for it in a way you didn't cater for (like, have you looked at /etc/alternatives?), so your graphical session immediately ends, throwing you back to the graphical login screen.

You can use Ctrl-Alt-F2 on the login screen to swith to a text console to log in, and I guess the first thing to do would be to reinstall CentOS' Java. (BTW, in my experience, there is no problem with having multiple versions of Java installed. I tend to put my manually installed ones in /opt, but then, I don't usually care if system tools use the old version.)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.