MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    PM2 Error

    Scheduled Pinned Locked Moved Troubleshooting
    7 Posts 4 Posters 3.8k Views 4 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • K Offline
      KnottyCord @Preve
      last edited by

      @Preve I don’t think so so because if you follow the step on the guide this step of adding the mm.sh is after.

      1 Reply Last reply Reply Quote 0
      • yawnsY Offline
        yawns Moderator
        last edited by

        KnottyCord is right. pm2 startup is not used to start the mm2 process but to start and initialize pm2 itself.
        Just to be sure … you ran pm2 startup and that told you to run the command your screenshot shows? There are other users with similar problems: https://github.com/Unitech/pm2/issues/2574

        1 Reply Last reply Reply Quote 0
        • K Offline
          KnottyCord
          last edited by

          Yes that’s what i did. Run the command pm2 startup. It gave me a command to enter. When I pressed enter it was not working I keep giving me an error!

          1 Reply Last reply Reply Quote 0
          • K Offline
            KnottyCord
            last edited by yawns

            Changing the command form this:
            sudo su -c "env PATH=$PATH:/usr/bin pm2 startup linux -u pi --hp /home/pi" to this:
            sudo su -c "env PATH=$PATH:/usr/bin pm2 startup systemd -u pi --hp /home/pi"
            seem to work!

            A 1 Reply Last reply Reply Quote 0
            • A Offline
              amanzimdwini @KnottyCord
              last edited by

              @KnottyCord You are correct - you are running systemd (not plain old linux). PM2 does not seem to “realize” that.

              Note that there is ANOTHER problem with PM2 that is now reported as a bug - read all about it here:

              https://forum.magicmirror.builders/topic/2065/solved-pm2-does-not-start-on-reboot/10

              Best of luck - and don’t hesitate to ask for help!

              1 Reply Last reply Reply Quote 0
              • 1 / 1
              • First post
                Last post
              Enjoying MagicMirror? Please consider a donation!
              MagicMirror created by Michael Teeuw.
              Forum managed by Sam, technical setup by Karsten.
              This forum is using NodeBB as its core | Contributors
              Contact | Privacy Policy