JACK26
Member
DC31, It just occured to me that using ps -aux and a text match with the error text output from ezstream could be used as a condition to reboot (or kill and restart related processes). Just not sure how to do that yet 
DC31, It just occured to me that using ps -aux and a text match with the error text output from ezstream could be used as a condition to reboot (or kill and restart related processes). Just not sure how to do that yet![]()
One thing with working with rpi and VNC when working with the terminal windows and trying to copy and paste long lines of text, it truncates the text to the viewable area of the window so I can't see the full content of the output messages. There is no horizontal slider tab to move the content around. Any suggestions on how to solve that problem?
TIA.
That depends on where the error text is placed. If the program is not running, it will not show in the results of the ps. (Which can be used to trigger a restart, via a script.) If the error goes into a log file, grepping that log could work.
Sent via Tapatalk
Copy and paste when using VNC is a pain. I avoid it whenever possible. Normally, i am working on a Mac and connect to the pi through an ssh connection in a Terminal window. Copy and paste works fine there. If you are working on a Windows computer, you could try using puTTY for an ssh connection. I think that copy/paste will work that way.
I have seen the "no more data" streaming error messages MANY times. I have not tried to figure them out. As i recall, the message is something like "no more data from stdin". That implies to me that the data feed (audio) into ezstream has been interrupted. So, rather than a problem with ezstream itself, it may be a problem with the data being piped from rtl to sox then to ez.
I got my bcfy stream sounding reasonably good (acceptable) toward the end of last week. Since then i have diverged into trying to get the audio into pulseaudio so I can do other things rather than just a Bcfy feed. After countless hours, i can report absolutely no progress. When I hit on the correct combination to get it to show in pulse, the audio from rtl locks up with no error messages within about 5 sec.
Currently streaming here with USB sdr sticks on rpi here until it breaks again
https://www.broadcastify.com/listen/feed/23831
https://www.broadcastify.com/listen/feed/25781
ps the feed sample rate is 16KHz not 22.05KHz. Is that a problem? I did change that parameter in the ezstream files to 16KHz.
pps: Follow up. The broadcastify stats changed to the 16KHz stat, so that is not a problem![]()
So is there a way to use ps to detect the error message from ezstream and trigger a reboot of the rpi?
Details are appreciated as I'm new to linux scripting. TIA
.
Jack,
Take a read of the following:
https://broadcastify.zendesk.com/hc/en-us/articles/204172369-Feed-Owner-API-v0-9-Documentation
Using the feed method returns the details of your feed with one of the parameters being whether it is on-line or off-line. "status":1 indicates on-line and "status":0 indicates off-line. It might be a good learning exercise to write a script that monitors that state and triggers a restart when it detects an off-line status. I would use the script that I posted a few days ago as a starting point and run it via a cron job every minute or two. I experimented a little with the feed method and there seems to be a lag of a minute or two also between when the feed goes off-line and when the status parameter actually changes.
This isn't the ideal solution but gives you a starting point.
Jack,
Take a read of the following:
https://broadcastify.zendesk.com/hc/en-us/articles/204172369-Feed-Owner-API-v0-9-Documentation
Using the feed method returns the details of your feed with one of the parameters being whether it is on-line or off-line. "status":1 indicates on-line and "status":0 indicates off-line. It might be a good learning exercise to write a script that monitors that state and triggers a restart when it detects an off-line status. I would use the script that I posted a few days ago as a starting point and run it via a cron job every minute or two. I experimented a little with the feed method and there seems to be a lag of a minute or two also between when the feed goes off-line and when the status parameter actually changes.
This isn't the ideal solution but gives you a starting point.
Started looking at this api info and still have not figured out how to form a fully working url yet. I think that "feedid" is the mount value less the / and the user id is whatever your actual user id and the password is your logon password and not the password used by the feed?
Got past the "access denied" messages but still don't know how to query for online status. That link is not exactly detailed and all but one of the comments have to do with actually getting it to work. lol.
Any suggestions? TIA.