Help me fix my wireless streaming video setup!
January 4, 2010 11:27 AM   Subscribe

I want to stream video at 720p from a storage server on my apartment LAN to wirelessly-connected clients. I've set up FreeNAS on an old laptop, but the setup isn't even fast enough to stream standard def movies without stuttering. Tell me what I'm doing wrong, and how I can fix it. More details about my setup inside

My setup is as follows:
  • FreeNAS 0.7 running on a vintage ThinkPad X30. The OS (FreeNAS is a special-purpose FreeBSD distro) is loaded from a USB key.
  • eSATA PC card in the X30 provides the connection to a 1.5Tb eSATA external hard drive. The drive is shared out to windows clients via samba.
  • Laptop is plugged directly into a Linksys WRT54g V2 wireless router running the latest DD-WRT firmware. Router's wireless LAN is 802.11g.
I can mount the remote drive on my laptop with no problem, but transfer rates are no faster than 200Kb/s. I suspect that 802.11g is the culprit here, though I could be wrong. Would an 802.11n router be fast enough to stream 720p to other machines on the wireless network, or will I have to resort to a wired network to fix this?
posted by killdevil to Computers & Internet (23 answers total)
 
Hmm. 802.11g should have enough bandwidth for streaming 720p (which I think should go from about 4-10mpbs (note the small b)). Which falls well within the bitrate supported for 802.11g. You can try forcing the wireless to only use "g" in the DD-WRT settings to make sure you're not falling back to something slower.

What kind of card are you using on the ThinkPad? also have you tried the same setup but completely wired just to test?
posted by bitdamaged at 11:38 AM on January 4, 2010


It may simply be an interference issue. How many walls/cell/cordless/microwaves do you have in between your setup and your clients?
posted by Oktober at 11:42 AM on January 4, 2010


Response by poster: Wierd, I just tried the same setup wired, and transfer rates are STILL maxing out just above 200Kb/sec. The machine has an "Integrated Intel 10/100 Ethernet controller," according to the specs, so I can't imagine how/why this is causing the problem... but it clearly is.
posted by killdevil at 11:50 AM on January 4, 2010


Response by poster: On further investigation, the link is running at full 100baseT on the FreeNAS server side:
Name  	 fxp0
MAC address 	00:09:6b:e0:6e:42
IP address 	192.168.1.250 
Subnet mask 	255.255.255.0
Gateway 	192.168.1.1
Media 	100baseTX 
MTU 	1500
I/O packets 	24012818/31403609 (685.52 MB/1.82 GB)
I/O errors 	6635969/0
Collisions 	0
Status 	up

So the slowness is still a mystery to me.
posted by killdevil at 12:00 PM on January 4, 2010


That's helpful if you know it may not be the wireless. Can you get to a command line and see if the computer is being maxed out elsewhere? CPU? I/O? Etc.?
posted by bprater at 12:06 PM on January 4, 2010


I had no end of stutter trouble streaming SD video over wireless-g to my PS3 across one wall and about 15ft, so I ran a cable.
posted by rhizome at 12:06 PM on January 4, 2010


Can you try moving files between the server and the client and see what kind of throughput you get? E.g., drag and drop and see if you max out the 200Kb/s
posted by geoff. at 12:08 PM on January 4, 2010


I think first I'd try a hardwired ethernet connection between them - no wifi - and see what speed you get. Using windows shares, on 100Mb ethernet, I regularly get 6MB/s, up to about 12 if I use like rsync to a linux machine. 1Gb ethernet I get up to about 2.5 times that.

On my wireless network I rarely get more than 2MB/s but that's still 10x the speeds you're reporting. Something's wrong - antenna maybe, maybe it's not actually using 802.11g

What's the topology here? freeNAS gets connects to wireless router via hardwire, laptop connects to wireless router via wifi?
posted by RustyBrooks at 12:08 PM on January 4, 2010


Also if your linux box is old, you may have a problem if you're using ext3, I think. This is really hazy because it's been a while but my oldest file server couldn't do ext3 that well, it just chewed CPU to hell.
posted by RustyBrooks at 12:10 PM on January 4, 2010


How old is the client laptop? can you give OS / Specs?
posted by jjb at 12:12 PM on January 4, 2010


I wonder if the connection between the PC card and the laptop is the bottleneck? I am having trouble locating an exact spec, but it was my understanding that the Type-II PC card bus was only slightly faster than USB 1.1, which doesn't stream HD too well. :)

I could be wrong, but it's a thought.
posted by AltReality at 12:20 PM on January 4, 2010


Rhizome I was googling a few things on this and it looks like there's an issue specific to PS3s and a firmware update

http://www.breakitdownblog.com/streaming-playback-of-720p-media-to-ps3-stutters-or-is-jerky/
posted by bitdamaged at 12:44 PM on January 4, 2010


Response by poster: That's helpful if you know it may not be the wireless. Can you get to a command line and see if the computer is being maxed out elsewhere? CPU? I/O? Etc.?

