Oracle 每隔5分鐘產生2個clsc*.log檔案

來源:互聯網
上載者:User

標籤:vim   color   console   install   ls -l   觀察   環境   bash   清理   

環境:

OS:HP-UNIX

資料庫:11.2.0.4   雙機RAC

 

(一)現象

在清理Oracle日誌的時候,發現在$ORACLE_HOME/log/{instance_id}/client下面存在大量的clsc*.log。經過觀察,發現每隔5分鐘產生2個日誌,具體如下:

...-rw-r--r-- 1 oracle oinstall 244 Sep 25 15:55 clsc34691.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 15:55 clsc34692.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:00 clsc34693.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:00 clsc34694.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:05 clsc34695.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:05 clsc34696.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:10 clsc34697.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:10 clsc34698.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:15 clsc34699.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:15 clsc34700.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:20 clsc34701.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:25 clsc34702.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:30 clsc34703.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:35 clsc34704.log-rw-r--r-- 1 oracle oinstall 244 Sep 25 16:40 clsc34705.log...

查看日誌數量,發現已經有很多了

fabdb1$[/grid/11.2.0/grid/log/fabdb1/client]ll |wc -l34709

 

(二)原因

發現這是Oracle在11.2中的bug,在開啟Oracle EM的情況下,EM會每隔5分鐘使用crs_stat去收集Oracle服務的狀態,導致日誌的產生。

 

(三)解決方案

以oracle使用者登入,到目錄下:

$ORACLE_HOME/sysman/admin/scripts/

修改2個檔案:

①  vim crs_resources.pl
# 找到這一行:my $cmd = "$crs_home/bin/crs_stat"; # 修改為:my $cmd = "$crs_home/bin/crsctl stat res"; 

② vim crs_vip.pl
# 找到這一行:my $cmd = "$crs_home/bin/crs_stat"; # 修改為:my $cmd = "$crs_home/bin/crsctl stat res"; 

重啟EM

emctl stop dbconsoleemctl start dbconsole

 

su - grid

cd $ORACLE_HOME/log/{instance_name}/client
ls -lrt --持續監控半小時,檢查是否有規律產生記錄檔。

Oracle 每隔5分鐘產生2個clsc*.log檔案

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.