Thursday, July 20, 2017

This account is currently not available - user login problem in linux

I wanted to perform some tomcat related operations and wanted to login as tomcat user after having installed tomcat afresh on my system. As you can see from the screenshot pasted above, sudo su - tomcat gave me the error - This account is currently not available. 

Investigating this problem:

To investigate this I needed to check the /etc/passwd file which stores essential information, which is required during login.

Compare this with my current user - vagrant

To fix this problem:

Nologin is used for security reasons but if you are sure that you need to login for a genuine reason, you may edit the /etc/passwd file and replace /sbin/nologin after : with /bin/bash/ as shown below after which you won't receive the error This account is currently not available any more.

Now you will be able to login and go about your business as usual.

More Information on nologin:

No comments:

Post a Comment

Please post your comments on whether you liked it and what else would you like me to write on. Suggestions of all types are welcome.