* basic SOHO NFS/autofs setup for noob help
@ 2008-01-02 18:42 Jerzy Jalocha N
2008-01-02 18:58 ` Jeff Moyer
2008-01-02 21:05 ` Jerzy Jalocha N
0 siblings, 2 replies; 7+ messages in thread
From: Jerzy Jalocha N @ 2008-01-02 18:42 UTC (permalink / raw)
To: autofs
Hi, I am trying to set-up the following (simple?) configuration:
* one server which has a mounted partition (/shared) exported with
NFS. This holds some files (office, etc) which will be shared by all
users.
* a few (4) clients which should autofs this partition as '/shared'.
I am able to manually mount the partition on the clients:
$ sudo mount 192.168.1.20:/shared /shared
And I am able to mount with fstab. (That's how it's running now.)
But I am unable to automount. Whatever the combinations of options I
try ('ls /shared/', or 'ls /shared/subdir', or 'cd /shared : ls'), it
shows nothing.
I guess, It has to do with the combination of
mounting/exporting/autofs options, but I don't really know how to
debug this part.
This is how I've set it up right now:
* server:/etc/fstab
/dev/sdb1 /shared ext3 rw,sync,suid,nodev,exec,auto,nouser 0 3
* server:/etc/exports
/shared 192.168.1.0/24(rw,sync,no_root_squash,no_subtree_check)
* client:/etc/auto.master
shared 192.168.1.20:/shared --ghost --timeout=60
* client:/etc/auto.shared
shared fstype=nfs,rw,sync,soft,intr,rsize=8192,wsize=8192 192.168.1.20:/shared
Everytime I change some configuration file, I restart the necessary
services. (/etc/init.d/xxx restart). When testing autofs, I remove the
entry from fstab.
The only debugging information I know of:
$ sudo /etc/init.d/autofs status
Configured Mount Points:
------------------------
/usr/sbin/automount --timeout=300 /net program /etc/auto.net
Active Mount Points:
--------------------
/usr/sbin/automount --pid-file=/var/run/autofs/_shared.pid
--timeout=60 --ghost /shared file /etc/auto.shared
And '/proc/mounts' while autofs is running:
automount(pid8181) /shared autofs
rw,fd=4,pgrp=8181,timeout=60,minproto=2,maxproto=4,indirect 0 0
I've tried all possible combinations of options, and I've been working
on this for several weeks now, without success. I'm really a noob, but
I've read everything I could find, including the manual pages of
mount, exports, nfs, fstab, the excellent Redhat reference guide, and
forums. I've also asked for help on two forums without success so far:
* from post 19 onwards:
http://www.linuxquestions.org/questions/linux-networking-3/small-linux-only-network-607346/page2.html
* http://ubuntuforums.org/showthread.php?t=646572
I am trying really hard to understand what I'm doing, and to learn as
much as possible, but I'm really stuck here. Could anyone with more
experience please guide me with this?
Thanks!
-Jerzy
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: basic SOHO NFS/autofs setup for noob help
2008-01-02 18:42 basic SOHO NFS/autofs setup for noob help Jerzy Jalocha N
@ 2008-01-02 18:58 ` Jeff Moyer
2008-01-02 19:10 ` Jerzy Jalocha N
2008-01-02 21:05 ` Jerzy Jalocha N
1 sibling, 1 reply; 7+ messages in thread
From: Jeff Moyer @ 2008-01-02 18:58 UTC (permalink / raw)
To: Jerzy Jalocha N; +Cc: autofs
"Jerzy Jalocha N" <jjalocha@gmail.com> writes:
> Hi, I am trying to set-up the following (simple?) configuration:
> * one server which has a mounted partition (/shared) exported with
> NFS. This holds some files (office, etc) which will be shared by all
> users.
> * a few (4) clients which should autofs this partition as '/shared'.
>
> I am able to manually mount the partition on the clients:
> $ sudo mount 192.168.1.20:/shared /shared
> And I am able to mount with fstab. (That's how it's running now.)
>
> But I am unable to automount. Whatever the combinations of options I
> try ('ls /shared/', or 'ls /shared/subdir', or 'cd /shared : ls'), it
> shows nothing.
>
> I guess, It has to do with the combination of
> mounting/exporting/autofs options, but I don't really know how to
> debug this part.
>
> This is how I've set it up right now:
>
> * server:/etc/fstab
> /dev/sdb1 /shared ext3 rw,sync,suid,nodev,exec,auto,nouser 0 3
>
> * server:/etc/exports
> /shared 192.168.1.0/24(rw,sync,no_root_squash,no_subtree_check)
>
> * client:/etc/auto.master
> shared 192.168.1.20:/shared --ghost --timeout=60
Try:
auto.master:
/shared /etc/auto.shared
/etc/auto.shared:
* -hard,intr 192.168.1.20:/shared/&
Cheers,
Jeff
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: basic SOHO NFS/autofs setup for noob help
2008-01-02 18:58 ` Jeff Moyer
@ 2008-01-02 19:10 ` Jerzy Jalocha N
2008-01-02 19:22 ` Jeff Moyer
0 siblings, 1 reply; 7+ messages in thread
From: Jerzy Jalocha N @ 2008-01-02 19:10 UTC (permalink / raw)
To: autofs
> Try:
>
> auto.master:
> /shared /etc/auto.shared
>
> /etc/auto.shared:
> * -hard,intr 192.168.1.20:/shared/&
Thanks, Jeff, but sorry, that doesn't work. It's one of the first
settings I had. Tried it again now, but without success. 'ls' just
shows nothing, even with 'cd /shared'.
Any other ideas?
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: basic SOHO NFS/autofs setup for noob help
2008-01-02 19:10 ` Jerzy Jalocha N
@ 2008-01-02 19:22 ` Jeff Moyer
2008-01-02 19:37 ` Jerzy Jalocha N
0 siblings, 1 reply; 7+ messages in thread
From: Jeff Moyer @ 2008-01-02 19:22 UTC (permalink / raw)
To: Jerzy Jalocha N; +Cc: autofs
"Jerzy Jalocha N" <jjalocha@gmail.com> writes:
>> Try:
>>
>> auto.master:
>> /shared /etc/auto.shared
>>
>> /etc/auto.shared:
>> * -hard,intr 192.168.1.20:/shared/&
>
> Thanks, Jeff, but sorry, that doesn't work. It's one of the first
> settings I had. Tried it again now, but without success. 'ls' just
> shows nothing, even with 'cd /shared'.
>
> Any other ideas?
Of course it shows nothing. What directories exist under /shared on
the server? Try to cd to one of those.
If you want the directory names to appear in a listing of /shared,
then you would have to have a separate key in the auto.shared map for
each of the directories (instead of using the wildcard key).
-Jeff
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: basic SOHO NFS/autofs setup for noob help
2008-01-02 19:22 ` Jeff Moyer
@ 2008-01-02 19:37 ` Jerzy Jalocha N
2008-01-02 20:45 ` muzzol
0 siblings, 1 reply; 7+ messages in thread
From: Jerzy Jalocha N @ 2008-01-02 19:37 UTC (permalink / raw)
To: autofs
> Of course it shows nothing. What directories exist under /shared on
> the server? Try to cd to one of those.
Sorry, I am not very clear what I should expect from autofs, so I
didn't post everything I've tested. But I've also tried to show the
contents of a sub-directory without success:
$ ls /shared/subdir
or
$ cd /shared/subdir
(for some directory I know that exists.)
But this just takes around 10 min to tell me that there's "No such
file or directory".
> If you want the directory names to appear in a listing of /shared,
> then you would have to have a separate key in the auto.shared map for
> each of the directories (instead of using the wildcard key).
Thanks, this will surely be useful once I get it running. :)
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: basic SOHO NFS/autofs setup for noob help
2008-01-02 19:37 ` Jerzy Jalocha N
@ 2008-01-02 20:45 ` muzzol
0 siblings, 0 replies; 7+ messages in thread
From: muzzol @ 2008-01-02 20:45 UTC (permalink / raw)
To: Jerzy Jalocha N; +Cc: autofs
En/na Jerzy Jalocha N ha escrit:
>> Of course it shows nothing. What directories exist under /shared on
>> the server? Try to cd to one of those.
>
> Sorry, I am not very clear what I should expect from autofs, so I
> didn't post everything I've tested. But I've also tried to show the
> contents of a sub-directory without success:
> $ ls /shared/subdir
> or
> $ cd /shared/subdir
> (for some directory I know that exists.)
> But this just takes around 10 min to tell me that there's "No such
> file or directory".
>
try
showmount -e <nfs server>
--
========================
^ ^
O O
(_ _)
muzzol(a)muzzol.com
========================
jabber id: muzzol(a)jabber.dk
========================
No atribueixis qualitats humanes als ordinadors.
No els hi agrada.
========================
"El gobierno español sólo habla con terroristas, homosexuales y
catalanes, a ver cuando se decide a hablar con gente normal"
Jiménez Losantos
========================
<echelon spamming>
bomb terrorism bush aznar teletubbies
</echelon spamming>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: basic SOHO NFS/autofs setup for noob help
2008-01-02 18:42 basic SOHO NFS/autofs setup for noob help Jerzy Jalocha N
2008-01-02 18:58 ` Jeff Moyer
@ 2008-01-02 21:05 ` Jerzy Jalocha N
1 sibling, 0 replies; 7+ messages in thread
From: Jerzy Jalocha N @ 2008-01-02 21:05 UTC (permalink / raw)
To: autofs
!!!! SOLVED !!!!
The following entry in '/etc/auto.shared' works correctly:
* -fstype=nfs,rw,sync,soft,intr,rsize=8192,wsize=8192 192.168.1.20:/shared/&
What I had wrong right before, was the IP address.
I had tested this configuration several times before, but since 'cd
/shared' and 'ls /shared' didn't show anything, I thought it wasn't
working. 'ls /shared/subdir' now works perfectly, and probably always
has!
Thank you so much, jeff and muzzol, for your help. You both provided
me the necessary pieces for making this work.
(I'll still read further, to understand it better.)
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2008-01-02 21:05 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-02 18:42 basic SOHO NFS/autofs setup for noob help Jerzy Jalocha N
2008-01-02 18:58 ` Jeff Moyer
2008-01-02 19:10 ` Jerzy Jalocha N
2008-01-02 19:22 ` Jeff Moyer
2008-01-02 19:37 ` Jerzy Jalocha N
2008-01-02 20:45 ` muzzol
2008-01-02 21:05 ` Jerzy Jalocha N
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.