bash script at Proxmox start-up

friendodevil

Member
Apr 5, 2022
39
3
8
I've put a bash script at /etc/init.d, changed in to executable but Proxmox doesn't execute it when it boots.
How can I add a command script to execute when Proxmox boots?
 
nano /etc/crontab
Then add a line like this if you want root to run a bash script after boot:
@reboot root /bin/bash /path/to/your/script.sh > /dev/null 2>&1
 
  • Like
Reactions: LnxBil
Thank you! What does "> /dev/null 2>&1" indicate?
It will pipe the output of that script into the void, so crontab won't send you emails each time your script echos/prints something or complains because of a warning/error.