Another NFS question
Author
Discussion

TheExcession

Original Poster:

11,669 posts

277 months

Friday 29th October 2004
quotequote all
If a Server writes a file into a Share - it seems to take upto a minute before a client with a mount on that share sees a copy of the new file - e.g. using ls.

Is there an easy way to ensure that the client can see the new file immediately?


thanks
Ex

fatsteve

1,143 posts

304 months

Friday 29th October 2004
quotequote all
TheExcession said:
If a Server writes a file into a Share - it seems to take upto a minute before a client with a mount on that share sees a copy of the new file - e.g. using ls.

Is there an easy way to ensure that the client can see the new file immediately?


thanks
Ex


Whoah!, thats horrendous, should be pretty much instantaneous (unless you're doing something dreadfull like linking the servers via dialup). What flavour of Unix are you using?

TheExcession

Original Poster:

11,669 posts

277 months

Friday 29th October 2004
quotequote all
fatsteve said:



TheExcession said:
If a Server writes a file into a Share - it seems to take upto a minute before a client with a mount on that share sees a copy of the new file - e.g. using ls.

Is there an easy way to ensure that the client can see the new file immediately?


thanks
Ex





Whoah!, thats horrendous, should be pretty much instantaneous (unless you're doing something dreadfull like linking the servers via dialup). What flavour of Unix are you using?




I knew you were gonan ask that - RedHat 6.2 (shivers)

For some operations it is instantaneous - ie if I know the file name and cat it then it works perfectly -
however if I touch a file on the server and then do ls on the client it can take ages.

many thanks
Ex

FEPB is the server - FEPA the client

[root@FEPB /root]# cd /home/Esas/FEPB/InBasket
[root@FEPB InBasket]# ls
tmp
[root@FEPB InBasket]# date
Fri Oct 29 13:16:09 UTC 2004
[root@FEPB InBasket]# touch file1
[root@FEPB InBasket]# date
Fri Oct 29 13:16:43 UTC 2004
[root@FEPB InBasket]#





[root@FEPA InBasket]# more /etc/fstab
/dev/ida/c0d0p6 / ext2 defaults 1 1
/dev/cdrom /mnt/cdrom iso9660 noauto,owner,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,owner 0 0
none /proc proc defaults 0 0
none /dev/pts devpts gid=5,mode=620 0 0
/dev/ida/c0d0p5 swap swap defaults 0 0
xxx.xxx.xxx.xxx:/home/Esas/FEPB/InBasket /home/Esas/FEPB/InBasket nfs rw 0 0
[root@FEPA InBasket]# cd /home/Esas/FEPB/InBasket
[root@FEPA InBasket]# ls
tmp
[root@FEPA InBasket]# date
Fri Oct 29 13:16:08 UTC 2004
[root@FEPA InBasket]# ls
tmp
[root@FEPA InBasket]# ls
tmp
[root@FEPA InBasket]# ls
tmp
[root@FEPA InBasket]# date
Fri Oct 29 13:16:30 UTC 2004
[root@FEPA InBasket]# ls
tmp
[root@FEPA InBasket]# ls
tmp
[root@FEPA InBasket]# date
Fri Oct 29 13:16:39 UTC 2004
[root@FEPA InBasket]# ls
tmp
[root@FEPA InBasket]# ls
tmp
[root@FEPA InBasket]# date
Fri Oct 29 13:16:54 UTC 2004
[root@FEPA InBasket]# ls
tmp
[root@FEPA InBasket]# ls
tmp
[root@FEPA InBasket]# date
Fri Oct 29 13:17:04 UTC 2004
[root@FEPA InBasket]# ls
tmp
[root@FEPA InBasket]# ls
file1 tmp
[root@FEPA InBasket]# date
Fri Oct 29 13:17:12 UTC 2004
[root@FEPA InBasket]#




>> Edited by TheExcession on Friday 29th October 16:10

fatsteve

1,143 posts

304 months

Friday 29th October 2004
quotequote all
Do you have an other comms between the 2 servers, so you can isolate it to an NFS issue. It could be a general comms issue

TheExcession

Original Poster:

11,669 posts

277 months

Friday 29th October 2004
quotequote all
fatsteve said:
Do you have an other comms between the 2 servers, so you can isolate it to an NFS issue. It could be a general comms issue


They are on a dual 100MBit LAN - plugged into the same switches...

strange init?

cheers
Ex

icamm

2,153 posts

287 months

Friday 29th October 2004
quotequote all
Sounds like an NFS caching issue to me.

zumbruk

7,848 posts

287 months

Friday 29th October 2004
quotequote all
Are the mounts "hard" or "soft"?

TheExcession

Original Poster:

11,669 posts

277 months

Tuesday 2nd November 2004
quotequote all
zumbruk said:
Are the mounts "hard" or "soft"?


I beleieve they are hard mounts - the default setting?

best
Ex

TheExcession

Original Poster:

11,669 posts

277 months

Tuesday 2nd November 2004
quotequote all
icamm said:
Sounds like an NFS caching issue to me.


Indeedy - but wot to do?

best
Ex

icamm

2,153 posts

287 months

Tuesday 2nd November 2004
quotequote all
You can switch of caching for each NFS mount. I think the mount option is noac

eg: mount -F server:/filesystem /filesystem -o noac

Check the man page for nfs (mount_nfs?).