Firmware: A-410 [01 Apr. 2014] | A-400 [12 Mar. 2014] | C-300 [13 Feb. 2014] | A-300 [24 Feb. 2014] | C-200 [11 July 2013] | A-200/A-210 [11 July 2013] | Popbox V8 [3 Dec 2013]

Just got your NMT | WIKI has the answers | Search the forum | Forum Rules/Policy | Firmware & Official NMT News | Popcornhour manuals



User(s) browsing this thread: 2 Guest(s)
Thread Closed 
Analysis of SMB vs. NFS performance for the PCH
05-15-2008, 10:23 PM
Post: #1
Analysis of SMB vs. NFS performance for the PCH
The executive summary:

1. The PCH does not do well with SMB when there is a Gig switch in the network path (as of May 15 2008)
2. NFS-UDP performance is much better than SMB for high bitrate scenes
3. NFS-TCP performance is moderately better than NFS-UDP for high bitrate scenes
4. The main bottleneck for SMB seems to be CPU util on the PCH

A summary of my cpu utilization:
- total cpu util: ~ 60% playing DVD over SMB with Gig switch (worst video performance)
- total cpu util: ~ 70% playing DVD over SMB w/o Gig switch (very bad video performance)
- total cpu util: ~ 40% playing DVD over nfs-tcp/udp (adequate video performance)
- total cpu util: ~70% playing m2ts 1080p content via SMB w/o Gig switch (not great video performance)
- total cpu util: ~40% playing m2ts 1080p content via nfs-udp (almost adequate video performance)
- total cpu util: ~4% playing m2ts 1080p content via nfs-tcp (great video performance!)


If you want more detail on how I came to this conclusion, feel free to read on...

I purchased a PCH about two weeks ago, and when I first got it I upgraded the firmware to the latest and hooked it up and played both a DVD and a high bitrate m2ts file over SMB, everything worked fine.

My network setup:
PCH - 10/100 local switch -- central 10/100 switch -- gig local switch -- PC

After I installed the NMT apps, SMB never worked quite the same. DVD ISO's and m2ts files were stuttering and losing audio. Even after I downgraded the firmware, still the same. SMB was capping out at around 4mbps, extremely poor.

The DVD's and m2ts files seemed to play fine over http, however the http servers don't support ISO's so that wasn't very good for me.

I wondered if maybe this was a problem with TCP parameters (Nagle, buffer sizes, tcp_nodelay, etc.) so thanks to lundman and others I was able to open a telnet window to see if optimizing tcp parameters made any difference.

Short answer, NO. Twiddling with packets sizes, buffers, delay settings, etc. didn't produce any noticeable difference for me. But looking at TOP output during high bitrate DVD scenes (~8mbps) where the video started stuttering, I noticed the following (over SMB):

mem: 85248K used, 4348K free, 0K shrd, 576K buff, 62220K cached
load: 1.53 1.01 0.49
%CPU - %MEM - COMMAND
30.5 - 8.7 - amp_test
15.8 - 0.0 cifsd
9.8 - 8.7 - amp_test
6.2 - 8.7 - amp_test
1.8 - 8.7 - amp_test

total cpu util: ~ 60% playing DVD over SMB with Gig switch


Notice the load creeps up, peaking at around 1.8 in my case. Also, the cisfd process (samba client) is also consuming a lot of CPU. I'm guessing amp_test is the software DVD player, which looks like it is also consuming a huge amount of CPU (isn't decoding supposed to be in hardware!?). Syabas support told me that the PCH has problems when there is a gig switch in the network chain, so I removed the gig switch so my network is now:

PCH - 10/100 local switch -- central 10/100 switch -- PC

When I removed the gig switch, there was a noticeable improvement. The PC reported network usage of around 8mbps (compared to 4mbps when the gig switch was there) but the CPU util distribution changed a little:
%CPU - %MEM - COMMAND
25.2 - 0.0 - cifsd
24.5 - 8.7 - amp_test
8.2 - 8.7 - amp_test
5.6 - 8.7 - amp_test
1.9 - 8.7 - amp_test

total cpu util: ~ 70% playing DVD over SMB w/o Gig switch


Also, still got stuttering on the high 8mbps bitrate scenes even though reads over the network was not a bottleneck. What looks to be the bottleneck is the high CPU usage of the samba client (cifsd). But I got less stuttering, and it corrected itself faster, so it was better but still not good enough.

