Super simple, method for registering program or software as system service under windows system
Super simple, method for registering program or software as system service under windows system
This demand is mainly based on the fact that software or programs can run in the background under the windows system
Or start it up to achieve unconscious operation. . . Very convenient and easy to use
Here mainly introduces the open source winsw tool, winsw download address is as follows
https://github.com/kohsuke/winsw/releases
The download version here is the version of .net4. . . As shown below
Renamed to a simple and easy to remember name, here renamed to winsw.exe
Copy winsw.exe to the program or software directory, here t r o j a n as an example
Create a new winsw.xml file, this must have the same name as the above winsw.exe,
For example, if you renamed WinSW.NET4.exe then the file name must be WinSW.NET4.xml
winsw.xml file content is as follows, fill in according to your needs
1
2
3
4
5
6
7
<service>
<id> myT * r o * j a n </id>
<name> T * r o * j * a n </name>
<description> none description </description>
<executable> t * r * o * j a n </executable>
<logmode>rotate</logmode>
</service>
1
2
<executable> This is the name of the program / software that needs to be registered as a system service. No exe suffix is required.
Enter the program or software root directory
Execute the following command to register as a system service
1
2
3
.\winsw.exe install
If successful, the following message will be displayed
1
2
3
4
5
#.\winsw.exe install
2020-03-04 19: 40: 24,648 INFO-Installing the service with id 'myT * r * o
j * a * n '
If you want to uninstall the service, execute the following command
1
2
3
.\winsw.exe uninstall
💘 相关文章
- MySQL adds the user with the least authority and the method of restricting the user to occupy system resources
- Method to cancel ssh key password
- 一键自动安装Resilio Sync脚本 for centos
- debian/Ubuntu simple firewall setupthing
- Implementation method of regular backup of MySQL database
- MySQL remote connection configuration method under docker container
- MySQL8 method to restrict the connection of the intranet IP segment
- Plesk uninstall and reinstall method
- How to apply for a free ipv6 address
- 更改用户home目录 for centos