Linux View Service Command Linux provides the chkconfig command to update and query system services at different running levels. Syntax: chkconfig -- list [name] is used to list the service www.2cto. comchkconfig -- addname is used to add the service chkconfig -- d...
Linux View Service Command Linux provides the chkconfig command to update and query system services at different running levels. Syntax: chkconfig -- list [name] is used to list the service www.2cto.com chkconfig -- add name to add the service chkconfig -- del name to delete the service chkconfig [-- level levels] name to change the startup information and check the startup of a specific service status. On and off indicate the start and stop of the service when the running level is changed. Reset refers to initializing service information. For on and off switches, the system is only valid for 3, 4, and 5 by default, but the reset can be valid for all running levels. Option description: -- level levels specifies the running level, which consists of numbers 0 to 7. for example, -- level 35 indicates the running level 3 and 5. The option www.2cto.com -- add name adds a new service. chkconfig ensures that each running level has a startup (S) or kill (K) entry. If the init script is missing, it is automatically created from the default init script. -- Del name is used to delete the service and delete the connection from/etc/rc [0-6]. d. -- List name list. if a name is specified, only the specified service name is displayed. Otherwise, the statuses of all services at different running levels are listed. Each service in the running-level file managed by chkconfig needs to add two or more lines of comments to the script in the corresponding/etc/rc. d/init. d. The first line tells chkconfig the default startup running level and the priority of start and stop. If a service is not started at any running level by default, use-to replace the running level. The second line of www.2cto.com describes the service. you can use the \ cross-line comment. For example, random. init contains three lines: # chkconfig: 2345 20 80 # description: Saves and restores system entropy pool for \ # higher quality random number generation. it indicates that the random script should be started at runtime level 2, 3, 4, 5. the start priority is 20, and the stop priority is 80. Author wwyu8901
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.