This is done on HP-UX v 11.23.

  1. Make NFS Server to autostart
    • Open /etc/rc.config.d/nfsconf

      # vi /etc/rc.config.d/nfsconf

    • Change NFS_SERVER paramater from “0” to “1”, then save.

      NFS_CLIENT=1
      NFS_SERVER=1
      NUM_NFSD=16
      NUM_NFSIOD=16
      PCNFS_SERVER=0

  2. Share some directories
    • Open /etc/exports

      # vi /etc/exports

    • add directories that you want to share to the file, for example:

      /var/opt/ignite/clients -anon=2
      /var/opt/ignite/recovery/archives/hqcmsdb1 -anon=2,access=hqcmsdb1
      /backup/dump -access=hqcmsdb1

      the parameter “-anon=2” means all anonymous access will be given default uid “2” while the parameter “-acess=hqcmsdb1” means only that server is allowed to mount the share. No parameters means the directories shared with read write access for everyone. For more infos and examples, type “man 4 exports” on the console

    • Update the share

      # /usr/sbin/exportfs -a

    • Make sure the right folder are shared

      # /usr/sbin/exportfs
      /var/opt/ignite/clients -anon=2
      /var/opt/ignite/recovery/archives/hqcmsdb1 -anon=2,access=hqcmsdb1
      /backup/dump -access=hqcmsdb1

  3. Start NFS Server
    • Check whether NFS is already started or not

      # ps -ef | grep nfsd
      root 2309 2308 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2333 2312 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2332 2312 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2307 1 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2334 2312 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2308 1 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2310 2309 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2312 2308 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2313 2308 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2316 2308 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2315 2313 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2314 2308 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2317 2308 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16
      root 2318 2309 0 20:22:54 ? 0:00 /usr/sbin/nfsd 16

      If the output is similar to the above example, then the nfsd is already started, if not..

    • start the nfsd daemon

      # /sbin/init.d/nfs.server start

  4. Test whether the shared directories can be mounted from the target server
    • Mount the shared directory manually

      # mount -F nfs hqcmsdb2:/backup/dump /backup/dump

    • Check whether the directory is mounted correctly

      # mount
      / on /dev/vg00/lvol3 ioerror=nodisable,log,dev=40000003 on Sun Dec 7 18:03:17 2008
      /stand on /dev/vg00/lvol1 ioerror=mwdisable,log,nodatainlog,tranflush,dev=40000001 on Sun Dec 7 18:03:18 2008
      /var on /dev/vg00/lvol8 ioerror=mwdisable,delaylog,nodatainlog,dev=40000008 on Sun Dec 7 18:03:31 2008
      /var/opt/ignite/recovery/archives on /dev/vg00/lvol10 ioerror=mwdisable,largefiles,delaylog,nodatainlog,dev=4000000a on Sun Dec 7 18:03:31 2008
      /usr on /dev/vg00/lvol7 ioerror=mwdisable,delaylog,nodatainlog,dev=40000007 on Sun Dec 7 18:03:31 2008
      /u01 on /dev/vg00/lvol9 ioerror=mwdisable,delaylog,nodatainlog,dev=40000009 on Sun Dec 7 18:03:31 2008
      /backup/dump on hqcmsdb2:/backup/dump rsize=32768,wsize=32768,NFSv3,dev=7 on Wed Dec 10 20:37:33 2008

Aand.. I think we’re done

By ikhsan

3 thoughts on “Activating NFS server on HP-UX 11.xx”
  1. good info – thanks
    Do you know if there are any issues with putting datafiles on the NFS mount and if Oracle will support async NFS for these datafiles on the NFS mounts?

    Thansk!

    1. Oracle supports NFS for hosting the data files and provides documentations to setup your NFS share. I have personally use it in development environment, and as a target for dumping data. Speed is of course the main drawback, especially if you’re using it in RAC setup, since the noac bit is mandatory

      You can drop Oracle’s mandatory parameter by making the database skip the NFS parameter checking, but I haven’t try this one

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.