I used the traditional way to create windows services before, and the steps are many and very troublesome.
It's been really cool since I used Topshelf
https://www.cnblogs.com/jys509/p/4614975.html
ps: When configuring log4net, you need to pay attention to how the configuration file is written