Buffalo NAS-Central Forums

Welcome to the Linkstation Wiki community
It is currently Fri Jun 22, 2018 5:41 pm

All times are UTC+01:00




Post new topic  Reply to topic  [ 20 posts ]  Go to page 1 2 Next
Author Message
 Post subject: NFS-Server
PostPosted: Thu Aug 11, 2005 10:56 pm 
Offline
Newbie

Joined: Thu Aug 11, 2005 10:51 pm
Posts: 12
Location: Germany
Hello,

I am new into this forum. Today I bought a Linkstation and I already upgraded my firmware to mipsel-openlink-052. Who can I now install a NFS-server (> 2 GB Files) on my linkstation. I am not very famliar with Linux.

Can anybody help? Thanks a lot!

Stefan


Top
   
 Post subject: Re: NFS-Server
PostPosted: Thu Aug 11, 2005 11:45 pm 
Offline
Regular Member
User avatar

Joined: Sun Jul 10, 2005 9:12 pm
Posts: 192
Location: Aachen, Germany
> Can anybody help?

Do a search on the forms first. This has been asked before, e.g. in [url=3_42_0.html]this thread[/url] or [url=3_45_0.html]here[/url] for debianized LinkStations. You need the appropriate kernel modules - you should be able to get them from http://www.voicenet.com/~jceklosk/linkstation-2.html.

They worked for me, but I don't know if the kernel version has changed in the latest OpenLink versions. You also need a way to set up the startup scripts (with Debian that's already done). Maybe someone with OpenLink experiences can do that and create a Wiki article. Or modify the existing one at http://buffalo.nas-central.org/Articles/MIPSelNFSServer, as the userspace NFS server is not that useful if you deal with large files.


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 6:23 am 
Offline
Newbie

Joined: Thu Aug 11, 2005 10:51 pm
Posts: 12
Location: Germany
I saw the discussion in the forum you had with Maik, but it was very confusing for me, because I am not very familiar with LINUX. The best would be, to have a very simple step by step installation instruction for users with very small LINUX knowledge.

What I did: I already downloaded the files from www.voicenet.com. Where should I copy them on my Linkstation? How to install? What has to be done next?

Thanks a lot!

Stefan


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 2:03 pm 
Offline
Regular Member
User avatar

Joined: Sun Jul 10, 2005 9:12 pm
Posts: 192
Location: Aachen, Germany
> Where should I copy them on my Linkstation?

First you try if they do work for you. So move the archive to your linkstation, then ssh into the box. Now switch to the directory where the archive is and unpack it with something like 'tar -xvzf nfs-1.0.0-link2-jfc-1.0.2-alpha.tar.gz' - if you ant to, you can move that into your home directory wit 'mv nfs-1.0.0-link2-jfc-1.0.2-alpha ~/nfs-mods-tools'.

Now you need an '/etc/exports', where you define the shares you want to export on your LinkStation. Put each share on a single line, mine looks like

/share/nfs 192.168.1.0/24(insecure,rw,sync,all_squash,anongid=2000,a nonuid=1100)

(That's "anonuid" above, I don't know why this forum insists on adding a space there.)

This shares the '/share/nfs' directory with all computers on my subnet, the options are "insecure" for Mac OS X (this is not insecure, it just allows the use of ports > 1024), "rw" for write access and "all_squash" just makes sure, that everything written to this share gets the following uid/gid. You have to make sure that this user/group has write permissions for your local share and that they possibly exist on the client system (or you need appropriate permissions for all users).

If you have your UID set up the same on all systems, you can also just do ...

/share/nfs 192.168.1.0/24(rw,sync,root_squash)

... to keep them - here the root user will get translated as "nobody", which is the default.

Now you've got your exports file, you just cd into the unpacked 'nfs-mods-tools' directory and run the 'do_install' script. You need to be root for this to work. Now you should be able to du an nfs mount from another computer. You can also have a look at 'showmount -e' to see the exports list, 'rpcinfo -p' to see details of the portmapper and 'lsmod', which should show the nfs kernel modules being loaded.

> How to install?

When you made sure it works, you need to adapt the startup scripts for your OpenLink distribution and you probably also want to put the nfs to a better location. I don't have OpenLink and I don't know how it's set up at boot time. Maybe someone else can fill in that info.


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 4:09 pm 
Offline
Newbie

