Hello,
Sorry for the long post, I hope someone with programming experience can give me a little tip how to solve my problem.
After each VenusGX software update, I always have huge troubles to get my bash-script started again periodically by a cronjob.
Usually I do the following:
- I duplicate my bash-script (maxinverterpwr) from a backup on /data to /etc.
The script itself starts with:
#!/bin/bash
set -e
#---Deactivate Fronius Standby Mode (switch off relais) ---
dbus -y com.victronenergy.system /Relay/1/State SetValue 0
....
....
.... - I make the script executable with chmod +x /etc/maxinverterpwr
- With WinSCP I give the script all root rights too (0777)
- If I start my script manually in PuTTY with ./maxinverterpwr, it runs without any errors.
- Cronjob stuff:
- With nano setpowerlevels I create a new file in /etc/cron.d with the following content:
*/10 * * * * root /etc/maxinverterpwr - With crontab setpowerlevels I "convert" it into crontab.
- After that, crontab -e shows the following (looks ok for me):
Is it necessary to delete the setpowerlevels source file or not (I tried both)? - I reboot the VenusGX device.
- I would expect that my script will be started every 10 minutes, but it does not!
I am quite desperate because sometimes I get it working after updates (honestly I don't know why it works) but this time I failed. Wheather it is working or not, in the end everything looks the same for me. Any ideas what else I can try? There must be only a tiny thing that I do not consider.
Thank you and best regards,
Rainer