安装.NET Windows服务

bli*_*egz 5 .net c#

我正在尝试安装我编写的第一个服务:

installutil XMPPMonitor.exe
Run Code Online (Sandbox Code Playgroud)

我收到以下消息:

Running a transacted installation.

Beginning the Install phase of the installation.
See the contents of the log file for the E:\Documents\Projects\XMPPMonitor\XMPPMonitor\bin\Debug\XMPPMonitor.exe assembly's progress.
The file is located at E:\Documents\Projects\XMPPMonitor\XMPPMonitor\bin\Debug\XMPPMonitor.InstallLog.

The Install phase completed successfully, and the Commit phase is beginning.
See the contents of the log file for the E:\Documents\Projects\XMPPMonitor\XMPPMonitor\bin\Debug\XMPPMonitor.exe assembly's progress.
The file is located at E:\Documents\Projects\XMPPMonitor\XMPPMonitor\bin\Debug\XMPPMonitor.InstallLog.

The Commit phase completed successfully.


The transacted install has completed.
Run Code Online (Sandbox Code Playgroud)

但我没有设置运行 services.msc 时列出的服务。我错过了什么吗?

Ree*_*sey 5

确保您正确创建并配置了ServiceInstallerServiceProcessInstaller。这些是 installutil 用于实际注册进程中的每个服务的内容。