Joined: Thu Aug 11, 2005 10:51 pm
Posts: 12
Location: Germany
Up to creating the exports file and running the installation script, everything looks fine.

if I try showmount -e the following error message appears:

root@HD-HLAN60C:/nfs-mods-tools/nfs-utils# ./showmount -e
rpc mount export: RPC: Unable to receive; errno = Connection refused

What did I wrong? If I use lsmod the following message appears:

root@HD-HLAN60C:/nfs-mods-tools/nfs-utils# lsmod
Module Size Used by Tainted: P
nfsd 89312 1
nfs 90624 0 (unused)
lockd 61648 1 [nfsd nfs]
sunrpc 78672 1 [nfsd nfs lockd]
idtinfo 12412 0 (unused)

rpcinfo -p is displaying the following messages:

root@HD-HLAN60C:/nfs-mods-tools/nfs-utils# rpcinfo -p
program vers proto port
100000 2 tcp 111
100000 2 udp 111
100005 1 udp 902
100005 1 tcp 905
100005 2 udp 902
100005 2 tcp 905
100005 3 udp 902
100005 3 tcp 905
100024 1 udp 906
100024 1 tcp 909
100003 2 udp 2049
100003 3 udp 2049
100003 2 tcp 2049
100003 3 tcp 2049
100021 1 udp 1024
100021 3 udp 1024
100021 4 udp 1024
100021 1 tcp 1024
100021 3 tcp 1024
100021 4 tcp 1024

What went wrong? Do you have an idea? Thanks a lot for your support so far.

Stefan


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 4:27 pm 
Offline
Regular Member
User avatar

Joined: Sun Jul 10, 2005 9:12 pm
Posts: 192
Location: Aachen, Germany
Hmm, it looks like your modules did load correctly. Could you show us your '/etc/exports' file? And what do you get from the command 'exportfs -ra'? Ans as you read the other forum posts, you probably already checked your '/var/lib/nfs/rmtab' being a normal file? What's the error message from the remote computer?


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 4:49 pm 
Offline
Newbie

Joined: Thu Aug 11, 2005 10:51 pm
Posts: 12
Location: Germany
Here is my exports file:

mnt/hda/share/filme 192.168.0.250/24(rw,sync,root_squash)

The command "exportfs -ra" returns no message.

The error message from my Dbox2 is, when I try to mount my share:

/var # mount 192.168.0.250:filme /var/mnt/movies
mount: RPC: Unable to receive; errno = Connection refused
mount: nfsmount failed: Bad file descriptor
mount: Mounting 192.168.0.250:filme on /var/mnt/movies failed: Invalid argument

The file rmtab is existing (here is the direcotry):

root@HD-HLAN60C:/var/lib/nfs# ls -la
total 7
drwxr-xr-x 5 root root 1024 Feb 26 09:35 .
drwxr-xr-x 6 root root 1024 Jan 26 2004 ..
-rw-r--r-- 1 root root 168 Feb 26 09:35 etab
drwxr-xr-x 2 root root 1024 Nov 6 2003 rmtab
drwx------ 2 root root 1024 Feb 26 08:53 sm
drwx------ 2 root root 1024 Feb 26 08:53 sm.bak
-rw------- 1 root root 4 Feb 26 08:53 state
---------- 1 root root 0 Feb 26 08:55 xtab

What made I wrong?


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 5:03 pm 
Offline
Regular Member
User avatar

Joined: Sun Jul 10, 2005 9:12 pm
Posts: 192
Location: Aachen, Germany
> Here is my exports file:
>
> mnt/hda/share/filme 192.168.0.250/24(rw,sync,root_squash)


O.K. - there should be a slash in front of the path, as it's an absolute one. Usually the network is written with a zero at the end (it would be 192.168.0.0/24), but yours should work, too. And as you're using you dbox as a client, you might run into problems with "root_squash", because those MPEG transport streams are written by the root user. The best thing to do is setting up a special dbox user/group and use that as anonuid/anongid - that's the way I do it with my dbox.

> /var # mount 192.168.0.250:filme /var/mnt/movies

This is not correct, as the path of your share seems to be '/mnt/hda/share/filme' (I guess 192.168.0.250 is your LinkStation), so that line should read:

# mount 192.168.0.250:/mnt/hda/share/filme /var/mnt/movies

And finally:

> The file rmtab is existing

