Error 5 : Access Denied when starting windows service

前端 未结 30 2428
滥情空心
滥情空心 2020-12-04 18:49

I\'m getting this error when I try to start a windows service I\'ve created in C#:

\"alt

My Code

30条回答
  •  攒了一身酷
    2020-12-04 19:20

    Right click on the service in service.msc and select property.

    You will see a folder path under Path to executable like C:\Users\Me\Desktop\project\Tor\Tor\tor.exe

    Navigate to C:\Users\Me\Desktop\project\Tor and right click on Tor.

    Select property, security, edit and then add. In the text field enter LOCAL SERVICE, click ok and then check the box FULL CONTROL

    Click on add again then enter NETWORK SERVICE, click ok, check the box FULL CONTROL

    Then click ok (at the bottom)

提交回复
热议问题