Syabas support had suggested I use nfs-tcp for best performance, so I set up NFS server on my Win XP Pro PC using the instructions by chris57, with the exception that I mapped guest to anonymous instead of to root, and I had to enable the TCP equivalents (not just UDP) for the NFS and Sun Neo ports in Windows firewall to allow for nfs-tcp. By comparison, when playing the same scene from the same DVD as above, but over nfs-tcp and nfs-udp (both were about the same):

load: 1.04 0.82 0.91
%CPU - %MEM - COMMAND
13.1 - 8.7 - amp_test
11.0 - 8.7 - amp_test
8.2 - 8.7 - amp_test
3.1 - 8.7 - amp_test
2.1 - 0.0 - rpciod/0

total cpu util: ~ 40% playing DVD over nfs-tcp/udp

So over NFS (even with the Gig switch back in place), the load is much better, and CPU util is much better behaved. No stuttering, the DVD played just fine! Also notice that there is no cisfd process consuming a large amount of CPU, which apparently allows the amp_test process to run more efficiently. Although I still wonder why it takes so much CPU to begin with, if the mpeg2 decoding is really done in HW. So, for DVD ISO's, using either NFS-UDP or NFS-TCP works just fine.

1080p content (m2ts file)

But, what about 1080p video, whose bitrate runs about 40mbps? I did the same experiments, and got mostly the same results except that with 1080p video nfs-udp still caused some stuttering, while nfs-tcp worked flawlessly. Here are my results:

Playing a 1080p m2ts file over SMB (without the Gig switch), the read rate over the network was capped at around 35mbps. Still, on high bitrate scenes there is stuttering and loss of audio. Looking at "top", there are only two processes that consume cpu:

%CPU - COMMAND
45% - cisfd
24% - mono

total cpu util: ~70% playing m2ts file via SMB (no Gig switch)

Playing the same m2ts over nfs-udp (with or without Gig switch -- results are similar), the bitrate peaks at around 45mbps (better than smb), but the cpu usage is drastically different looking at "top". The largest cpu consumer was the mono process at 29%, and then rpciod/0 at 9%, so a HUGE difference -- 40% cpu util via NFS-UDP vs. 70% via SMB. There is still a slight bit of stuttering here and there, but it only lasts a couple of seconds and then corrects itself.

%CPU - COMMAND
29% - mono
9% - rcpiod/0

total cpu util: ~40% playing m2ts file via nfs-udp

I then tried running the same m2ts file over nfs-tcp. Everything works fine over nfs-tcp! The PC reports bitrates of around 45mbps (same as nfs-udp) but it looks like the streaming is smoother. The CPU utilization was below 5%! The biggest CPU consumer was the mono process at around 3%. The next biggest process was 0.5%.

total cpu util: ~4% playing m2ts file via nfs-tcp

So net-net, NFS-TCP is by far the most efficient protocol vs SMB and NFS-UDP. HTTP is probably faster, but I didn't bother to test the speeds since I need to play ISO's and we can't do that yet over http. Hope people find these results useful.

Cheers.
Find all posts by this user
05-15-2008, 10:40 PM
Post: #2
Re: Analysis of SMB vs. NFS performance for the PCH
schung Wrote:Hope people find these results useful.
Yes! Very!

It shows that no amount of messing with the network outside the PCH will make much difference to SMB. Thanks for your work on this and thanks for sharing in such a clear manner.

Les.
Find all posts by this user
05-15-2008, 11:18 PM
Post: #3
 
big thx thats an really good report Smile

werner
Find all posts by this user
05-15-2008, 11:26 PM
Post: #4
 
thanks for those infos, but I have a "naive"/stupid question :oops:

I have setup my PCH with the following Nerwork sharing option :
nfs://my_nas/media, it works but how could i know if i am using a nfs over tcp or a nfs over udp ?

Thanks in advance for your help/

Ampli A/V:Denon AVR-4308 (HDMI)
Video :Pioneer PDP506-XDE+Panasonic PT-AE1000U (HDMI)
PCH A-110:Firm 01-17-081023-15
C2OOFirm 02-01-090904-19
NAS:Readynas NV+ 4To & QNAP TS-509 5To
Wired Cat 6 net :Belink N1 V
Find all posts by this user
05-15-2008, 11:30 PM
Post: #5
 
you use udp to use tcp you have to take nfs-tcp
Find all posts by this user
05-15-2008, 11:30 PM
Post: #6
 
zakhounet Wrote:I have setup my PCH with the following Nerwork sharing option :
nfs://my_nas/media, it works but how could i know if i am using a nfs over tcp or a nfs over udp ?

Thanks in advance for your help/

You are using nfs-udp. To use nfs-tcp, modify your share to be:

