ORA-27054: NFS file system where the file is created or resides is ......

dcswinner發表於2012-03-05
前兩天下午想對一生產環境(rac)的資料庫進行expdp的邏輯備份,備份盤在異地,通過nfs對映到rac的節點一上。
 
nfs盤掛載後通過df -h能看到掛載成功。
但是在執行expdp命令後報如下錯誤:
ORA-27054: NFS file system where the file is created or resides is not mounted with correct options:
看來像是mount引數不對引起的,檢視metalink文章:

Mount Options for Oracle files when used with NFS on NAS devices [ID 359515.1]


 

Modified 04-FEB-2012     Type BULLETIN     Status PUBLISHED

 

In this Document
  Purpose
  Scope and Application
  Mount Options for Oracle files when used with NFS on NAS devices
     RAC 
      Single Instance
  References


Applies to:

Oracle Server - Enterprise Edition - Version: 10.1.0.2 to 11.2.0.3 - Release: 10.1 to 11.2
Information in this document applies to any platform.
Oracle Clusterware, Oracle Real Application Clusters, NAS

Purpose

The purpose of this bulletin is to document the options with which the NAS systems should be mounted. This note does not cover the new dNFS feature that was introduced in 11g.

Scope and Application

This document is relevant to all environments using Oracle Clusterware & RAC.

Mount Options for Oracle files when used with NFS on NAS devices

RAC 

 

In the table below

  • Binaries is the shared mount points where the Oracle Home and CRS_HOME is installed.
  • Datafiles includes Online Logs, Controlfile and Datafiles
  • nfsvers and vers are identical on those OS platforms that has nfsvers.  The ver option is an alternative to the nfsvers option. It is included for compatibility with other operating systems
  • Please note that the mount options on each of the following cells are applicable only to those type of files listed in the column heading.
  • For RMAN backup sets, image copies, and Data Pump dump files, the "NOAC" mount option should not be specified - that is because RMAN and Data Pump do not check this option and specifying this can adversely affect performance.

 

Operating System

Mount options for    Binaries ##

Mount options for Oracle Datafiles

Mount options for CRS Voting Disk and OCR

Sun Solaris *

rw,bg,hard,nointr,rsize=32768,
wsize=32768,proto=tcp,noac,

vers=3,suid

rw,bg,hard,nointr,rsize=32768,
wsize=32768,proto=tcp,noac,
forcedirectio, vers=3,suid

rw,bg,hard,nointr,rsize=32768,
wsize=32768,proto=tcp,vers=3,
noac,forcedirectio

AIX (5L) **

rw,bg,hard,nointr,rsize=32768,
wsize=32768,proto=tcp,

vers=3,timeo=600

cio,rw,bg,hard,nointr,rsize=32768,
wsize=32768,proto=tcp,noac,
vers=3,timeo=600

cio,rw,bg,hard,intr,rsize=32768,
wsize=32768,tcp,noac,
vers=3,timeo=600

HPUX 11.23 ***  --

rw,bg,vers=3,proto=tcp,noac,
hard,nointr,timeo=600,
rsize=32768,wsize=32768,suid

rw,bg,vers=3,proto=tcp,noac,
forcedirectio,hard,nointr,timeo=600,
rsize=32768,wsize=32768,suid

rw,bg,vers=3,proto=tcp,noac,
forcedirectio,hard,nointr,timeo=600
,rsize=32768,wsize=32768,suid

Windows

Not Supported

Not Supported

Not Supported

Linux x86
#
****

rw,bg,hard,nointr,rsize=32768,
wsize=32768,tcp, vers=3,
timeo=600, actimeo=0

rw,bg,hard,nointr,rsize=32768,
wsize=32768,tcp,actimeo=0,
vers=3,timeo=600

rw,bg,hard,nointr,rsize=32768,
wsize=32768,tcp,noac,actimeo=0,
vers=3,timeo=600

Linux x86-64 #
****

rw,bg,hard,nointr,rsize=32768,
 wsize=32768,tcp,vers=3,
timeo=600, actimeo=0

