In linux today, the system prompts "This account is currently not available", indicating that the user is invalid. Later, I checked it online and found that the user's shell is forbidden to log on, you only need to enable shell logon.
Solution:
For example, I encountered a problem when I was using su apache.
Use vi to view apache account information
# Cat/etc/passwd | grep apache
Find itsShellYes"/Sbin/nologin", You need to change"/Bin/bash"
# Vipw/etc/passwd
Save and exit after modification.
In this case, su apache can easily be used.
Command record:
Login as: root
Root@10.0.0.10's password:
[Root @ apache-2 ~] # Vi/etc/passwd
[Root @ apache-2 ~] # Chown-R apache: apache/var/www/BeeEye/
[Root @ apache-2 ~] # Vi/usr/local/apache/conf/httpd. conf
[Root @ apache-2 ~] #/Usr/local/apache/bin/apachectl stop
[Root @ apache-2 ~] #/Usr/local/apache/bin/apachectl start
[Root @ apache-2 ~] # Reboot