PM2 Windows Startup Utility

1.0.3 · maintenance · verified Wed Apr 22

This package enables PM2 (Process Manager 2) to automatically resurrect its saved process list upon Windows operating system startup. It achieves this by adding a specific entry to the Windows Registry that triggers PM2 on boot, leveraging the `start-on-windows-boot` library for low-level registry manipulation. The current stable version is 1.0.3, indicating a mature and stable utility that is likely in maintenance mode rather than active feature development. Its primary differentiator is its focused solution for automating PM2 process continuity specifically within Windows environments, which is crucial for server stability and uptime after system reboots. It serves as a dedicated tool for system administrators and developers deploying Node.js applications with PM2 on Windows servers.

Common errors

Warnings

Install

Imports

Quickstart

Demonstrates global installation of the utility, then how to register PM2 for Windows startup, and finally how to save the current PM2 process list for resurrection.

npm install pm2-windows-startup -g
pm i -g pm2 # Ensure PM2 is also installed globally if not already
pm i -g pm2-logrotate # Optional: for log management

# Install the PM2 startup script into Windows Registry
pm2-startup install

# Start your Node.js application(s) with PM2, e.g.
pm2 start app.js --name 'my-node-app'

# Crucially, save the current PM2 process list so it can be resurrected on startup
pm2 save

view raw JSON →