Here's a screenshot of the FreeNAS summary status page. As you can see, the computer isn't breaking a sweat from a CPU or memory standpoint.

Can you try moving files between the server and the client and see what kind of throughput you get? E.g., drag and drop and see if you max out the 200Kb/s

Yeah, I max out at 230Kb/sec when transferring files to my Windows 7 laptop, over EITHER wireless or wired link.

What's the topology here? freeNAS gets connects to wireless router via hardwire, laptop connects to wireless router via wifi?

Yes, that's it.

How old is the client laptop? can you give OS / Specs?

Nearly brand-new Thinkpad T500 running Win 7 Pro.

I wonder if the connection between the PC card and the laptop is the bottleneck? I am having trouble locating an exact spec, but it was my understanding that the Type-II PC card bus was only slightly faster than USB 1.1, which doesn't stream HD too well. :)

That's an interesting thought...

Also, I've done some more testing and the max throughput on drag-and-drop file copy from the server is:

275Kb/sec wired
325Kb/sec wireless (G-only network configuration)
posted by killdevil at 1:00 PM on January 4, 2010


Response by poster: Err that screenshot doesn't show CPU activity, but it's around 3-4% during file copy operations.
posted by killdevil at 1:01 PM on January 4, 2010


Response by poster: Re: Type 2 PC card throughput, here's what the PCMCIA association has to say:

What is the throughput of the PC Card interface?
Theoretical maximums are as follows:

CardBus (32 bit burst mode)
* Byte mode: 33 Mbytes/sec
* Word mode: 66 Mbytes/sec
* DWord mode: 132 Mbytes/sec

16-bit Memory Transfers (100 ns Minimum cycle)
* Byte mode: 10 Mbytes/sec
* Word mode: 20 Mbytes/sec

16-bit I/O Transfers (255 ns Minimum cycle)
* Byte mode: 3.92 Mbytes/sec
* Word mode: 7.84 Mbytes/sec

posted by killdevil at 1:03 PM on January 4, 2010


The issue might be with your eSATA card, I believe you should be able to run some kind of benchmark and find out if that's what's holding you back.
posted by borkencode at 1:29 PM on January 4, 2010


Does your esata enclosure also do USB? You may want to switch to USB to remove esata and the card from the troubleshooting process.

Also, get yourself an ubuntu boot CD to see if FreeNAS is the issue.
posted by damn dirty ape at 2:57 PM on January 4, 2010


Response by poster: The laptop only does USB1.1, unfortunately.
posted by killdevil at 3:13 PM on January 4, 2010


I don't know about FreeBSD, which current versions of FreeNAS are based on, but Linux, which future versions of FreeNAS are going to be based on, includes the hdparm utility lets you do some simple benchmarks that test the speed of the interface between the computer and the hard disk. That said, I'd think that even with 2x overhead in Byte mode, you should be able to get 16MBytes/s out of that card (CardBus slots can accept older PCMCIA cards, but I don't think CardBus cards even work in PCMCIA mode).

So, at this point, try to benchmark reads from your HDD directly from the laptop running FreeNAS. You could also check to see if the filesystem holding your media is updating access times, as that could cause writes that interfere with disk reads. Also, try getting your router/switch out of the way and see if that is part of the problem.
posted by Good Brain at 3:35 PM on January 4, 2010


Oh, also, it looks like that laptop has built in Firewire. Might be worth trying the disk out in a Firewire enclosure. It won't be as fast as eSATA, but it'll be fast enough, and I'd think the drivers for firewire controllers are more mature than controllers for SATA controllers
posted by Good Brain at 3:37 PM on January 4, 2010


Try to remove the external drive from the picture alltogether...for testing. Put a 500MB file (Cd image or something) on the laptop's harddrive, and share it out through Freenas...(I think you can do that....right?) then try to copy the file over the network, and see what kind of throughput you can get....if it's faster, then you know the problem is with either the drive or the esata card. (or freenas's interaction with the card/drive)...but you can get away from troubleshooting the network.

If the file copies over just as slowly, then you can assume that it is not the drive or card that is causing your problems, and focus more on the network side of things.
posted by AltReality at 5:18 PM on January 4, 2010


Generally wifi is poor at streaming, and even more so if you try streaming using smb. I would try wired connection (and if you were using smb, don't) :)

We have plenty of this sort of conversation over on the NMT forums, although talking to the PCH players rather than PCs.
posted by lundman at 6:28 PM on January 4, 2010


>The laptop only does USB1.1, unfortunately.

Yes, but even USB1.1 will outperform the 200kbs youre getting. It'll do at least 500 to 800kbs. If the USB copy is faster than 200kbs then you know the problem is the esata interface/card/driver/whatever.
posted by damn dirty ape at 7:09 AM on January 5, 2010


« Older Baby you can drive my car / I promise I'm not a...   |   Why did only one bottle of water freeze? Newer »
This thread is closed to new comments.