Write after the error occurs........
有多少錯誤可以重犯呢?
看一下我Oracle使用者的.bash_profile有什麼問題沒有?
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
ORACLE_BASE=/opt/oracle/product
ORACLE_HOME=/opt/oracle/product/10g
LD_LIBRARY_PATH=$ORACLE_HOME/lib32:$ORACLE_HOME/lib;export LD_LIBRARY_PATH
LIBPATH=$ORACLE_HOME/lib32:$ORACLE_HOME/lib:$ORACLE_HOME/ctx/lib;export LIB_PATH
CLASSPATH=$ORACLE_HOME/JRE/lib:$ORACLE_HOME/JRE/lib/rt.jar:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib;export CLASSPATH
PATH=$PATH:$HOME/bin:$ORACLE_HOME/bin
export PATH
unset USERNAME
貌似一切正常,可正當我做如下操作的時候:
[root@orahost01 ~]# su - oracle
[oracle@orahost01 ~]$ export ORACLE_SID=ASM
[oracle@orahost01 ~]$ sqlplus /nolog
Error 6 initializing SQL*Plus
Message file sp1
SP2-0750: You may need to set ORACLE_HOME to your Oracle software directory
Oracle報錯了。
很以外的的,我又登陸一次,成功了。但是在啟動instance的時候又報如下錯誤:
[oracle@orahost01 10g]$ clear
[oracle@orahost01 10g]$ export ORACLE_SID=ASM
[oracle@orahost01 10g]$ sqlplus /nolog
SQL*Plus: Release 10.2.0.1.0 - Production on Mon Dec 31 18:45:43 2007
Copyright (c) 1982, 2005, Oracle. All rights reserved.
SQL> conn / as sysdba;
ERROR:
ORA-09925: Message 9925 not found; No message file for product=RDBMS,
facility=ORA
Linux Error: 2: No such file or directory
Additional information: 9925
ORA-09925: Message 9925 not found; No message file for product=RDBMS,
facility=ORA
Linux Error: 2: No such file or directory
Additional information: 9925
查了一下$ORACLE_HOME/rdbms目錄
[oracle@orahost01 10g]$ ls -l rdbms
total 80
drwxr-x--- 2 oracle oinstall 36864 Dec 31 18:01 admin
drwxr-x--- 2 oracle oinstall 4096 Dec 31 18:54 audit
drwxr-x--- 2 oracle oinstall 4096 Dec 31 17:59 demo
drwxr-x--- 2 oracle oinstall 4096 Dec 31 17:58 doc
drwxr-x--- 4 oracle oinstall 4096 Dec 31 18:01 install
drwxr-x--- 2 oracle oinstall 4096 Dec 31 17:58 jlib
-rw-r----- 1 oracle oinstall 24 Jun 30 2005 label.info
drwxr-x--- 2 oracle oinstall 4096 Dec 31 18:01 lib
drwxr-x--- 2 oracle oinstall 4096 Dec 31 17:59 log
drwxr-x--- 2 oracle oinstall 4096 Dec 31 17:58 mesg
drwxr-x--- 2 oracle oinstall 4096 Dec 31 17:58 public
drwxr-x--- 3 oracle oinstall 4096 Dec 31 17:57 xml
audit和mesg都是存在切可寫的,那為什麼還會報錯呢?
問題其實已經暴露在我們的.bash_profile中了。主要就是
ORACLE_HOME=/opt/oracle/product/10g
這個環境變數沒有被export,因此此變數是不能被shell的子程式獲得的。
改為ORACLE_HOME=/opt/oracle/product/10g;export ORACLE_HOME
問題得到了圓滿的解決。
由於忽略了export,會引出這些奇怪的現象發生,誒?我確實設定了ORACLE_HOME,了但是為什麼還是有這樣的提示呢?
做為DBA,應該時刻注意自己的每一步操作,更重要的是要謹慎注意每一處的細節!
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/12361284/viewspace-68260/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- Connection reset by peer: socket write errorError
- backup: 0511-432 A write error occurredError
- su - grid 提示E297: Write error in swap fileError
- Software caused connection abort: socket write error/mysql/tomcatErrorMySqlTomcat
- ERROR [main] zookeeper.RecoverableZooKeeper: ZooKeeper create failed after 4 attemptsErrorAI
- 【MySQL】ERROR 1878 (HY000): Temporary file write failure.MySqlErrorAI
- ERROR 1661 (HY000): Cannot execute statement: impossible to write to binaryError
- mysql [ERROR] InnoDB: ./ibdata1 can't be opened in read-write modeMySqlError
- ggsci error libclntsh.so.10.1: cannot restore segment prot after relocErrorREST
- jQuery after()jQuery
- Shlomo關於everntual consistency與read-after-write consistency區別的解釋以及為什麼US Standard 沒有采用先進的read-after-wr
- /sqlplus: error on libnnz11.so: cannot restore segment prot after reloc [ID 454196.1]SQLErrorREST
- 關於Cache的write-through & write-back
- MySQL double writeMySql
- hio_write
- [Javascript] Write .call()JavaScript
- Failed: error reading separator after document # 1: bad JSON array format - found no opening brackAIErrorJSONORM
- HDFS read and write
- document.write()方法
- db file parallel writeParallel
- commit_writeMIT
- storage儲存的cache快取相關機制write-though和write-back(write-caching)快取
- Oracle db file parallel write 和 log file parallel write 等待事件 說明OracleParallel事件
- MySQL 5.7半同步複製after sync和after commit詳解MySqlMIT
- How boltdb Write its Data?
- write&read&open
- Copy-On-Write技術
- MongoDB Write Concern整理MongoDB
- 關於document.write
- ImageIO.write錯誤
- MySQL double write存在意義MySql
- mongodb批量操作, bulk_write,MongoDB
- 【MySQL】八、double write 淺析.MySql
- 深入淺出Netty:writeNetty
- write_through 寫效能下降
- MongoDB 寫安全(Write Concern)MongoDB
- mysql之 double write 淺析MySql
- nodejs read/write fileNodeJS