Run as a Service

Once Tiny PXE Server has been configured correctly, you may want to consider running it at startup as a service. nssm (the Non-Sucking Service Manager) can be used to install and run Tiny PXE Server as a Service.

Download nssm from here. Extract the nssm executable from the download (selecting either 32-bit or 64-bit as required) and copy it to a location in the PATH (e.g. C:\Windows\, C:\Windows\System32\, etc).

See here for a full list of nssm commands.

This page includes the following topics -

nssm Command-line

To install Tiny PXE Server as a service (with servicename pxesrv) using the nssm command-line, use the following syntax -

E.g.

And start the newly created pxesrv service by restarting the system or running the following command -

Tiny PXE Server should now run as a service at startup. As the Tiny PXE Server GUI will no longer be visible, running the Syslog daemon is recommended for logging (see here).

NOTE - any changes made to the Tiny PXE Server configuration file (config.ini) will not be applied until the system is rebooted, or the pxesrv service is stopped and restarted. To restart the pxesrv service, run the following command -

nssm GUI

To install Tiny PXE Server as a service using the nssm GUI, run the following command -

The NSSM service installer should open after running the install command -

Click on the ... button (see below) and browse/select pxesrv.exe. Alternatively type the path(s) in manually -

The Path: field should display C:\pxesrv\pxesrv.exe and the Startup directory: field should display C:\pxesrv -

Now add a name for the service in the Service name: field (e.g. pxesrv) and click on the Install service button -

A message simlar to the screenshot below should be displayed - click on the OK button -

And start the newly created pxesrv service by restarting the system or running the following command -

Tiny PXE Server should now run as a service at startup. As the Tiny PXE Server GUI will no longer be visible, running the Syslog daemon is recommended for logging (see here).

NOTE - any changes made to the Tiny PXE Server configuration file (config.ini) will not be applied until the system is rebooted, or the pxesrv service is stopped and restarted. To restart the pxesrv service, run the following command -

Syslog daemon

The Tiny PXE Server logging function was removed in build 1.0.0.20 (Feb 12, 2017 - 19:29). A syslog daemon (syslogd.exe) is now included in the Tiny PXE Server download. If running Tiny PXE Server as a service, also running syslogd.exe as a service is recommended. Simply run the following command (editing any paths as required) -

And add the following to C:\pxesrv\config.ini -

The syslog daemon will now log to C:\pxesrv\log.txt - review this file as required for troubleshooting, etc.

Screenshot of the syslog daemon GUI (this will not be visible if running syslogd.exe as a service) -

And sample output to C:\pxesrv\log.txt -

Document date - 28th February 2017(DRAFT)