strange thing with nfs
when i mount on pc A a nfs-share wich is on the disk of pc B,
and i shutdown pc B then i get the following :
-konquerer will not show the root-dir.
after a while i don't even get the filename of subdirs.
-ksysguard gives only "888888....etc" in the status bar, and no data on
-i cannot unmount the share
i get kernel messages saying it's trying to mount and
in a console all is normal ( "ls / " and " top" work ok )
in the exports file on pc B there's only the (rw,sync) option.
rebooting pc B makes all normal again and then
i can unmount the share .
i think i have to change some setings somewhere , but
i can't find it.
any suggestions welcome .
mount the NFS directory with the "-o soft" option
hmmm.....from " man mount "
soft This option allows the kernel to time out if the nfs server is not
responding for some time. The time can be specified with timeo=time.
This option might be useful if your nfs server sometimes doesn't
respond or will be rebooted while some process tries to get a file
from the server. Usually it just causes lots of trouble.
it sais it should work, but also causes " lot's of trouble ".
maybe there's more options...
well.....using the " soft " option makes it a little better.
switching to the root dir causes a timeout of a few minutes,
but it won't hang.
on pc A the mount command gives
192.168.0.3:/home/packages on /diskhome type nfs (rw,soft,intr,addr=192.168.0.3)
but it's only kde app.'s that are bothered; cli works ok.
so maybe i should set smth. in kde.....?
Try automount your nfs share, it is not too hard to set (your kernel has to be
configured with autofs though, preferably as module)
- installpkg autofs
- create a /etc/auto.master file with the content :
so there is one :
save it as /etc/rc.d/rc.autofs
Then chmod +x it and /etc/rc.d/rc.autofs start, maybe add
' /etc/rc.d/rc.autofs start ' in rc.local
So try : konqueror /net/packages
well....been trying for hours to get it working.
are you sure the script is ok ?
it won't run ok.......
maybe someone can explain this part:
# Check for local maps to be loaded
if [ -f /etc/auto.master ]
echo "echo "check"" #<---- added by me
cat /etc/auto.master | sed -e '/^#/d' -e '/^$/d'| (
while read dir map options
if [ ! -z "$dir" -a ! -z "$map" \
-a x`echo "$map" | cut -c1` != 'x-' ]
echo "echo "check1 "" #<added by me
this function is called as " getmounts | sh "
i added two checks.
the first one is echoed, the 2.nd one not.
and it's after this that the command " automount" is issued
so that's never run.
I have used this script for a long time, it works fine
I added your line to test at the same place in rc.autofs
"check1" was echoed 3 times when I did rc.autofs restart
Could you post auto.master and auto.* associed file ?
! -z "$dir" : $dir must not be empty
! -z "$map" : $map must not be empty
x`echo "$map" | cut -c1` != 'x-' : this one seems complicated but not really,
first let see what is between the ` ` chars : echo "$map" | cut -c1
so it takes the first char in $map variable if $map was equal to "-fs", then
x`echo "$map" | cut -c1` != 'x-'
x- != 'x-' : so the test return false
(basically, if the first char of $map contains '-', the last test returns false)
And finally the -a connective option stands for the 3 expressions must returns true
like : expression1 && expression2 && expression3
thanks for the clear explanation.
i have these files :
when running the script with these files, we should get
$dir = /net
and that should work then....but it doesn't.
any idea ?
well.....i got it.
in the file /etc/auto.master i needed to put a return at the end of the line
( just hit enter )
thanks for the help/explanation.
it works nice :)
I would remove --timeout in auto.master to see if it works but frankly
I have no idea why /etc/auto.master does not pass the first test in
getmounts() function :
I am glad you get it working ;)
i think it's rather a stupid mistake.
took me 6 hours and i got the script almost memorised :D
Do the /net and /net/packages
directories have to be created? Or are they created by the automount scripts?
I have tried to do this following your instructions (ie. without creating the directories) and I get the following error:
[root@machine1 /]# cd /net/packages
bash: cd: /net/packages: No such file or directory
only /net; just use " #mkdir /net " to make it.
|All times are GMT -5. The time now is 02:55 PM.|