0

I’ve got a raspberry pi running headless, playing an audio stream through mplayer over wifi.

Crontab loads mplayer on boot, as well as a couple scripts:

  • one that pings the router, and if there is no internet connection, shuts the network interface down and starts it up again.
  • one the pgrep's mplayer, and if it isn't running, launches it

It works for a while, usually from 3 or 4 hours up to 3 days, but eventually it becomes unresponsive. the wireless goes down, and doesn’t come back up, It will not take input from the keyboard. It seems to have crashed.

I’m using a wireless usb card with chipset RT5370. I’ve turned wireless power saving off. I’ve tested the current to the rpi with a multimeter. it is 4.9V. I don’t think it’s an issue with the wireless card or power.

I’ve looked at the syslog and the kernel log, but I don’t really know what to look for, and can’t find anything obvious. What might be causing it to become unresponsive?

***Edit, more info:

I've set up hardware watchdog, and also have Crontab set to email me when the system reboots. I now know it has been crashing/hanging when it is unresponsive. I've started systematically eliminating software and hardware, and it's looking like the problem lies in the interaction of Mplayer, the Wipi, and my bad wireless connection

If I disable Mplayer, or use a more reliable internet connection, it doesn't hang or crash. I am putting this together for an on-site installation where I will have no control over the router, so it can't crash just because there is an interruption in connectivity.

Here is what the cronjob for Mplayer looks like:

 * * * * * pgrep mplayer > /dev/null || sudo mplayer -loop 0 http://96.126.111.125:8000/airadio.ogg > /dev/null 2>> /var/log/airlog.log

the ~/.mplayer/config file contains:

ao=pulse,alsa:device=sysdefault

Any Ideas what I'm doing wrong, or where I should be looking?

  • Hi, my guess is mplayer is crashing under some network situations. I wonder if using trickle would help more quickly identify network issues causing mplayer to become unresponsive. you might also want to daemonize your mplayer commands with start-stop-daemon... – esharp Jan 1 '14 at 19:41
1

My Pi used to freeze up and I tracked it back to the 800mhz overclock that they say "most Pi's can handle". I used to get freezes every few hours. Got rid of ALL overclocking settings and got it running at stock 700mhz and I haven't had a freeze since. Overclocking options are in /boot/config.txt. All the overclocking options explained here. Hope you get it sorted out.

  • Thanks for the thought, but I haven't played with the overclock options. I double-checked /boot/config, and nothing was overclocked. – MichaelBaker Nov 1 '13 at 16:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.