I have xbmc installed on a Revo Acer 3600 in my bedroom. My media is sitting on a Synology NAS in the lounge in the next room. My database and media both sit on the NAS (i.e. remote mysql database)
When playing media wirelessly, at first it works wonders, but it always ends up freezing and xbmc just seems to completely freeze.
I’ve checked the debug log, and this is what I’m seeing:
20:30:25 T:3078395776 M:619479040 NOTICE: GL: Selecting Single Pass YUV 2 RGB shader 20:30:25 T:3078395776 M:619606016 NOTICE: GL: NPOT texture support detected 20:30:25 T:3078395776 M:619606016 NOTICE: GL: Using GL_ARB_pixel_buffer_object 20:31:12 T:2892065648 M:619679744 WARNING: CDVDMessageQueue(video)::Get - asked for new data packet, with nothing available 20:31:12 T:2881575792 M:619679744 WARNING: CDVDMessageQueue(audio)::Get - asked for new data packet, with nothing available 20:31:33 T:2881575792 M:619720704 ERROR: Pause - pcm_pause, alsa error: -77 - File descriptor in bad state 20:31:33 T:2881575792 M:619720704 WARNING: CALSADirectSound::CALSADirectSound - device is not able to pause playback, will flush and prefix with 0 frames 20:38:18 T:2892065648 M:619831296 WARNING: CDVDMessageQueue(video)::Get - asked for new data packet, with nothing available 20:38:18 T:2881575792 M:619831296 WARNING: CDVDMessageQueue(audio)::Get - asked for new data packet, with nothing available 20:38:27 T:2881575792 M:619831296 WARNING: CALSADirectSound::CALSADirectSound - device is not able to pause playback, will flush and prefix with 0 frames 20:50:10 T:2892065648 M:618541056 WARNING: CDVDMessageQueue(video)::Get - asked for new data packet, with nothing available 20:50:10 T:2881575792 M:618541056 WARNING: CDVDMessageQueue(audio)::Get - asked for new data packet, with nothing available 20:52:06 T:2881575792 M:617766912 WARNING: CALSADirectSound::CALSADirectSound - device is not able to pause playback, will flush and prefix with 0 frames 20:56:36 T:2892065648 M:617775104 WARNING: Previous line repeats 3 times. 20:56:36 T:2892065648 M:617775104 WARNING: CDVDMessageQueue(video)::Get - asked for new data packet, with nothing available 20:56:36 T:2881575792 M:617775104 WARNING: CDVDMessageQueue(audio)::Get - asked for new data packet, with nothing available 20:56:46 T:2881575792 M:617783296 WARNING: CALSADirectSound::CALSADirectSound - device is not able to pause playback, will flush and prefix with 0 frames 21:00:12 T:2892065648 M:617156608 WARNING: CDVDMessageQueue(video)::Get - asked for new data packet, with nothing available 21:00:12 T:2881575792 M:617156608 WARNING: CDVDMessageQueue(audio)::Get - asked for new data packet, with nothing available 21:00:19 T:2881575792 M:617164800 WARNING: CALSADirectSound::CALSADirectSound - device is not able to pause playback, will flush and prefix with 0 frames 21:14:42 T:2892065648 M:616681472 WARNING: CDVDMessageQueue(video)::Get - asked for new data packet, with nothing available 21:14:42 T:2881575792 M:616681472 WARNING: CDVDMessageQueue(audio)::Get - asked for new data packet, with nothing available 21:14:46 T:2881575792 M:616681472 WARNING: CALSADirectSound::CALSADirectSound - device is not able to pause playback, will flush and prefix with 0 frames
Basically I keep seeing this:
WARNING: CDVDMessageQueue(audio)::Get - asked for new data packet, with nothing available
It’s pretty clear from the log that xbmc is complaining that it can’t get any new data packets. However this ONLY happens when playing media. If I copy stuff wirelessly, it can copy for hours without fault.
I know you might say that media requires a certain amount of bits per second. Correct, but I get the same freezing whether I’m testing a 1080p file or a standard ’320p’ file. Also it ALWAYS seems to happen roughly 6 – 8 minutes after I start playback, no matter if it’s HD or regular.
The wireless card on the Revo is a 54Mbps capable card and my router is a WRT-54GL with dd-wrt installed. I get anything between 24Mbps to 54Mbps. Of course this is wireless though – half-duplex and the speed is always going to change. There is no problem with the actual wireless connection between my NAS (Synology ds210j) and my Revo. I’ve got iperf installed on the NAS and Revo and this is my results.
This is my actual wireless connection in Linux:
mellowd@XBMCLive:~$ iwconfig lo no wireless extensions. eth0 no wireless extensions. wlan0 IEEE 802.11bg ESSID:"Cisco" Mode:Managed Frequency:2.442 GHz Access Point: 68:7F:74:XX:XX:XX Bit Rate=54 Mb/s Tx-Power=20 dBm Retry long limit:7 RTS thr:off Fragment thr:off Power Management:off Link Quality=42/70 Signal level=-68 dBm Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0 Tx excessive retries:0 Invalid misc:0 Missed beacon:0
TCP test:
NAS:
Simba> iperf -s -p 555 -i 10 ------------------------------------------------------------ Server listening on TCP port 555 TCP window size: 85.3 KByte (default) ------------------------------------------------------------
Revo:
mellowd@XBMCLive:~$ iperf -c 10.20.30.4 -p 555 -i 10 -t 600 ------------------------------------------------------------ Client connecting to 10.20.30.4, TCP port 555 TCP window size: 16.0 KByte (default) ------------------------------------------------------------ [ 3] local 10.20.30.110 port 45553 connected with 10.20.30.4 port 555 [ ID] Interval Transfer Bandwidth [ 3] 0.0-10.0 sec 19.2 MBytes 16.1 Mbits/sec [ 3] 10.0-20.0 sec 19.4 MBytes 16.3 Mbits/sec [ 3] 20.0-30.0 sec 18.6 MBytes 15.6 Mbits/sec [ 3] 30.0-40.0 sec 18.4 MBytes 15.4 Mbits/sec [ 3] 40.0-50.0 sec 18.5 MBytes 15.5 Mbits/sec [ 3] 50.0-60.0 sec 18.4 MBytes 15.4 Mbits/sec [ 3] 60.0-70.0 sec 15.7 MBytes 13.1 Mbits/sec [ 3] 70.0-80.0 sec 16.9 MBytes 14.2 Mbits/sec . . . . . . [ 3] 270.0-280.0 sec 18.7 MBytes 15.7 Mbits/sec ^C[ 3] 0.0-285.7 sec 503 MBytes 14.8 Mbits/sec
Right, so I’m getting roughly 14Mbits/sec minimum average.
Let’s now do a UDP test at that speed to see if there is any jitter or packet loss
UDP test:
NAS:
Simba> iperf -s -p 555 -u -i 10 ------------------------------------------------------------ Server listening on UDP port 555 Receiving 1470 byte datagrams UDP buffer size: 106 KByte (default) ------------------------------------------------------------
Revo:
mellowd@XBMCLive:~$ iperf -c 10.20.30.4 -p 555 -u -i 10 -t 420 -b 14000000 ------------------------------------------------------------ Client connecting to 10.20.30.4, UDP port 555 Sending 1470 byte datagrams UDP buffer size: 110 KByte (default) ------------------------------------------------------------ [ 3] local 10.20.30.110 port 42693 connected with 10.20.30.4 port 555 [ ID] Interval Transfer Bandwidth [ 3] 0.0-10.0 sec 15.5 MBytes 13.0 Mbits/sec [ 3] 10.0-20.0 sec 16.5 MBytes 13.9 Mbits/sec [ 3] 20.0-30.0 sec 16.7 MBytes 14.0 Mbits/sec [ 3] 30.0-40.0 sec 16.5 MBytes 13.8 Mbits/sec [ 3] 40.0-50.0 sec 16.7 MBytes 14.0 Mbits/sec [ 3] 50.0-60.0 sec 16.6 MBytes 13.9 Mbits/sec [ 3] 60.0-70.0 sec 16.6 MBytes 13.9 Mbits/sec [ 3] 70.0-80.0 sec 16.6 MBytes 13.9 Mbits/sec [ 3] 80.0-90.0 sec 16.7 MBytes 14.0 Mbits/sec [ 3] 90.0-100.0 sec 16.4 MBytes 13.8 Mbits/sec [ 3] 100.0-110.0 sec 16.6 MBytes 13.9 Mbits/sec [ 3] 110.0-120.0 sec 14.6 MBytes 12.2 Mbits/sec [ 3] 120.0-130.0 sec 16.4 MBytes 13.8 Mbits/sec [ 3] 130.0-140.0 sec 16.5 MBytes 13.9 Mbits/sec [ 3] 140.0-150.0 sec 16.4 MBytes 13.8 Mbits/sec [ 3] 150.0-160.0 sec 16.2 MBytes 13.6 Mbits/sec [ 3] 160.0-170.0 sec 16.5 MBytes 13.8 Mbits/sec [ 3] 170.0-180.0 sec 16.7 MBytes 14.0 Mbits/sec [ 3] 180.0-190.0 sec 16.7 MBytes 14.0 Mbits/sec [ 3] 190.0-200.0 sec 16.7 MBytes 14.0 Mbits/sec [ 3] 200.0-210.0 sec 16.7 MBytes 14.0 Mbits/sec [ 3] 210.0-220.0 sec 16.6 MBytes 13.9 Mbits/sec [ 3] 220.0-230.0 sec 16.7 MBytes 14.0 Mbits/sec [ 3] 230.0-240.0 sec 16.7 MBytes 14.0 Mbits/sec [ 3] 240.0-250.0 sec 16.6 MBytes 13.9 Mbits/sec [ 3] 250.0-260.0 sec 16.2 MBytes 13.6 Mbits/sec [ 3] 260.0-270.0 sec 16.7 MBytes 14.0 Mbits/sec [ 3] 270.0-280.0 sec 16.0 MBytes 13.4 Mbits/sec [ 3] 280.0-290.0 sec 14.5 MBytes 12.2 Mbits/sec [ 3] 290.0-300.0 sec 16.6 MBytes 13.9 Mbits/sec [ 3] 300.0-310.0 sec 14.8 MBytes 12.4 Mbits/sec [ 3] 310.0-320.0 sec 14.8 MBytes 12.4 Mbits/sec [ 3] 320.0-330.0 sec 15.8 MBytes 13.2 Mbits/sec [ 3] 330.0-340.0 sec 14.5 MBytes 12.2 Mbits/sec [ 3] 340.0-350.0 sec 15.7 MBytes 13.2 Mbits/sec [ 3] 350.0-360.0 sec 14.9 MBytes 12.5 Mbits/sec [ 3] 360.0-370.0 sec 15.6 MBytes 13.1 Mbits/sec [ 3] 370.0-380.0 sec 16.4 MBytes 13.7 Mbits/sec [ 3] 380.0-390.0 sec 13.7 MBytes 11.5 Mbits/sec [ 3] 390.0-400.0 sec 13.4 MBytes 11.2 Mbits/sec [ 3] 400.0-410.0 sec 16.0 MBytes 13.4 Mbits/sec [ 3] 410.0-420.0 sec 14.8 MBytes 12.4 Mbits/sec [ 3] 0.0-420.0 sec 672 MBytes 13.4 Mbits/sec [ 3] Sent 479149 datagrams [ 3] Server Report: [ 3] 0.0-419.8 sec 672 MBytes 13.4 Mbits/sec 2.677 ms 0/479148 (0%) [ 3] 0.0-419.8 sec 1 datagrams received out-of-order
Not a bad result. 479148 datagrams sent with only 1 out of order. What does the server show?
NAS:
Simba> iperf -s -p 555 -u -i 10 ------------------------------------------------------------ Server listening on UDP port 555 Receiving 1470 byte datagrams UDP buffer size: 106 KByte (default) ------------------------------------------------------------ [ 3] local 10.20.30.4 port 555 connected with 10.20.30.110 port 42693 [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 0.0-10.0 sec 15.5 MBytes 13.0 Mbits/sec 0.675 ms 0/11027 (0%) [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 10.0-20.0 sec 16.6 MBytes 13.9 Mbits/sec 0.369 ms 0/11836 (0%) [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 20.0-30.0 sec 16.7 MBytes 14.0 Mbits/sec 0.618 ms 0/11909 (0%) [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 30.0-40.0 sec 16.5 MBytes 13.8 Mbits/sec 0.432 ms 0/11770 (0%) [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 40.0-50.0 sec 16.7 MBytes 14.0 Mbits/sec 0.364 ms 0/11912 (0%) [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 50.0-60.0 sec 16.5 MBytes 13.9 Mbits/sec 0.571 ms 0/11800 (0%) [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 60.0-70.0 sec 16.7 MBytes 14.0 Mbits/sec 0.424 ms 0/11900 (0%) [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 70.0-80.0 sec 16.6 MBytes 13.9 Mbits/sec 0.290 ms 0/11853 (0%) [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 80.0-90.0 sec 16.7 MBytes 14.0 Mbits/sec 1.921 ms 0/11878 (0%) [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 90.0-100.0 sec 16.5 MBytes 13.8 Mbits/sec 1.038 ms 0/11739 (0%) . . . . . . [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 400.0-410.0 sec 16.1 MBytes 13.5 Mbits/sec 0.443 ms 0/11477 (0%) [ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams [ 3] 0.0-419.8 sec 672 MBytes 13.4 Mbits/sec 2.677 ms 0/479148 (0%) [ 3] 0.0-419.8 sec 1 datagrams received out-of-order
At 14Mb/s – there is 0% data loss. Jitter is also very good. In 7 minues it transfered 672MB
Why then can I not watch a 350Mb file which lasts 40 minutes over this SAME link?
Seems like bad programming on the xbmc side as far as I’m concerned. I have posted on xbmc’s forum with no developer taking note.
[...] onboard Wireless ‘G’ NIC, which xbmc doesn’t seem to like playing media through: http://mellowd.co.uk/ccie/?p=1081 – I also have various other wireless [...]
I wouldn’t blame your network, i get the exact same freezes (oh it’s a “hang” not a “crash”) in my win7 setup, using an i3 cpu that hardly goes over 15% when playing 720p, 4 gigs of ram with atleast one free and a usb-hdd connected straight to the computer.
I have managed to “solve” it by running xbmc in debug-mode, as soon as i turn debug off i get a crash after maybe five-ten seconds, if i keep it in debug i can play stuff for hours.
Today it even locked up with debugmode on but in windowed mode (not fullscreen),
19:04:28 T:5932 M:1123897344 WARNING: CDVDMessageQueue(audio)::Get – asked for new data packet, with nothing available
19:05:51 T:5788 M:1133182976 DEBUG: CWinEventsWin32::WndProcWindow is active
1,5 minutes where i can do _nothing_, even when it’s windowed i cannot switch to another application or run taskkill /im “xbmc.exe” (think kill -9).
mad props on the extensive amount of information for your tests, if only my customers were as thorough
Varj. I agree. Other people have tested and it seems that xbmx 10+ is the only one having this issue. When people try media with 9.11 they don’t run into these same problems.
As for the testing, I wanted to prove beyond a shadow of a doubt that the fault did not lie with my network. Rather the fault is with the application being used. Unless people see real graphs they don’t believe you. Generally the reply is, “it must be your network”
Personally I gave up, I just lay a Cat5 cable which effectively ‘hides’ xbmc’s problem :)
I have a Cat5e Gigabit network running XBMC on an apple TV (it only has 100Mbps) and still get this problem.
Hi Sam.
I switched over to Cat5 for my Acer Revo and not since had a problem with xbmc freezing. Interestingly enough, I put xbmc on my laptop on the weekend and my wife was able to play a 720p version of Aladdin without it once choking.
My laptop only has wireless g capability, so I’m quite surprised.
The only software differences are that my laptop is running Windows 7 and my Revo is running Linux
It’s obviously an XBMC issue and I’ve seen it on a bunch of forums trying to solve the issue on my own box, however I get the issue when I play directly from the hdd
Ever find a fix for it?
Hi Jay.
I never did find a fix. My posts on the xbmc forum were ignored :( Even other people were complaining about the same problem in the same thread, but nothing.
I eventually cabled a Cat5 cable through the wall just to get it working right.
Darren,
I’ve got the same problem here, wired connection, Plenty of bandwidth, however mine freezes for like 30-45seconds and then resumes with this in the logs
WARNING: CDVDMessageQueue(video)::Get – asked for new data packet, with nothing available
WARNING: CDVDMessageQueue(audio)::Get – asked for new data packet, with nothing available
WARNING: CALSADirectSound::CALSADirectSound – device is not able to pause playback, will flush and prefix with 0 frames