Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

NFS performance for user share when playing movies

Featured Replies

When I play movies using NFS share, and doing some time seek, the movie stutter, and the Unraid CPU become very high:

 

top - 15:32:00 up 21 min,  1 user,  load average: 1.33, 0.68, 0.45

Tasks:  81 total,  2 running,  79 sleeping,  0 stopped,  0 zombie

Cpu0  :  0.0%us,  0.0%sy,  0.0%ni, 34.7%id, 65.0%wa,  0.0%hi,  0.3%si,  0.0%st

Cpu1  :  0.0%us,  0.0%sy,  0.0%ni,  0.3%id, 99.7%wa,  0.0%hi,  0.0%si,  0.0%st

Mem:  2040764k total,  1688868k used,  351896k free,    2708k buffers

 

You can see Cpu1 is 0% idle, and Cpu 0 is only 34 idle.

 

The bit rate of the movie I am testing is not that high, ~40Mbps.

It works perfect on disk share.

 

I am using version 4.4.2. I tried using blockdev to control the read ahead with higher and smaller number with no effect.

 

If you want I can collect more information.

 

What player software are you using?  Tried this with VLC media player & can not reproduce.  I will try another player later today.

What format file?  Some can not time seek, and some players are for crap and can't do it wither with some formats even if the format supports it.  The player "simulates" it by trying to do ultra-fast forward.... and that will definitely stutter.

What format file?  Some can not time seek, and some players are for crap and can't do it wither with some formats even if the format supports it.  The player "simulates" it by trying to do ultra-fast forward.... and that will definitely stutter.

Ah... but he said the player works perfectly when playing the same file from a "disk" share.  It is the "user-share" that gets ties up in a knot when he seeks forward over NFS.

 

Joe L.

True, but knowing the player, file format, codec, and bitrate would be helpful... this could be an "OK... close to the limit on one, and slightly over on the other, need some tweaking" or could be a "holy halibut Batman, there is no way that should stutter!"

  • Author

Yes, the file plays perfect on disk share but not on user share.

 

 

The file I am playing can be downloaded from here:

http://www.w6rz.net/

under the "Elephants Dream (Open Source Movie)" section you should download all the parts and merge them together to a single file using dos:

copy /b ed24p_00.ts+ed24p_01.ts+ed24p_02.ts+ed24p_03.ts+ed24p_04.ts+ed24p_05.ts+ed24p_06.ts+ed24p_07.ts+ed24p_08.ts+ed24p_09.ts+ed24p_10.ts+ed24p_11.ts ed24p.ts

 

This file is a constant 40Mbps file that is similar to bluray rip rates.

 

 

 

I am using Popcorn hour player to play the file over nfs-tcp.

 

I have Elephant's dream ... its on legaltorrents.com

 

The copy I have is MP4, 1080p, and has an average bitrate of 10.2Mbps (835MB / 10:53 length) and a peak of about 38Mbps.

 

Compare that to the MP2 transport stream version you linked to, and see that there is no visual difference, but a file that is much smaller, and 1/4 the average bitrate.

 

  • Author

I have Elephant's dream ... its on legaltorrents.com

 

The copy I have is MP4, 1080p, and has an average bitrate of 10.2Mbps (835MB / 10:53 length) and a peak of about 38Mbps.

 

Compare that to the MP2 transport stream version you linked to, and see that there is no visual difference, but a file that is much smaller, and 1/4 the average bitrate.

 

 

The file I linked to, at http://www.w6rz.net/ , is specifically made for high bit rate streaming testing...

This is why the file size is larger than yours. It was encoded in 40Mbps to test heavy load on the storage and player. You should expect the same video quality.

 

When playing bluray rips there are some scenes with high constant bit rate. This file was made to make it easier to test and demonstrate such problems.

 

Whenever there is a stuttering or other playing issue, it would be helpful if the user was to report some information about the file.

 

MediaInfo is a good free applications for this:

 

  http://mediainfo.sourceforge.net/en

 

I use the CLI version in my media server interface.

  • Author

I think I found a way to make the popcorn hour play this movie, and the bluray rips correctly from unraid !

 

 

This is what is needed:

 

1) For all the mdX devices set read ahead for exactly 32k (nfs normal read):

blockdev --setra 64 /dev/md1

 

2) Set only one nfsd

echo 1 > /proc/fs/nfs/threads

 

3) Set low latency settings in sysctl

sysctl -w net.ipv4.tcp_low_latency=1

 

 

I don't know exactly why it is working with this settings, but it does. It seem like a latency problem of the user share that does not happen on disk share.

It is still not 100% working when seeking in the movie, but it is much better.

  • Author

Another thing I changed and really fix NFS performance of user share to 100% is:

 

edit the syslinux.cfg and change the disk elevator algorithm to "Completely Fair Queuing".

 

 

change the boot append line to this:

 

append elevator=cfq initrd=bzroot

  • 8 months later...

Has anyone verified these settings? I just switched 100% to linux Mint (ubuntu with all the codecs and goodies).

 

I would like to ask the veteran unRAID users with considerable Linux experience what they think about the settings suggested above, in particular, the elevator setting, as well as the low latency setting.  Are these valid changes for the rest of us, and if so, how do we implement them.  And are they something I should be recommending on the Improving Performance wiki page?

I would like to ask the veteran unRAID users with considerable Linux experience what they think about the settings suggested above, in particular, the elevator setting, as well as the low latency setting.  Are these valid changes for the rest of us, and if so, how do we implement them.  And are they something I should be recommending on the Improving Performance wiki page?

Easiest way to experiment is to use unMENU and this set of user-scripts.  (they are in the newest set of plug-ins)  The buttons will show up in the User-Scripts page.

 

With them you can set the disk I/O parameter at will just by clicking a button.

(or, since they are just shell scripts, by running any of them at the linux command line)

 

There is a script to get the current disk I/O method, and scripts to set it to any of those available.  Unzip to your unmenu folder that holds all your plug-in files.

 

2iazzhc.jpg

 

Joe L.

 

 

Wow, that was fast!  Nice job!

 

I guess I was hoping you would tell me the good and bad of the different choices.  ;)  But I suppose if I'm going to be making recommendations, it would be better to know what I'm talking about, first hand.  I'll be testing various operations under the different schedulers.  It would be good to hear from others too, as I don't use User Shares.

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.