Use NFS instead of SMB for TSReader

  Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
Swifty Offline
Fan
Posts: 618
Joined: Nov 2008
Reputation: 5
Post: #1
(this is mainly @margro)
I thought it could be useful to use NFS instead of SMB for reading files when using TSReader since I'm looking to switch to using a RaspberryPi, so every CPU cycle counts Smile

This evening I played around with the addon source and changed the ToXBMCPath function in utils.cpp and replaced smb:// with nfs:// and then commented out the username/password bits below it.
This was mainly as a test to see if it could even work - since I don't really know what I'm doing Smile

After creating two NFS shares on the Mediaportal box (using the same names as used for the SMB shares) it worked a treat and even on my Acer Revo, it seems a bit quicker at opening files.

Would it be possible to get this added as a 'proper' option in the addon ? probably something like under the advanced section of the addon configuration have a checkbox to 'use NFS instead of SMB' then just ignore the username/password (if one has been entered) and switch the protocol in the connection details?

It seems like this could be a very quick way to eek out a little extra performance from lower power boxes that are in use these days.
find quote
margro Offline
Fan
Posts: 654
Joined: Oct 2009
Reputation: 21
Location: The Netherlands
Post: #2
Yeah that change would work for the Gotham version of the PVR addon since it is now using XBMC's internal virtual file system which supports also nfs.

Sure, it is possible to add an option for that, provided that someone also updates the wiki documentation with hint about the configuration at the server side.

Could you tell me which nfs server you are using under Windows and how to confgure it like you did. I don't like adding options for stuff I can't test myself Wink

Developer of the MediaPortal PVR addon and the Argus-TV PVR-addon. Unofficial XBMC Windows builds with PVR.
http://www.scintilla.utwente.nl/~marcelg/xbmc
find quote
Swifty Offline
Fan
Posts: 618
Joined: Nov 2008
Reputation: 5
Post: #3
Hi Margro, thanks for the quick reply - I'm glad you are willing to include this option Smile

The setup is quite easy, I'm using hanewin NFS (http://www.hanewin.net/nfs-e.htm) but you can also use Windows built in NFS from the Services for Unix feature or similar if you use Windows Server (untested).

Configuration is just a matter of installing hanewin NFS and opening the application and clicking the 'Exports' tab, then click on 'Edit Exports file' and enter two lines like below:-

C:\Users\Public\Videos\Timeshift -name:Timeshift -alldirs -public
"D:\Media\Videos\TV Recordings" -name:Recordings -alldirs -public

The details of that are fairly self explanatory but the first path is the local directory (put in quotes if it includes spaces), -name option is the NFS share name, -alldirs allows direct mounts of any folder level below the share (unsure if explicitly needed).
-public means anyone can access Smile
You can also replace -public with -range 192.168.1.1 192.168.1.10 to lock access to a certain IP range.

Once your two lines are entered just hit 'Save' and 'Restart Server' then it should be set-up Smile

On my openelec box I had an issue where I wouldn't see my server (TV server URL has the hostname, and for some reason DNS didn't resolve the IP) but to solve that I just added the ip/hostname to .config/hosts.conf and all worked fine (probably not needed for most people).

I'm happy to get the wiki page together with setup details for this once I can get some screenshots of the required options etc.
(This post was last modified: 2013-10-27 17:09 by Swifty.)
find quote
dracul Offline
Junior Member
Posts: 2
Joined: Dec 2013
Reputation: 0
Post: #4
Ive tested some of my HD recordings from Mediaportal and SMB stutters while NFS runs smooth. Now i hope the same happens with the HD Tv stream from Mediaportal and with the recordings over the mediaportal plugin.

So can someone send me the changed version? I tied by myself, but visual Studio 2012 drops an error and ./configure on the Pi does the same.
find quote
ravents Offline
Junior Member
Posts: 1
Joined: Nov 2013
Reputation: 0
Post: #5
I had big problems with stuttering of HD content as well. On the same client, with the same TV server, I could play the same content flawlessly with MediaPortal, but not via XBMC.

The fix for me was simply to change the Audio Renderer to WASAPI.
find quote
dracul Offline
Junior Member
Posts: 2
Joined: Dec 2013
Reputation: 0
Post: #6
I think you are using Windows(Wasapi=Windows Audio Session API) on your client, so unfortunately this is no option for this thread :/

On XBMC Gotham with changed with chaged PVR Plugin i could play HD *.ts streams flawlessly with NFS. But i didnt managed to get live tv working. Maybe i had some issues on my server with nfs and file rights.
find quote