NFS server setup

From KiSS DP 558 STAGE2 WiKi
Jump to: navigation, search


About

The NFS server is not part of Stage2. But it allows user of diskless players, i.e. DP-500, to use the features of Stage2 that usually require a hard disk inside. At the player side it has to be configured as well.

Windows

There are several implementation of a NFS server available for Windows, i.e. SFU 3.5 from Microsoft, Cygwin NFS. We describe, as an example, how to install Cygwin NFS.

(mostly taken from http://www.csparks.com/CygwinNFS/index.xml)

  • download the setup from: http://www.cygwin.com/setup.exe and save it somewhere on your computer (let say c:\cygwinsetup)
  • execute the setup.exe
  • press next,next,next and type your downloadlocation (let say c:\cygwinsetup) and do next
  • next (direct connection)
  • choose mirror and do next
Adding nfs-server:
Click on the + sign next to the Net category. Scroll down to find the nfs-server item and click on the word "Skip" so it 
becomes "Install." Select a recent version of the package. Note: The nfs-server is fairly new, so if you don't see it in the 
* mkdir /kissnfs/hdd/audio
Net category, back out and try a different Cygwin server. 

Adding cygrunsrv:
This utility lets you configure the nfs server as a Windows system service. Click on the + sign next to the Admin category. 
Scroll down to find the cygrunsrv item and click on the word "Skip". Select a recent version of the package. 

Adding mc:
This utility is easy to edit the config files. Click on the + sign next to the Utils category.
Scroll down to find the nc item and click on the word "Skip".
  • next (if it fail, choose a other mirror till your done)
  • wait til the download is complete
  • press complete
  • dubble click the cygwin icon
Run the configuration script

In the cygwin shell window, run: 

	/usr/bin/nfs-server-config A number of warnings will appear about you installing cygwin for a single user, even
though you didn't. You can ignore these complaints. 

Editing the config file

Export directories

Edit: 

	/etc/exports This is where you export local directories. 

This example exports the hardcoded nfs shares for stage2

	/kissnfs			(rw,map_static=/etc/nfs/server.map,all_squash)
  • use the mc command to edit the /etc/exports file (you can also use a other editor if you have this installed)
  • be sure to restart the service after changing this file
cygrunsrv --start mountd
cygrunsrv --start nfsd
cygrunsrv --start portmap 

also you need to create the directory with the folowing commands

* mkdir /kissnfs
* mkdir /kissnfs/hdd
* mkdir /kissnfs/systempart


(you can also restart computer)

Linux

Use your favorite packaging system (RPM, DEB, YAST) to check whether your system has installed a NFS server package. If not install it.

Second step is to create the directories that will be exported to your KiSS player:

mkdir /kissnfs
mkdir /kissnfs/hdd
mkdir /kissnfs/systempart

Now you must tell your NFS server about these directories so it will export them to your KiSS player:

vi /etc/exports
/kissnfs 10.0.0.100(rw,async,no_root_squash,no_subtree_check)
exportfs -rv

Replace 10.0.0.100 with your player's IP address.

You may want to create the following directories and put your media files in, so the player will show them in the file browser:

mkdir /kissnfs/hdd/audio
mkdir /kissnfs/hdd/pictures
mkdir /kissnfs/hdd/video