nfs-tcp://my_nas:/media
Find all posts by this user
05-15-2008, 11:53 PM
Post: #7
 
thank you.

Do i also need to do something on my NAS (netgear readynv+) ?

Ampli A/V:Denon AVR-4308 (HDMI)
Video :Pioneer PDP506-XDE+Panasonic PT-AE1000U (HDMI)
PCH A-110:Firm 01-17-081023-15
C2OOFirm 02-01-090904-19
NAS:Readynas NV+ 4To & QNAP TS-509 5To
Wired Cat 6 net :Belink N1 V
Find all posts by this user
05-15-2008, 11:55 PM
Post: #8
 
no you dont have to change something on your nas
Find all posts by this user
05-16-2008, 01:58 AM
Post: #9
 
Great post! Thanks.

I can do a smb share using smb://nas/folder (I also have a userid and pwd)


When I try to use the nfs-tcp format I never can connect to the drive

nfs-tcp://nas:/folder

Am I missing something? Must there be something special on the network or the nas to support nfs-tcp?
Find all posts by this user
05-16-2008, 02:16 AM
Post: #10
 
UncleJohnsBnd Wrote:Great post! Thanks.

I can do a smb share using smb://nas/folder (I also have a userid and pwd)


When I try to use the nfs-tcp format I never can connect to the drive

nfs-tcp://nas:/folder

Am I missing something? Must there be something special on the network or the nas to support nfs-tcp?

Ok...I now have it picking up my NAS....but when I click on the video icon it indicates no content found..... :?
Find all posts by this user
05-16-2008, 06:51 AM
Post: #11
 
UncleJohnsBnd Wrote:Ok...I now have it picking up my NAS....but when I click on the video icon it indicates no content found..... :?

When I had that problem it was because I did not have the correct permissions set on the shared directory (and sub directories). Since I was accessing the NFS share anonymously, I added permissions for Guest (the Windows user mapped to anonymous access) to the shared directory and then things worked fine.
Find all posts by this user
05-16-2008, 01:38 PM
Post: #12
 
MyIhome = http So I should be ok unless I want to read ISO? Am I correct?

Thx
Find all posts by this user
05-16-2008, 02:02 PM
Post: #13
 
Bebop: Yes.

Apart from not reading isos, Myihome also does not support menus for DVDs in folder format. It will however play individual VOB files.

Because I want the ISO and DVD folder functionality, I tried to install SMB shares on my PC, but unfortunately I still haven't managed to get it to work. Sad

Media tank:A-100 & C-200
TV:Panasonic TH-50PY800MT (HDMI)
Audio:Logitech Z-5500 (Coaxial)
Find all posts by this user
05-17-2008, 12:40 AM
Post: #14
 
I tried this out.
But i get like "lag" in 1080p movies
A friend of mine tested on his PCH, and following the instructions.

Any idea what is wrong when it lags?
I got 10/100 network, and get 10-20% usage
Find all posts by this user
05-17-2008, 06:31 AM
Post: #15
 
Its kinda silly PH has no manual for setting up these devices, it took me over 2months to get the device working correctly in NFS TCP mode, ever since then its been flawless and VERY fast.

Kinda pointless to offer SMB, its useless.
Find all posts by this user
Thread Closed 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Network performance with new NAS EasyTiger 1 512 02-19-2014 06:53 AM
Last Post: Willem53
  A300 - LAN Performance Challenges bresnab 0 700 09-12-2012 03:32 PM
Last Post: bresnab
  Ready Nas to A-110 performance Atinkler 1 1,160 10-10-2011 09:28 AM
Last Post: Atinkler
  SMB vs NFS, how to boost SMB performance? everlong 0 3,059 01-14-2011 03:30 PM
Last Post: everlong
  streaming performance of PCH A110 when PC is connected to router with WiFi g ?? geof3010 4 2,548 08-24-2009 05:23 AM
Last Post: nmtwilier
  Network, disk, ftp, rsync performance lmfs 28 29,932 08-04-2009 06:02 PM
Last Post: ajauberg
  New opensolaris server and performance earthling 41 17,881 07-21-2009 03:12 AM
Last Post: lundman
  Playback performance between external USB-drive and Streaming over LAN. HTP 4 2,124 06-21-2009 09:36 PM
Last Post: HTP
  SMB Performance... am I missing something? memmo 3 1,618 05-03-2009 01:40 PM
Last Post: memmo
  [A110] network performance michso 4 2,841 04-15-2009 08:10 PM
Last Post: sunking

Forum Jump: