Association caused by chkconfig-how to check whether the program has been installed/successfully installed

Source: Internet
Author: User

One day, you need to run chkconfig. The command still cannot be found during root login.

[Root @ localhost ~] # Chkconfig
Bash: chkconfig: Command not found

 

Why, first check if chkconfig has been installed?

[Root @ localhost ~] # Rpm-Q chkconfig
Chkconfig-1.3.30.1-2

 

Yes. Where has it been installed?

[Root @ localhost ~] # Whereis chkconfig
Chkconfig:/sbin/chkconfig/usr/share/man/man8/chkconfig.8.gz

 

/Sbin/chkconfig here, why not recognize the command and check the environment variables?

[Root @ localhost ~] # Echo $ path
/Usr/Kerberos/sbin:/usr/Kerberos/bin:/usr/local/bin:/usr/bin:/home/zhaoxueqian/bin

 

The/sbin directory is not found. Add the Directory and search a bunch of files online.

[Root @ localhost ~] # Export Path = $ path:/sbin/

Try chkconfig again

[Root @ localhost ~] # Chkconfig
Chkconfig version 1.3.30.1-copyright (c) 1997-2000 red hat, Inc.
...

That is, understanding.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.