【問題處理】diagcollection.pl採集指令碼執行出錯——Argument list too long
1.問題現象
1)在root使用者下設定必須的環境變數
[root@rac1 ~]# export ORACLE_BASE=/oracle/app/oracle
[root@rac1 ~]# export ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1
[root@rac1 ~]# export ORA_CRS_HOME=/oracle/app/crs
2)確認環境變數設定正確
[root@rac1 ~]# echo $ORACLE_BASE
/oracle/app/oracle
[root@rac1 ~]# echo $ORACLE_HOME
/oracle/app/oracle/product/10.2.0/db_1
[root@rac1 ~]# echo $ORA_CRS_HOME
/oracle/app/crs
[root@rac1 ~]# echo $HOSTNAME
rac1
3)問題報錯如下
[root@rac1 ~]# cd $ORA_CRS_HOME/bin
[root@rac1 bin]# ./diagcollection.pl -collect --all --crshome $ORA_CRS_HOME
Production Copyright 2004, 2005, Oracle. All rights reserved
Cluster Ready Services (CRS) diagnostic collection tool
The following CRS diagnostic archives will be created in the local directory.
crsData_rac1.tar.gz -> logs,traces and cores from CRS home. Note: core files will be packaged only with the -core option.
ocrData_rac1.tar.gz -> ocrdump, ocrcheck etc
coreData_rac1.tar.gz -> contents of CRS core files in text format
Collecting crs data
sh: /bin/tar: Argument list too long
gzip: crsData_rac1.tar: No such file or directory
Collecting OCR data
Collecting information from core files
No corefiles found
The following Oracle Home diagnostic archives will be created in the local directory.
oraData_rac1.tar.gz -> logs, traces and cores from Oracle Home
Collecting oracle home data
/bin/tar: Removing leading `/' from member names
2.問題原因
該問題是由於Shell本身的限制,當引數列表(Argument list)過長後,便會導致diagcollection.pl指令碼執行出錯。
本例中CRS日誌目錄下的大量檔案是導致該問題的罪魁禍首。
3.處理方法
主要有兩種處理方法:①手工收集CRS日誌目錄下的所需檔案;②刪除無用檔案,避免出現超出Shell限制的問題
針對第二種方法,我們僅需要關心“$CRS_HOME/log//clien”目錄下的檔案即可,因為該目錄下儲存的檔案內容最為龐大。可以清除一個月之前的檔案(或將一個月之前的檔案手工備份到其他目錄)後再嘗試收集。
4.更多的參考資訊
有關該問題的更多參考資訊請參見MOS:diagcollection.pl Fails With "Argument list too long" [ID 751981.1]
5.小結
我們的目標:不放過任何細節!
Good luck.
secooler
10.11.20
-- The End --
1)在root使用者下設定必須的環境變數
[root@rac1 ~]# export ORACLE_BASE=/oracle/app/oracle
[root@rac1 ~]# export ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1
[root@rac1 ~]# export ORA_CRS_HOME=/oracle/app/crs
2)確認環境變數設定正確
[root@rac1 ~]# echo $ORACLE_BASE
/oracle/app/oracle
[root@rac1 ~]# echo $ORACLE_HOME
/oracle/app/oracle/product/10.2.0/db_1
[root@rac1 ~]# echo $ORA_CRS_HOME
/oracle/app/crs
[root@rac1 ~]# echo $HOSTNAME
rac1
3)問題報錯如下
[root@rac1 ~]# cd $ORA_CRS_HOME/bin
[root@rac1 bin]# ./diagcollection.pl -collect --all --crshome $ORA_CRS_HOME
Production Copyright 2004, 2005, Oracle. All rights reserved
Cluster Ready Services (CRS) diagnostic collection tool
The following CRS diagnostic archives will be created in the local directory.
crsData_rac1.tar.gz -> logs,traces and cores from CRS home. Note: core files will be packaged only with the -core option.
ocrData_rac1.tar.gz -> ocrdump, ocrcheck etc
coreData_rac1.tar.gz -> contents of CRS core files in text format
Collecting crs data
sh: /bin/tar: Argument list too long
gzip: crsData_rac1.tar: No such file or directory
Collecting OCR data
Collecting information from core files
No corefiles found
The following Oracle Home diagnostic archives will be created in the local directory.
oraData_rac1.tar.gz -> logs, traces and cores from Oracle Home
Collecting oracle home data
/bin/tar: Removing leading `/' from member names
2.問題原因
該問題是由於Shell本身的限制,當引數列表(Argument list)過長後,便會導致diagcollection.pl指令碼執行出錯。
本例中CRS日誌目錄下的大量檔案是導致該問題的罪魁禍首。
3.處理方法
主要有兩種處理方法:①手工收集CRS日誌目錄下的所需檔案;②刪除無用檔案,避免出現超出Shell限制的問題
針對第二種方法,我們僅需要關心“$CRS_HOME/log/
4.更多的參考資訊
有關該問題的更多參考資訊請參見MOS:diagcollection.pl Fails With "Argument list too long" [ID 751981.1]
5.小結
我們的目標:不放過任何細節!
Good luck.
secooler
10.11.20
-- The End --
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/519536/viewspace-680054/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 【問題處理】diagcollection.pl採集指令碼執行出錯——'crshome' is missingGC指令碼
- 刪除大量檔案Argument list too long錯誤解決
- 執行指令碼diagcollection.pl報錯指令碼GC
- -bash: /bin/rm: Argument list too long的解決辦法
- 【故障處理】-0403-027 The parameter list is too long
- ES報錯Result window is too large問題處理薦
- MySQL問題處理——1040錯誤Too many connectionsMySql
- 0403-027 The parameter list is too long for AIXAI
- ORACLE問題處理十個指令碼Oracle指令碼
- ORA-00494 enqueue [CF] held for too long故障分析處理ENQ
- 執行遷移檔案報錯 1071 Specified key was too long.
- solaris 10 sar_ 執行出錯處理
- UNIX 檔案太多,不能刪除的問題解決(ksh: /usr/bin/find: arg list too long)
- Too many open files報錯處理
- 從一個shell指令碼執行出錯聊起指令碼
- 執行 shell 指令碼 \r 問題解決指令碼
- Laravel 5.5 資料遷移問題:Specified key was too longLaravel
- 資料採集,微軟控制元件分頁問題的處理微軟控制元件
- git拉取程式碼報錯filename too long unable to create fileGit
- 【k8s】etcd叢集took too long to execute慢日誌告警問題分析K8S
- xcall叢集執行命令指令碼指令碼
- docker 遷移映象到其他機器執行報錯OCI 問題處理Docker
- Bash 指令碼中的錯誤處理指令碼
- Linux 問題處理集錦Linux
- IntelliJ IDEA 執行專案的時候提示 Command line is too long 錯誤IntelliJIdea
- Laravel 5.4 常見錯誤:Specified key was too longLaravel
- Linux每程式執行緒數問題處理Linux執行緒
- 解決 Specified key was too long ... 767 bytes 的本質問題
- 一個“指令碼執行夯死”問題的分析指令碼
- repmgr 叢集雙主問題處理
- SOLIDWORKS啟動時出現指令碼錯誤問題Solid指令碼
- idea在使用git clone 時出現Filename too long的報錯資訊IdeaGit
- shell 指令碼的除錯問題指令碼除錯
- Arcgis toolbox匯入python script執行出錯,實在找不出指令碼哪裡有問題。求助Python指令碼
- crontab不執行mysql的指令碼問題的解決!MySql指令碼
- Android高併發問題處理和執行緒池ThreadPool執行緒池原始碼分析Android執行緒thread原始碼
- 執行計劃問題導致處理速度時快時慢的問題
- 升級執行指令碼遇到SP2-0734: unknown command beginning 錯誤處理指令碼