This article is a mirror article of machine translation, please click here to jump to the original article.

View: 5257|Reply: 0

[Communication] OpenWRT settings to boot up the execution command

[Copy link]
Posted on 11/5/2023 9:51:21 AM | | | |
Requirements: Based on OpenWRT soft routing, if you want to start a program, you can set up the command to start execution in the OpenWRT background, not in the form of a service.

Prerequisite: You need to install the coreutils-nohup plugin, as shown in the figure below:

Normally, in Linux/Unix, only the daemon can continue to execute after leaving the terminal, while the normal process will exit when the terminal is closed due to receiving a SIGHUP signal (pending signal). Therefore, in order to run normal processes for a long time, you need to use the nohup command.




Step: Go to the Openwr background and click System - Startup Items - Local Startup Script to add the following code.

This is the content of /etc/rc.local. Insert your own commands here (before "exit 0") to execute them at the end of the boot process.

As shown below:



Add commands as follows:



Or edit directly/etc/rc.localDocuments can also be used.

(End)




Previous:EF concurrency exception DbUpdateConcurrencyException requeries the cached value
Next:Introduction to Nginx location configuration priority
Disclaimer:
All software, programming materials or articles published by Code Farmer Network are only for learning and research purposes; The above content shall not be used for commercial or illegal purposes, otherwise, users shall bear all consequences. The information on this site comes from the Internet, and copyright disputes have nothing to do with this site. You must completely delete the above content from your computer within 24 hours of downloading. If you like the program, please support genuine software, purchase registration, and get better genuine services. If there is any infringement, please contact us by email.

Mail To:help@itsvse.com