Up 起動・停止 作成: 2021-01-27
更新: 2021-02-10


  • 起動
      $ sudo motion
      [25192072:motion] [NTC] [ALL] conf_load: Processing thread 0 - config file /etc/motion/motion.conf [25192072:motion] [NTC] [ALL] motion_startup: Motion 4.1.1 Started [25192072:motion] [NTC] [ALL] create_path: creating directory /var/log/motion [25192072:motion] [NTC] [ALL] motion_startup: Logging to file (/var/log/motion/motion.log)


  • 起動状態のチェック
      $ ps -def | grep motion
      root 1378 1006 0 12:46 pts/0 00:00:00 sudo motion root 1379 1378 2 12:46 pts/0 00:00:02 motion
      $ sudo service motion status
      ● motion.service - LSB: Start Motion detection Loaded: loaded (/etc/init.d/motion; generated) Active: active (exited) since Wed 2021-02-10 12:08:58 JST; 40min ago Docs: man:systemd-sysv-generator(8) Tasks: 0 (limit: 1938) CGroup: /system.slice/motion.service Feb 10 12:08:58 raspi systemd[1]: Starting LSB: Start Motion detection... Feb 10 12:08:58 raspi motion[1140]: Not starting motion daemon, disabled via Feb 10 12:08:58 raspi systemd[1]: Started LSB: Start Motion detection.


  • 停止
      $ sudo pkill motion
      (名前に motion を含むプロセスが終了する)
    または
      $ pgrep motion
      (motionのプロセスナンバーが表示される)
      $ sudo kill [motionのプロセスナンバー]
    または
      $ sudo service motion stop