Install and config nfs server ver 4

#opkg install nfs-kernel-server

the current version is nfs v4
mkdir /storage/usb
then edit /.opt/etc/export, insert " no_root_squash"and “fsid=0”, /storage/usb is your shared location, “no_root_squash” for ntfs filesystem access . NTFS is non-POSIX permissions compliant, you must access the share as root. (NFS seems not support fuse system like “ntfs-3g”,“exfat-3g”,and removable drive does not work well in /var/media/ )
# vi /.opt/etc/export
/storage/usb *(fsid=0,ro,no_root_squash,insecure,no_subtree_check,sync)

and now,if you start nfs-kernal-server it will print “rpc.nfsd: unable to set any sockets for nfsd”
so you need to

# vi /opt/etc/init.d/S57nfs-kernel-server
find
rpc.nfsd --no-nfs-version 4 --no-tcp 1
rpc.mountd --no-nfs-version 4 --no-tcp

replace with

rpc.nfsd --nfs-version 4  1
rpc.mountd --nfs-version 4	/*enable nfs ver 4*/

and then mount drive and start nfs server:

#mount /dev/sda1 /storage/usb/
#/opt/etc/init.d/S57nfs-kernel-server restart

#rpcinfo -p localhost

3 tcp 2049 nfs
4 tcp 2049 nfs

now the nfs server is running success!

Why not using build in NFS server?

the sample file /storage/.config/exports.sample is absent in my system,and ntfs filesystem,usb drive and fsid error often with trouble