rw,bg,hard,nointr,rsize=32768,
wsize=32768,tcp,actimeo=0,
vers=3,timeo=600

rw,bg,hard,nointr,rsize=32768,
wsize=32768,tcp,noac,vers=3,
timeo=600,actimeo=0

Linux - Itanium

rw,bg,hard,nointr,rsize=32768,
wsize=32768,tcp,vers=3,
timeo=600, actimeo=0

rw,bg,hard,nointr,rsize=32768,
wsize=32768,tcp,actimeo=0,
vers=3,timeo=600

rw,bg,hard,nointr,rsize=32768,
wsize=32768,tcp,noac,vers=3,
timeo=600,actimeo=0

* NFS mount option “forcedirectio” is required on Solaris platforms when mounting the OCR/CRS files when using Oracle 10.1.0.4 or 10.2.0.2 or later (Oracle unpublished bug 4466428)
** AIX is only supported with NAS on AIX 5.3 TL04 and higher with Oracle 10.2.0.1 and later (NetApp)
*** NAS devices are only supported with HPUX 11.23 or higher ONLY 
**** As per BUG 11812928, the 'intr' & 'nointr' are deprecated in OEL 5.6 kernels and up including Oracle Linux 6. It is harmless to still include it, but the "NFS: ignoring mount option: nointr" will appears. This message can be ingnored.


# These mount options are for Linux kernels 2.6 and above for older kernels please check Note 279393.1

Due to Unpublished bug 5856342, it is necessary to use the following init.ora parameter when using NAS with all versions of RAC on Linux (x86 & X86-64 platforms) until 10.2.0.4. This bug is fixed and included in 10.2.0.4 patchset.
filesystemio_options = DIRECTIO

 Single Instance

Operating System

Mount options for Binaries

Mount options for Oracle Datafiles

Sun Solaris *
(8, 9, 10)

rw,bg,hard,rsize=32768,wsize=32768,vers=3,nointr,proto=tcp,suid

rw,bg,hard,rsize=32768,wsize=32768,vers=3,[forcedirectio or llock],nointr,proto=tcp,suid

AIX (5L) **

rw,bg,hard,rsize=32768,wsize=32768,vers=3,intr,timeo=600,proto=tcp

rw,bg,hard,rsize=32768,wsize=32768,vers=3,cio,intr,timeo=600,proto=tcp

HPUX 11.23 ****

rw,bg,hard,rsize=32768,wsize=32768,vers=3,nointr,timeo=600,proto=tcp,suid

rw,bg,hard,rsize=32768,wsize=32768,vers=3,nointr,timeo=600,proto=tcp, suid, forcedirectio

Windows

Not Supported

Not Supported

Linux x86
#

rw,bg,hard,rsize=32768,wsize=32768,vers=3,nointr,timeo=600,tcp

rw,bg,hard,rsize=32768,wsize=32768,vers=3,nointr,timeo=600,tcp,actimeo=0*

Linux x86-64 #

rw,bg,hard,rsize=32768,wsize=32768,vers=3,nointr,timeo=600,tcp

rw,bg,hard,rsize=32768,wsize=32768,vers=3,nointr,timeo=600,tcp,actimeo=0*

Linux - Itanium

rw,bg,hard,rsize=32768,wsize=32768,vers=3,nointr,timeo=600,tcp

rw,bg,hard,rsize=32768,wsize=32768,vers=3,nointr,timeo=600,tcp

* actime=0 or noac can be used

 

References

http://now.netapp.com/Knowledgebase/solutionarea.asp?id=kb7518
http://linux.oracle.com/pls/apex/f?p=102:2:3947951439689189::NO::P2_VC_ID:424

我的作業系統是Linux x86-64,因此我先將已掛在的盤umount下,按照新的選項重新掛載:

[root@xxxx-db-01 ~]# umount -l /orabak/

