In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly shows you the "Linux without rc.local file how to do", the content is easy to understand, clear, hope to help you solve the doubt, the following let the editor lead you to study and learn "what to do without rc.local file in Linux" this article.
Newer Linux distributions no longer have rc.local files. Because it has been serviced.
Solution:
1. Set rc-local.service
Sudo vim / etc/systemd/system/rc-local.service [Unit] Description=/etc/rc.local Compatibility ConditionPathExists=/etc/rc.local [Service] Type=forking ExecStart=/etc/rc.local start TimeoutSec=0 StandardOutput=tty RemainAfterExit=yes SysVStartPriority=99 [Install] WantedBy=multi-user.target
2. Activate rc-local.service
Sudo systemctl enable rc-local.service
3. Add startup service
Manually create or copy an existing / etc/rc.local and grant execution permission
#! / bin/sh-e # # rc.local## This script is executed at the end of each multiuser runlevel.# Make sure that the script will "exit 0" on success or any other# value on error.## In order to enable or disable this script just change the execution# bits.## By default this script does nothing.# below this is the command to boot / home/selfcs/anaconda3/bin/python / home/selfcs/t.py > / home/selfcs/auto.log exit boot Giving script execution permission sudo chmod + x / etc/rc.local and above is all the content of the article "what to do without a rc.local file in Linux" Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
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.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.