When Domoticz and Grafana are open in Chromium on Raspberry Pi 3 b, it uses a lot of memory. That's why I want to close all chromium tabs automatically once a day. I can find a lot about the automatic startup of chromium, tab Domoticz and tab Grafana after a reboot but almost nothing about automatic shutdown. In ../etc/crontab I already tried to execute 0 5 * * * killall chromium browser. But that doesn't seem to work. Who knows the answer to this question.
This is what I get when tab "Domoticz" and tab "Grafana" are open in chromium:
pi@raspberrypi:~ $ ps -A | grep -i chrom 9665 ? 00:00:26 chromium-browse 9706 ? 00:00:00 chromium-browse 9708 ? 00:00:00 chromium-browse 9740 ? 00:00:01 chromium-browse 9794 ? 00:00:07 chromium-browse 9799 ? 00:00:37 chromium-browse 9867 ? 00:00:04 chromium-browse 10103 ? 00:00:00 chromium-browse
I tried this:
enter # /etc/crontab: system-wide crontab # Unlike any other crontab you don't have to run the `crontab' # command to install the new version when you edit this file # and files in /etc/cron.d. These files also have username fields, # that none of the other crontabs do. SHELL=/bin/sh PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin # m h dom mon dow user command 17 * * * * root cd / && run-parts --report /etc/cron.hourly 25 6 * * * root test -x /usr/sbin/anacron || ( cd / && run-parts --repo$ 47 6 * * 7 root test -x /usr/sbin/anacron || ( cd / && run-parts --repo$ 52 6 1 * * root test -x /usr/sbin/anacron || ( cd / && run-parts --repo$ 0 18 50 * * pi sudo killall chromium-browser-v7 #0 5 * * * root reboot #0 17 * * * root reboot
I also tried user root