From: Freek de K. <fr...@op...> - 2023-03-27 14:47:03
|
Op zaterdag 25 maart 2023 19:16:48 CEST schreef Tony Ross: > On 3/25/23 05:33, Freek de Kruijf wrote:... > > > The documentation tells me use "libcamerify motion" to initialize the > > camera for motion. However I can't find this app in the system. > > > > So my question: Where can I find libcamerify > > "apt-file" is a very useful package to have installed, because it tells > us what package contains the file, e.g.: > > $ apt-file search libcamerify > libcamera-tools: /usr/bin/libcamerify I did find this application. Thanks a lot. However when using "systemctl start motion.service" motion starts, but also stops immediately. When I do "cd /etc/motion ; libcamerify motion" motion starts and stays alive. So I copied /usr/lib/systemd/system/motion.service to /etc/systemd/system and changed: EnvironmentFile=-/etc/default/motion in EnvironmentFile=-/etc/motion ExecStart=/usr/bin/motion in ExecStart=/usr/bin/libcamerify /usr/bin/motion -c /etc/motion/motion.conf I also added ExecStartPre=!/bin/mkdir -p /var/run/motion ExecStartPre=!/bin/chown motion:adm /var/run/motion because I got complaints about not being able to write the pid file. However this also starts motion, but stops right afterwards. A workaround may be to start motion in a cron job after boot; did not try this yet. -- fr.gr. member openSUSE Freek de Kruijf |