• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
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.

Quit MagicMirror via SSH?

Scheduled Pinned Locked Moved Troubleshooting
7 Posts 2 Posters 7.7k Views 2 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.
  • M Offline
    MattG
    last edited by Feb 2, 2017, 1:38 AM

    Hello!

    How do you stop running MagicMirror via SSH? I’m on a mac if that matters.

    Full disclosure, I’m a total n00b. I did look on the forums for this, but couldn’t seem to find anything. Thank you for your time!

    1 Reply Last reply Reply Quote 0
    • Y Offline
      yawns Moderator
      last edited by Feb 2, 2017, 5:48 AM

      How are you starting the mirror?
      Using pm2? -> pm2 stop

      M 1 Reply Last reply Feb 2, 2017, 12:43 PM Reply Quote 2
      • M Offline
        MattG @yawns
        last edited by Feb 2, 2017, 12:43 PM

        @yawns Thank you for your reply!

        I believe I’ve tried that method, but I can say for sure later tonight when I get home from work.

        As for whether I’m using pm2 or not, I don’t believe so, but I am not 100% certain. I setup my Pi 2b fairly generically, and then followed the “how to” in MagPi Issue #54, which doesn’t seem to mention anything about pm2.

        Ultimately, I just want to be able to make changes to the config file, and refresh the mirror without having to interface with the Pi physically. Right now, it is just an annoyance, but once it is on the wall, it would be a real pain as I won’t have any mouse/keyboard hooked up to it.

        Is this something I should be using? If so, can you please point me to a n00b friendly resource?

        Thank you!

        Y 1 Reply Last reply Feb 2, 2017, 12:46 PM Reply Quote 0
        • Y Offline
          yawns Moderator @MattG
          last edited by Feb 2, 2017, 12:46 PM

          @MattG
          This is the “official” way to schedule the MagicMirror process: https://github.com/MichMich/MagicMirror/wiki/Auto-Starting-MagicMirror

          If you let us know how you start your mirror currently we will find a solution to stop/restart the process to avoid rebooting the pi.

          M 1 Reply Last reply Feb 2, 2017, 12:59 PM Reply Quote 0
          • M Offline
            MattG @yawns
            last edited by Feb 2, 2017, 12:59 PM

            @yawns said in Quit MagicMirror via SSH?:

            @MattG
            This is the “official” way to schedule the MagicMirror process: https://github.com/MichMich/MagicMirror/wiki/Auto-Starting-MagicMirror

            If you let us know how you start your mirror currently we will find a solution to stop/restart the process to avoid rebooting the pi.

            Nice! Thank you for the link. This looks like it is exactly what I am looking for. Given that I’ve already setup the MM, and messed around some with the config (modules), do you think I need to wipe the pi and start over, or can I go ahead and follow the steps you linked to implement pm2?

            Regarding your question about how I interface with the mirror currently -

            Right now, I make changes via ssh, and start the mirror via ssh using ```
            DISPLAY=:0 nohup npm start &

            which loads up the mirror interface after a few seconds. To stop the mirror, I use the keyboard physically plugged into the pi and hi ctrl+Q.

            Thanks!

            Y 1 Reply Last reply Feb 2, 2017, 1:18 PM Reply Quote 0
            • Y Offline
              yawns Moderator @MattG
              last edited by Feb 2, 2017, 1:18 PM

              @MattG

              Okay. I did not test it and it is a rather cruel approach, but you could run killall -9 npm via ssh to terminate the npm process. However this would be some kind of a dirty shutdown.
              I don’t think you need to start all over again. pm2 just automates the start after booting the raspberry and gives a little comfort when dealing with logs and such. So you should be fine going ahead and add pm2 functionality.

              As an alternative or in addition you could install Remote Control and use your smartphone/tablet/pc/mac to initiate reboot/shutdown

              M 1 Reply Last reply Feb 2, 2017, 1:44 PM Reply Quote 0
              • M Offline
                MattG @yawns
                last edited by Feb 2, 2017, 1:44 PM

                @yawns

                Awesome! Thank you again! I will definitely be trying this out after work today. Cheers!

                1 Reply Last reply Reply Quote 0
                • 1 / 1
                1 / 1
                • First post
                  1/7
                  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