-1

On the client server the NFS mount on /oracle/r12/inst/apps/database1 works as expected, but /oracle/r12/apps does not. For example if I touch test in /oracle/r12/inst/apps/database1 the file test appears on both the client and the server, this is not the case with /oracle/r12/apps.

NFS Server /etc/exports

[root@nfs-server apps]# cat /etc/exports
/oracle/ x.x.x.x(rw,fsid=0,sync,nohide,no_subtree_check,no_wdelay,no_root_squash)
/oracle/r12/ x.x.x.x(rw,sync,no_wdelay,nohide,no_subtree_check,no_root_squash)
/oracle/r12/apps/ x.x.x.x(rw,sync,no_wdelay,nohide,no_subtree_check,no_root_squash)
/oracle/r12/inst/apps/ x.x.x.x(rw,sync,no_wdelay,nohide,no_subtree_check,no_root_squash)

NFS Client /etc/fstab

[root@nfs-client ~]# cat /etc/fstab
/dev/VolGroup00/LogVol00 /                       ext3    defaults        1 1
LABEL=/boot             /boot                   ext3    defaults        1 2
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
/dev/VolGroup00/LogVol01 swap                    swap    defaults        0 0
x.x.x.x:/oracle/r12/inst/apps/database1 /oracle/r12/inst/apps/database1 nfs defaults 1 2
x.x.x.x:/oracle/r12/apps /oracle/r12/apps nfs defaults 1 2

NFS Client output of df -h

[root@erl-ora-apps1 ~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/VolGroup00-LogVol00
                      274G   16G  244G   7% /
/dev/sda1              99M   61M   34M  65% /boot
tmpfs                 7.9G     0  7.9G   0% /dev/shm
x.x.x.x:/oracle/r12/apps
                      3.1T  2.5T  441G  86% /oracle/r12/apps
x.x.x.x:/oracle/r12/inst/apps/database1
                      3.1T  2.5T  441G  86% /oracle/r12/inst/apps/database1
에이바
  • 612
  • 4
  • 11
  • 34
  • 1
    Why are you exporting /oracle and /oracle/r12 if the first level you're mounting remotely is /oracle/r12/apps ? – John Jul 17 '13 at 17:55
  • I don't know, /etc/exports was already like that. Think those need to be removed? They're all pointing to the same IP address anyway. – 에이바 Jul 17 '13 at 17:56
  • 1
    Don't think they need to be removed, it's just unusual to see that in my experience. What error are you getting when you try to touch a file in /oracle/r12/apps on the client? – John Jul 17 '13 at 17:58
  • There is no error but it does not update to the server and vice versa. – 에이바 Jul 17 '13 at 18:00
  • 1
    Are the times on the server and client synced via NTP? Also: indirectly related at most, but change the "1 2" and the end of the NFS mounts in fstab to be "0 0". – John Jul 17 '13 at 18:02
  • Nice catch on the 0 0 and no they're not using NTP. Since you mentioned it though, I checked the date and noticed a slight difference in time. – 에이바 Jul 17 '13 at 18:15
  • 1
    Start up NTP on the server and client, and your problems just might disappear. – John Jul 17 '13 at 18:20
  • 1
    Does mounting as (vfstype) nfs4 make a difference? – HTTP500 Jul 17 '13 at 18:28
  • I turned on NTP and syncronized the time as well as changed nfs to nfs4 in fstab. No change. – 에이바 Jul 17 '13 at 18:45
  • I commented out all of the lines but `/oracle/r12/ x.x.x.x(rw,sync,no_wdelay,nohide,no_subtree_check,no_root_squash)` in exports and /oracle/r12/inst/apps/database1 still works but /oracle/r12/apps does not. – 에이바 Jul 17 '13 at 19:02
  • 1
    @에이바 have you issued `showmount -a x.x.x.x` on your nfs server where you are exporting the shares? Check the directory permissions of `apps` see if there is any difference. Also add only these options `x.x.x.x/24(rw)` See for the netmask. I assume it has a `255.255.255.0` mask. – Valentin Bajrami Jul 17 '13 at 19:37
  • I changed the IP to have /24 and removed all options but rw. Still the same behavior except now I cannot create any files on the NFS drive from the client. showmount -a only shows /oracle/r12/inst/apps/database1 – 에이바 Jul 17 '13 at 19:55

1 Answers1

0

Thank you for all of the comments everyone.

Here is what I did to fix the issue.

Started ntp service on both servers and synchronized the time.

Changed /etc/fstab on the NFS client to

x.x.x.x:/oracle/r12/inst/apps/database1 /oracle/r12/inst/apps/database1 nfs defaults 0 0 x.x.x.x:/oracle/r12/apps /oracle/r12/apps nfs defaults 0 0

Changed /etc/exports on NFS server to

/oracle/r12/ x.x.x.x/24(rw,sync,no_wdelay,nohide,no_subtree_check,no_root_squash)
/oracle/r12/apps/ x.x.x.x/24(rw,sync,no_wdelay,nohide,no_subtree_check,no_root_squash)

Ran exportfs -av on NFS Server

Manually unmounted drives on the NFS client and issued mount -a to re-read /etc/fstab and mount file systems.

Now it's working properly.

에이바
  • 612
  • 4
  • 11
  • 34