No, it doesn't exist. It's a directory - that's the same error Maik got in [url=3_42_0.html]this thread[/url]. Remove it with 'rm -r /var/lib/nfs/rmtab', it should be created when you restart your NFS server.


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 5:07 pm 
Offline
Newbie

Joined: Thu Aug 11, 2005 10:51 pm
Posts: 12
Location: Germany
OK, but one more stupid question ....

How can I restart the NFS-Server?


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 5:21 pm 
Offline
Regular Member
User avatar

Joined: Sun Jul 10, 2005 9:12 pm
Posts: 192
Location: Aachen, Germany
> How can I restart the NFS-Server?

It should be enough to do 'exportfs -r' to sync your exports with the '/etc/exports' file.


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 5:32 pm 
Offline
Newbie

Joined: Thu Aug 11, 2005 10:51 pm
Posts: 12
Location: Germany
It still happens the same, when I try to mount my share:

/var # mount 192.168.0.250:/mnt/hda/share/filme /var/mnt/movies
mount: RPC: Unable to receive; errno = Connection refused
mount: nfsmount failed: Bad file descriptor
mount: Mounting 192.168.0.250:/mnt/hda/share/filme on /var/mnt/movies failed: In
valid argument

I now realy made everything 1:1, but when check my share with 'showmount -e' the following error appears:

root@HD-HLAN60C:/etc# showmount -e
rpc mount export: RPC: Unable to receive; errno = Connection refused

My export file now is:

/mnt/hda/share/filme 192.168.0.0/24(rw,sync,all_squash,anongid=2000,anonuid=1100)

Any other idea?


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 6:22 pm 
Offline
Regular Member
User avatar

Joined: Sun Jul 10, 2005 9:12 pm
Posts: 192
Location: Aachen, Germany
> My export file now is:
>
> /mnt/hda/share/filme 192.168.0.0/24(rw,sync,all_squash,anongid=2000,anonuid=1100)


When you use it that way, you have to make sure that a user with uid 1100 and a group with gid 2000 does exist and that they are allowed to access your share '/mnt/hda/share/filme'. If this is really the problem, you can try something like ...

/mnt/hda/share/filme   192.168.0.0/24(rw,sync,no_root_squash)

... in your '/etc/exports'. This permits the 'root' user from your dbox to behave like 'root' on your LinkStation. This way access permissions shouldn't be a problem, as 'root' will be able to read and write from/to your share. Anyway, a 'showmount' has to work.


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 8:22 pm 
Offline
Newbie

Joined: Thu Aug 11, 2005 10:51 pm
Posts: 12
Location: Germany
Many thanks! Everything works. I just recored a movie on my LinkStation via NFS share. Also movieplayer of my DBox is working. That's fine ...

How can I start automatically the NFS server with its share while booting? Are there any suggestions to speed up the NFS server?

Thanks a lot again.


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 9:59 pm 
Offline
Regular Member
User avatar

Joined: Sun Jul 10, 2005 9:12 pm
Posts: 192
Location: Aachen, Germany
> How can I start automatically the NFS server with its share while booting?

Well, that's something your fellow OpenLink users should answer. You might have a look at your '/etc/init.d' directory and the corresponding '/etc/rc.d' - I don't know which runlevel is used for normal operation. My first try would be copying the 'do_install' script into '/etc/init.d/' and add symlinks to that inside all those '/etc/rc.d/rcx.d', maybe something like 'S80nfsd'.

> Are there any suggestions to speed up the NFS server?

Why? For the dbox it doesn't matter, as the bottleneck is its 10BaseT (half duplex) network interface. You could probably tune the NFS parameters to your special needs (it seems to be mainly large files), but that requires some knowledge of NFS and networking in general. You can read the articles linked from [url=4_59_0.html]my previous post[/url] for some performance questions, although that's quite Mac/AFP centric.


Top
   
 Post subject: Re: NFS-Server
PostPosted: Fri Aug 12, 2005 10:09 pm 
Offline
Newbie

Joined: Thu Aug 11, 2005 10:51 pm
Posts: 12
Location: Germany
OK! Copying the do_install file is no problem. But what is a 'symlink', and how can I add one?

Regarding the tuning: I will read some of these articles. But I think, the NFS-Server is fast enough after my first tests. Thanks


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 20 posts ]  Go to page 1 2 Next

All times are UTC+01:00


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Limited