SliTaz SliTaz Forum

You are not logged in.

#1 2012-07-12 14:45:18

Jarachnae
Member
Registered: 2012-07-11
Posts: 6

NFS ?

Bonjour,

Encore moi ;-)

Alors voila : je tente de mettre en place un accès vers un répertoire partagé sur notre réseau, via NFS.

Alors que sur les autres machines, il n'y a aucun soucis, là, avec le même type exactement de config, mon Slitaz n'arrive pas à accéder au répertoire.

Les données :

- le serveur est sous Debian, avec NFS 3.

- j'ai bien changé le fichier export de ce serveur

- j'ai bien relancé exportfs

- du côté du SLitaz, j'ai bien changé mon fstab

- quand je lance un mount -a sur le Slitaz, il me dit : "an incorrect mount option was specify"... alors que les options sont les mêmes pour toutes les autres machines, et que sur les autres machines (sous Ubuntu), ça fonctionne très bien...

J'ai même essayé de changer lesdites options... rien à faire...

Quelqu'un peut m'aider ? En pas à pas...

J.

Offline

#2 2012-07-13 18:04:22

renstyle
Member
Registered: 2012-07-13
Posts: 7

Re: NFS ?

salutations,

J'ai couru cette réponse travers google translate (anglais), désolé si le processus grisé le libellé.

Si vous avez du succès avec les montages NFS de travail pour non-SliTaz machines, * devrait * signifie les paramètres (les exportations / nfs / rpc) sur la machine exportatrice sont OK.

Le "nolock" et "TCP" options semblent être nécessaires pour NFS au travail:

mount-t nfs hmm machine à distance / répertoire / local / répertoire-o tcp, nolock

ci-dessus a travaillé pour moi la connexion à slackware, fedora, la menthe, et les exportations Debian (tous les vers. nfs = 3).

espérons que cette aide ...

Offline

#3 2012-07-17 10:22:23

Jarachnae
Member
Registered: 2012-07-11
Posts: 6

Re: NFS ?

Hello,

OK, let's do it in English (not sure I understood every thing under the automated translation, sorry).

So, at work, we have a Ubuntu / Lubuntu network with NFS (NFS 3).

We have an old computer, and I decided to put it under SlitaZ.

Keeping the very same options of the config files (/etc/exports for the distant directory and /etc/fstab in the SlitaZ computer), the SlitaZ system keeps telling "an incorrect mount option was specify".

In the exports file, : options are : rw,all_squash,no_subtree_check

In the fstab file : user,auto

What's going on ?

Thanks...

J.

Offline

#4 2012-07-17 13:03:30

renstyle
Member
Registered: 2012-07-13
Posts: 7

Re: NFS ?

I assume you have already tested the nfs mount being exported, ensured that you can mount this on a different machine.  That shows the exports should be ok.  You can verify this using "exportfs -f" (which will flush the cache) and then "exportfs -r" (which should re-read).  Exportfs invoked alone should display which exports are active.

On the slitaz box, I've had to enter the -o tcp,nolock to allow my NFSv3 mounts to work:

mount -t nfs remote-machine:/nfs/export /local/nfs/mountpoint -o tcp,nolock

When I type this in, then hit enter, I get no errors, just a prompt.  The mount works for rw.

I'd suggest ensuring you can mount the export at the cmdline before you go editing the /etc/fstab file, tho once you have the correct options from the cmdline creating the effective line in fstab is trivial...

On my SliTaz box I've chosen to bring up the NFS mounts using an init.d script, gives me the option to change the mountpoint by parsing /proc/cmdline for a different parameter.  I do a frugal install tho, all non-home info is ram-based...

Offline

#5 2012-07-17 13:28:55

Jarachnae
Member
Registered: 2012-07-11
Posts: 6

Re: NFS ?

It did just work really fine, trying it in command-line. So, I tried in the fstab, and it worked well too.

But there is still a very tiny element : how do I make it mounting automatically (the "auto" option in fstab doesn't seem working...) I have to do the "mount -a" thing to access the NFS parts.

But a big thank to you, whatsoever !

Offline

#6 2012-07-17 16:59:07

renstyle
Member
Registered: 2012-07-13
Posts: 7

Re: NFS ?

Perhaps my line about the triviality of the fstab line was a bit premature! :-)

Does your fstab line look anything similar to this:

nfs-server:/mount/in/exports    /place/to/mount    nfs nfsvers=3,rw,tcp,nolock,no_subtree_check 0 0

that's all one line.  The important parts to include are those tcp,nolock options.  The others *may* not be needed (but shouldn't hurt).

I could be totally barking up the wrong tree, since I use an external script to bring up the nfs mounts.  As with most things in the *nix world... "there is always more than one way to do it" :-)

There is also a chance that the init script that mounts the drives is only seeking out local storage (USB key, CD, hdd, etc) and skipping out on the other mounts. 

Maybe changing a standard "mount" to a "mount -a" in the startup scripts (rcS and possibly others).  Don't have my install in front of me right now for better answers...

Excellent to hear the mount itself is working, that's well over half of the problem solved.

====

I've done a bit more digging.  Check out your dmesg output.  It is possible that your network drivers are not "up" and loaded when the filesystems are mounted, so nfs mount would fail.  I ran this by one of our sysadmins, and he had the exact same issue trying to use the "auto" option. 

His solution: Add the noauto option to the fstab entries, and put the mount commands in /etc/rc.d/rc.local (basically what I had mentioned before).

At least you know it will work! :-)

Offline

#7 2012-07-18 09:16:57

Jarachnae
Member
Registered: 2012-07-11
Posts: 6

Re: NFS ?

Hello,

In fact, my fstab line looks like :

nfs-server:/mount/in/exports    /place/to/mount    nfs rw,tcp,nolock,nfsvers=3 0 0

because it says no-subtree_check is not a valide option

(but previously, it was only with 2 option, tcp and nolock, and worked the same it seems)

Thank you for all that !

No message through dmesg concerning any missed mounting NFS partition.

Last : I couldn't find the "/etc/rc.d"... All I got in /etc/ is a rcS.conf, that has got a RUN_SCRIPTS filled with "bootopts.sh network.sh system.sh local.sh"

I think I have to had the "mount -a" in one of these files, but I don't know which one, and I don't know where they are.

I could probably create another shell file, with just the "mount -a" instruction in it, but the question is : where do I put it ? ;-)

Many thanks for the time you spend with my questions !

Best

J.

Offline

Registered users online in this topic: 0, guests: 1
[Bot] ClaudeBot

Board footer

Powered by FluxBB
Modified by Visman

[ Generated in 0.025 seconds, 8 queries executed - Memory usage: 1.55 MiB (Peak: 1.77 MiB) ]