internet-equity / nm-exp-active-netrics

Netrics - Active Measurements of Internet Performance
Apache License 2.0
12 stars 7 forks source link

machine reboot resets crontab #18

Closed JamesSaxon closed 3 years ago

JamesSaxon commented 3 years ago

On machine reboot, the crontab /etc/cron.d/cron-nm-exp-active-netrics reverts to a default one, instead of either the user's default or (I would prefer) whatever was edited & installed.

JamesSaxon commented 3 years ago

This is still not working for me on reboot. This would also help with #19

ubuntu@pi:~$ sudo cp /etc/cron.d/cron-nm-exp-active-netrics blah
ubuntu@pi:~$ sudo reboot now 
Connection to 192.168.1.5 closed by remote host.
Connection to 192.168.1.5 closed.
 ~ ssh pi 
[...]
ubuntu@pi:~$ cat /etc/cron.d/cron-nm-exp-active-netrics
*/5 * * * * netrics env USER=$LOGNAME /usr/local/bin/netrics -p -n -d -t -b -u >>/tmp/nm/nm-exp-active-netrics/log/log.txt 2>&1
32 * * * * netrics env USER=$LOGNAME /usr/local/bin/netrics -s -l -u >>/tmp/nm/nm-exp-active-netrics/log/log.txt 2>&1
22 * * * * netrics env USER=$LOGNAME /usr/local/bin/netrics -i -u >/tmp/nm/nm-exp-active-netrics/log/log.txt 2>&1
ubuntu@pi:~$ cat blah 
*/5  *  * * * netrics env USER=$LOGNAME /usr/local/bin/netrics -p -n -d -t -b -u >>/tmp/nm/nm-exp-active-netrics/log/log.txt 2>&1
32  */2 * * * netrics env USER=$LOGNAME /usr/local/bin/netrics -s -l -u >>/tmp/nm/nm-exp-active-netrics/log/log.txt 2>&1
22  */6 * * * netrics env USER=$LOGNAME /usr/local/bin/netrics -i -u >/tmp/nm/nm-exp-active-netrics/log/log.txt 2>&1
*    *  * * * netrics env USER=$LOGNAME /usr/local/bin/netrics --tshark -u >/tmp/nm/nm-exp-active-netrics/log/log.txt 2>&1
ggmartins commented 3 years ago

this should be fixed with #20

JamesSaxon commented 3 years ago

Yes, this is working now for me. Thanks