That seems to have cracked it. With the udev rule set to trigger on 'add', I'm still calling mostly the same script as shown a few posts back, but instead of trying to restart squeezelite from within that script, I'm now calling another script to run in the background ('/home/tc/restartSQLITE.sh &'). That new script simply has a short sleep command, followed by the original squeezelite restart command ('sudo /usr/local/etc/init.d/squeezelite restart >> /var/log/pcp_DAC.log ').
As a result, the udev script returns very quickly without blocking further udev events, and squeezelite starts up in the background after that short sleep. I'll experiment with how long the sleep should be in my case - I suspect 0.25 would probably be enough (can you have a non integer sleep?). I don't think the complexity of testing whether squeezelite generates a process id and then retrying would be necessary, since the driver loads very quickly after the 'add' event. ------------------------------------------------------------------------ chill's Profile: http://forums.slimdevices.com/member.php?userid=10839 View this thread: http://forums.slimdevices.com/showthread.php?t=113661 _______________________________________________ unix mailing list unix@lists.slimdevices.com http://lists.slimdevices.com/mailman/listinfo/unix