Use chkconfig in Linux to set Automatic Service Startup

Source: Internet
Author: User

Command description of chkconfig:

[Root @ mail ~] # Chkconfig
Chkconfig version 1.3.30.1-copyright (c) 1997-2000 red hat, Inc.
Under the terms of the GNU Public License, this software can be freely released.

Usage: chkconfig -- list [name]
Chkconfig -- add <Name>
Chkconfig -- del <Name>
Chkconfig [-- level <levels>] <Name> <on | off | reset | resetpriorities>
[Root @ mail ~] # Chkconfig -- list
NetworkManager 0: Close 1: Close 2: Close 3: Close 4: Close 5: Close 6: Close
Acpid 0: off 1: off 2: Enable 3: Enable 4: Enable 5: Enable 6: Disable
Anacron 0: off 1: off 2: Enable 3: Enable 4: Enable 5: Enable 6: Disable
Apmd 0: Disable 1: Disable 2: Enable 3: Enable 4: Enable 5: Enable 6: Disable
ATD 0: Disable 1: Disable 2: Disable 3: Enable 4: Enable 5: Enable 6: Disable
Auditd 0: off 1: off 2: Enable 3: Enable 4: Enable 5: Enable 6: Disable
Autofs 0: Disable 1: Disable 2: Disable 3: Enable 4: Enable 5: Enable 6: Disable
Avahi-daemon 0: Disable 1: Disable 2: Disable 3: Enable 4: Enable 5: Enable 6: Disable
Avahi-dnsconfd 0: Close 1: Close 2: Close 3: Close 4: Close 5: Close 6: Close
Bluetooth 0: Disable 1: Disable 2: Enable 3: Enable 4: Enable 5: Enable 6: Disable
Capi 0: Close 1: Close 2: Close 3: Close 4: Close 5: Close 6: Close
Conman 0: Close 1: Close 2: Close 3: Close 4: Close 5: Close 6: Close
Cpuspeed 0: off 1: Enable 2: Enable 3: Enable 4: Enable 5: Enable 6: Disable

For example, set named startup

[Root @ mail ~] # Chkconfig named on

Check whether execution is successful:

[Root @ mail ~] # Chkconfig -- list named

Named 0: Disabled 1: Disabled2: Enable 3: Enable 4: Enable 5: Enable6: Disable

 

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.