NSSM, or Non-Sucking Service Manager, is an open-source tool for managing services on Windows operating systems.
The Windows services utility ‘services.msc’ provides basic functionality for managing services. But NSSM offers many additional options for service management.
To use NSSM, we simply have to download the executable and place it in any folder on our hard drive. To facilitate its use, it is convenient for the location to be added to the PATH environment variable.
Now we can use NSSM. For example, it is very simple to add an executable as a Windows service. To do this, we simply have to do,
nssm install <servicename>
<servicesname> is the name we want to give.
NSSM will open a window with all the options that we can configure in the service. There are quite a few. For example, we can indicate the start parameters, the working directory, or the maximum allowed memory.
We can also specify a start time window and a restart time window, which means that the service will only start or restart within those specified time periods.
We can edit an existing service by doing
nssm edit <servicename>
Or remove it
nssm remove <servicename>
In addition, all configuration options are editable from the command console, making it useful to add as part of our development when we have to manage or configure Windows services.