linux 突然變得很慢
這兩天伺服器出現了一個很神奇的問題,那就是週期性的變得很慢(PS:有一段時間處理的很快,但是過一段時間,就會有一兩天,處理很慢!非常慢!)。使用top看了一下,發現CPU和負載都很高。整個系統就跟遙控汽車的電池沒電是的。都顯得很怠慢。導致整個業務的流程相應很慢。超時很多~~ 糾結啊~ 兩天了。
網上找了各種原因檢視CPU的溫度、I/O輸出、負載、記憶體、儲存空間…… 就剩下CPU的電壓沒看了。網上各種原因的找啊。還是找不到。還好,在百度上面問了一個大仙,再看了系統資源截圖之後,沒有問題,建議我去看 /var/log/message 下的日誌。
我執行了 cat var/log/message 然後,發現裡面有大量的日誌。
Jun 1 03:31:01 localhost rsyslogd: [origin software="rsyslogd" swVersion="5.8.10" x-pid="1238" x-info="http://www.rsyslog.com"] rsyslogd was HUPed
Jun 1 03:52:24 localhost auditd[1222]: Audit daemon rotating log files
Jun 1 04:56:10 localhost auditd[1222]: Audit daemon rotating log files
Jun 1 05:57:19 localhost auditd[1222]: Audit daemon rotating log files
Jun 1 07:02:59 localhost auditd[1222]: Audit daemon rotating log files
Jun 1 08:16:28 localhost auditd[1222]: Audit daemon rotating log files
Jun 1 11:09:57 localhost auditd[1222]: Audit daemon rotating log files
Jun 1 14:55:22 localhost auditd[1222]: Audit daemon rotating log files
Jun 1 23:21:09 localhost auditd[1222]: Audit daemon rotating log files
Jun 2 01:39:41 localhost auditd[1222]: Audit daemon rotating log files
Jun 2 07:09:58 localhost auditd[1222]: Audit daemon rotating log files
Jun 2 22:56:32 localhost auditd[1222]: Audit daemon rotating log files
Jun 2 23:27:29 localhost kernel: CPU0: Core power limit notification (total events = 175385872)
Jun 2 23:27:29 localhost kernel: CPU1: Core power limit notification (total events = 176288017)
Jun 2 23:27:29 localhost kernel: CPU3: Core power limit notification (total events = 176266430)
Jun 2 23:27:29 localhost kernel: CPU2: Core power limit notification (total events = 176618264)
Jun 2 23:27:29 localhost kernel: CPU1: Package power limit notification (total events = 176996607)
Jun 2 23:27:29 localhost kernel: CPU3: Package power limit notification (total events = 176997408)
Jun 2 23:27:29 localhost kernel: CPU2: Package power limit notification (total events = 177034309)
Jun 2 23:27:29 localhost kernel: CPU0: Package power limit notification (total events = 176908746)
Jun 2 23:27:29 localhost kernel: CPU0: Core power limit normal
Jun 2 23:27:29 localhost kernel: CPU0: Package power limit normal
Jun 2 23:27:29 localhost kernel: CPU1: Core power limit normal
Jun 2 23:27:29 localhost kernel: CPU2: Core power limit normal
Jun 2 23:27:29 localhost kernel: CPU3: Core power limit normal
Jun 2 23:32:29 localhost kernel: CPU1: Package power limit normal
Jun 2 23:32:29 localhost kernel: CPU2: Package power limit normal
Jun 2 23:32:29 localhost kernel: CPU3: Package power limit normal
Jun 2 23:32:29 localhost kernel: CPU2: Core power limit notification (total events = 176784916)
Jun 2 23:32:29 localhost kernel: CPU3: Core power limit notification (total events = 176433014)
Jun 2 23:32:29 localhost kernel: CPU1: Core power limit notification (total events = 176454540)
Jun 2 23:32:29 localhost kernel: CPU0: Core power limit notification (total events = 175552143)
Jun 2 23:32:29 localhost kernel: CPU0: Package power limit notification (total events = 177075421)
Jun 2 23:32:29 localhost kernel: CPU2: Core power limit normal
Jun 2 23:32:29 localhost kernel: CPU3: Core power limit normal
Jun 2 23:32:29 localhost kernel: CPU1: Core power limit normal
Jun 2 23:32:29 localhost kernel: CPU0: Core power limit normal
Jun 2 23:32:29 localhost kernel: CPU0: Package power limit normal
Jun 2 23:37:29 localhost kernel: CPU0: Core power limit normal
Jun 2 23:37:29 localhost kernel: CPU1: Core power limit normal
找一條,網上一貼,果然。說是dell機器的一種節能設定。說是在整個伺服器的壓力不是很大的情況向,自動的減少CPU等裝置的供電。讓其處在一種類似於低耗能的狀態。可能會導致伺服器的整體處理流程降低。我想,會不會是以為這種原因導致我的伺服器的效能下降了呢? 具體看
從網上找資料,怎麼關閉dell伺服器的節能設定。找了一大堆,都說在BISO裡面設定。 由於是線上伺服器,不能說關閉就關閉啊。於是打電話給dell客服。諮詢。結果人家也說,必須在BISO下配置。最後管dell伺服器的技術客服要了設定的文件,給了機房。讓其幫忙技術人員設定一下。
設定完畢之後,重啟、啟動專案。 問題得以解決~~!!!!! 節能模式在企業中,有自己的機房的話,在耗能這塊,可以說能節省不少。但是我們的伺服器是託管的。就不管啦,伺服器處理效能重要! 所以,設定成高效能模式。設定完成之後。伺服器感覺有質的飛越。原本高負載,這回再看一下,全都是0.0幾了。終於可以睡一個好覺了!! 希望這篇文章嗯幫你解決問題。