socket_write error - MPD Crashed

General discussion about RuneAudio. Do not post any support or feature requests here.

socket_write error - MPD Crashed

Postby irishwill2008 » 23 Apr 2018, 15:10

Hi guys,

Sometimes i get the odd time where MPD would crash and i would get
Code: Select all
rune_SY_wrk[357]: mpd error: Connection refused
rune_SY_wrk[357]: Warning: socket_write(): unable to write to socket [32]: Broken pipe in /srv/http/app/libs/runeaudio.php


And happens on the PL side (rune_PL_wrk).

Why cant it write the socket? What can i do to solve / fix this? Is there a manual override for this?

Thanks!
Last edited by irishwill2008 on 02 May 2018, 09:12, edited 1 time in total.
irishwill2008
 
Posts: 157
Joined: 26 Jul 2016, 14:49
Location: Ireland

Re: MPD Crashed

Postby janui » 23 Apr 2018, 19:55

Hi irishwill2008,
I have also seen this. But in most cases is caused by MPD not being fully initialised. The PHP script rune_SY_wrk runs through its loop again and usually after 2/3 attempts, when MPD is fully initialised, the pipe is opened successfully. For rune_PL_wrk it’s the same story.
MPD is also shut down for several reasons (e.g. when you use Spotify), again during the start-up phase after a shut-down these 'Broken pipe' messages can occur.
janui
User avatar
janui
 
Posts: 252
Joined: 20 Dec 2014, 12:55
Location: Ollanda

Re: MPD Crashed

Postby irishwill2008 » 01 May 2018, 16:39

Hi janui,

Sometimes it crashes and stays like this until i run a backup. When this occurs, is there some way to set it back to default? Like a command or something where once ran.. Its back to basic and runs smooth again?

Thanks.
irishwill2008
 
Posts: 157
Joined: 26 Jul 2016, 14:49
Location: Ireland

Re: MPD Crashed

Postby janui » 01 May 2018, 21:31

Hi irishwill2008,
Yes, you can reset Rune via SSH. After a reset you will lose quite a lot of your settings, but you will not need to reflash the SD-Card. So, log in via SSH and execute the following commands:
Code: Select all
redis-cli set playerid ""
redis-cli set hwplatformid ""
Then reboot. You will need to check your setting afterwards. Maybe an idea to make a note of your setting beforehand.

If you have Rern’s Addons installed the reset will break it. Its best to remove Rern’s Addons via the menu before resetting. If that is not possible, the following should reinstall the Addons menu after rebooting:
Code: Select all
rm -f ./install.sh
rm -f /usr/local/bin/uninstall_addo.sh
redis-cli del addons addo
wget -vN https://github.com/rern/RuneAudio_Addons/raw/master/install.sh
chmod +x -v ./install.sh
./install.sh

janui
User avatar
janui
 
Posts: 252
Joined: 20 Dec 2014, 12:55
Location: Ollanda

Re: MPD Crashed

Postby irishwill2008 » 02 May 2018, 09:07

Thanks janui! Next time it happens il give it a shot and see how it goes.

Cheers!
irishwill2008
 
Posts: 157
Joined: 26 Jul 2016, 14:49
Location: Ireland

Re: socket_write error - MPD Crashed

Postby Stefano » 22 May 2018, 08:28

Thanks for the codes!
Totally worth it. Next time I want to find lord of the ocean bonuses. Pal, I think that place will provide me some cool info. I need to read it now.
Stefano
 
Posts: 1
Joined: 22 May 2018, 08:27

support RuneAudio Donate with PayPal


Return to General discussion

Who is online

Users browsing this forum: No registered users and 0 guests