Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Deploying Node.js

You're reading from   Deploying Node.js Learn how to build, test, deploy, monitor, and maintain your Node.js applications at scale

Arrow left icon
Product type Paperback
Published in Jul 2015
Publisher
ISBN-13 9781783981403
Length 274 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Sandro Pasquali Sandro Pasquali
Author Profile Icon Sandro Pasquali
Sandro Pasquali
Arrow right icon
View More author details
Toc

Using third-party monitoring tools


Node is a new technology for which there are few mature application monitoring tools. Some independent developers, along with established companies in the application monitoring space, have jumped in to fill this gap. In this section, we'll look at PM2 as a process manager and monitor and also have a look at Nodetime.

PM2

PM2 is designed to be an enterprise-level process manager. As discussed elsewhere, Node runs within a Unix process, and its child_process and cluster modules are used to spawn further processes, typically when scaling an application across multiple cores. PM2 can be used to implement the deployment and monitoring of your Node processes both via the command line and programmatically. Here, I will focus on programmatically using PM2 for process management and show you how to use it to monitor and display process activity.

Install PM2 globally:

npm install pm2 -g

The most straightforward way to use PM2 is as a simple process runner. The following...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image