[root@xxxx-db-01 ~]# df -h
Filesystem            容量  已用 可用 已用% 掛載點
/dev/cciss/c0d0p6      64G  4.4G   56G   8% /
/dev/cciss/c0d0p1     190M   15M  166M   9% /boot
/dev/cciss/c0d0p5      39G  392M   37G   2% /data
none                   16G     0   16G   0% /dev/shm
/dev/cciss/c0d0p3      29G   21G  6.6G  76% /home
x.x.x.x:/home/db_bak/
                      359G   38G  304G  11% /orabak

[root@xxxx-db-01 ~]# umount -l /orabak/
[root@xxxx-db-01 ~]# df -h
Filesystem            容量  已用 可用 已用% 掛載點
/dev/cciss/c0d0p6      64G  4.4G   56G   8% /
/dev/cciss/c0d0p1     190M   15M  166M   9% /boot
/dev/cciss/c0d0p5      39G  392M   37G   2% /data
none                   16G     0   16G   0% /dev/shm
/dev/cciss/c0d0p3      29G   21G  6.6G  76% /home
[root@xxxx-db-01 ~]# mount -t nfs -o rw,bg,noac,hard,nointr,rsize=32768,wsize=32768,nolock,proto=tcp,actimeo=0,vers=3,timeo=600 x.x.x.x:/home/db_bak/ /orabak/

[root@xxxx-db-01 ~]# df -h
Filesystem            容量  已用 可用 已用% 掛載點
/dev/cciss/c0d0p6      64G  4.4G   56G   8% /
/dev/cciss/c0d0p1     190M   15M  166M   9% /boot
/dev/cciss/c0d0p5      39G  392M   37G   2% /data
none                   16G     0   16G   0% /dev/shm
/dev/cciss/c0d0p3      29G   21G  6.6G  76% /home
x.x.x.x:/home/db_bak/
                      359G   38G  304G  11% /orabak

再次執行備份指令碼,重新驗證,發現報如下錯誤:

ORA-39000: bad dump file specification
ORA-31641: unable to create dump file "/orabak/export/curr/emspda2101.dmp"
ORA-27086: unable to lock file - already in use
Linux-x86_64 Error: 37: No locks available

再次分析剛才的mount選項,難道是noac引數的問題嗎?
再次解除安裝nfs盤

umount -l /orabak/

按照如下選項重新mount nfs盤:

mount -t nfs -o rw,bg,hard,nointr,rsize=32768,wsize=32768,nolock,proto=tcp,actimeo=0,vers=3,timeo=600 x.x.x.x:/home/db_bak/ /orabak/

重新執行備份程式:

[oracle@xxxx-db-01 backup]$ ./expdp.sh &
[1] 9782
[oracle@xxxx-db-01 backup]$
Export: Release 10.2.0.5.0 - 64bit Production on Monday, 05 March, 2012 11:20:13

Copyright (c) 2003, 2007, Oracle.  All rights reserved.

Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bit Production
With the Partitioning, Real Application Clusters, OLAP, Data Mining
and Real Application Testing options
Starting "SYSTEM"."SYS_EXPORT_SCHEMA_01":  system/******** directory=exp_dir dumpfile=exp_dir:emspda21%U.dmp filesize=30g parfile=exp_par.txt logfile=exp_dir:emspda220120305.log
Estimate in progress using BLOCKS method...
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 3.309 GB
Processing object type SCHEMA_EXPORT/USER
Processing object type SCHEMA_EXPORT/SYSTEM_GRANT
Processing object type SCHEMA_EXPORT/ROLE_GRANT
Processing object type SCHEMA_EXPORT/DEFAULT_ROLE
Processing object type SCHEMA_EXPORT/TABLESPACE_QUOTA
....................................

備份可以執行了,15分鐘後備份完成!

 

參考文章:
Mount Options for Oracle files when used with NFS on NAS devices [ID 359515.1]

RMAN and/or Datapump Export Backup fails with ORA-27086 on NFS / NAS [ID 1187014.1]

 
補充:每次主機重啟後,要記得加長nfs檔案系統有沒有自動mount上,如果沒有需要手工mount上。

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/12129601/viewspace-717731/,如需轉載,請註明出處,否則將追究法律責任。

相關文章