Reply To: Raspian rc.local pianobar

Home Forums Linux Raspian rc.local pianobar Reply To: Raspian rc.local pianobar



I’m trying again to go through log messages. I’m not sure what I’m looking for so I’ve been opening the various log files one by one. I may just try learn another way to start the program automatically.
In the rc.local file I put this pianobar command…
_IP=$(hostname -I) || true
if [ “$_IP” ]; then
printf “My IP address is %s\n” “$_IP”
sh /home/pi/ &
exit 0
this starts a script….

#!/usr/bin/env bash
aoss pianobar
I don’t think it’s a permission issue as I’ve made the script executable. This is the first auto start script I’ve ever tried so I suppose I need something better or more robust than what I wrote. I know when I run the script manually after boot it works.

New users everywhere seem to have issues getting pianobar to start at boot and a quite a few experienced people have said that rc.local is not the best way, they recommend an init script whatever that is. I think I need more general knowledge in running bash scripts.

I’ve read people use cron, so I may try to find some good lessons on how that works as well. I’m starting to feel like I got in over my head but I do seem to learn a few things every day. I never imagined it would be this difficult to run a simple bash command at startup.

Thanks for your input, I’m going to spend a little more time combing over the log files.

  • This reply was modified 1 year, 1 month ago by  Jim.
  • This reply was modified 1 year, 1 month ago by  Jim.