2154 views|0 replies

6818

Posts

11

Resources
The OP
 

[Chuanglong TL570x-EVM] Establish startup service - print helloworld [Copy link]

[Preface] Some services or programs need to be automatically enabled when the computer is turned on, and they need to be added to the startup service. Today, according to the tutorial, we will show you how to print hello world when the computer is turned on.

1. Create a new helloword.sh file in the previous directory:

Enter the following:

Save and exit.

3. Create a service: Enter the file system "/lib/systemd/system/" directory and create a self-starting systemd service configuration file helloworld.service .

Enter the following:

Description is a brief description of the systemd service, ExecStartPre is the print information of the systemd service,

ExecStart is the command to start the current service.

Save and exit.

4. Enter the service enable command: systemctl -f enable /lib/systemd/system/helloworld.service

After restarting the Linux system, the systemd service will automatically execute the contents of the helloworld.sh script after it is started.
The system print information is shown in the figure below:
[Summary] I have learned three steps: creating a new startup file, creating a new startup service file, and taking effect on the service command.
This post is from DSP and ARM Processors
 

Just looking around
Find a datasheet?

EEWorld Datasheet Technical Support

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京B2-20211791 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号
快速回复 返回顶部 Return list