9

Is it possible to see the restart log/history with PM2 app?

I saw my nodeJS app restarted a few times but no clue when.

I've checked pm2 documentation but no luck.

Thịnh Phạm
  • 2,528
  • 5
  • 26
  • 39

2 Answers2

20

PM2 logs are streamed into the file ˜/.pm2/pm2.log

Unitech
  • 5,781
  • 5
  • 40
  • 47
2

You can run the command: pm2 logs for an output of all logs, relating to running apps and their error logs.

The first log file in the window will be the default PM2 ones, for this kind of information.

MattJHoughton
  • 1,040
  • 13
  • 19