Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Simplify booting and starting linux service

2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

Command processing method:

1)ntsysv

2) setup-system service

3)Script one-click completion of processing

We'll script it.

Turn it on. We need it.

Start four services.

crond --timed task

network --network services

rsyslog --System log function

sshd --this is to allow remote link services

chkconfig --list| grep "3: Enable" See which services launch msconfig under windows like

for value in chkconfig --list| grep "3: Enable"| awk '{print $1}';do chkconfig $value off;done

chkconfig --list| grep "3: Enable"

for value in crond network sshd rsyslog;do chkconfig $value on;done

chkconfig --list| grep "3: Enable"

We can do that with a single command.

for value in chkconfig --list|grep "3:on"|awk '{print $1}' | grep -vE "crond|network|sshd|rsyslog";do chkconfig $value off;done

grep -v is to exclude one plus E can filter multiple, but you have to use vertical bars (|) Splicing

-i can be filtered out regardless of case.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report