ORACLE_修改執行個體的記憶體大小

來源:互聯網
上載者:User

標籤:info   http   mmu   each   and   指定   one   rac   oracle安裝   


註:本文來源於:星火spark  《Oracle的執行個體佔用記憶體調整》

ORACLE_修改執行個體的記憶體大小一:修改oracle資料庫執行個體記憶體大小指令碼
  1  ---- 1、操作 (oracle使用記憶體約等於 SGA+PGA,所以可以減少SGA與PGA解決你的問題,生產庫慎用)  2 alter system set sga_max_size=100m scope=spfile; --減少SGA大小,靜態參數,重啟後生效  3 alter system set sga_target=80m scope=both; --動態參數;oracle推薦:啟動時修改此參數,不要動態設定此參數  4 alter system set pga_aggregate_target=40m sope=both; ---減少pga大小


二:知識點拓展:

SGA_MAX_SIZE的大小不是隨意指定的,必須滿足一定條件的。
sga_max_size=100M,必須滿足SGA所有組件的最小和;至少滿足db_cache_size,log_buffer,shared_pool_size,large_pool_size,java_pool_size總和的大小)

  1 oracle記憶體結構介紹:  2 Introduction to Oracle Memory Structures  3 Oracle uses memory to store information such as the following:  4   5 Program code  6 Information about a connected session, even if it is not currently active  7 Information needed during program execution (for example, the current state of a query from which rows are being fetched)  8 Information that is shared and communicated among Oracle processes (for example, locking information)  9 Cached data that is also permanently stored on peripheral memory (for example, data blocks and redo log entries) 10 The basic memory structures associated with Oracle include: 11 System Global Area (SGA), which is shared by all server and background processes. 12 Program Global Areas (PGA), which is private to each server and background process; there is one PGA for each process. 13  14 1.sqlplus “/ as sysdba"  2. 3.create pfile=‘d:/cj.ora‘ from spfile;  然後去你的oracle安裝目錄 15   找一個init資料庫名。ora這樣一個檔案 16  17   把幾個oracle記憶體參數改小點 18  19   一個2G的記憶體是如下配置的: 20  21   *.sga_max_size=712M 22  23   *.large_pool_size=8M 24  25   *.shared_pool_size=250M 26  27   *.sort_area_size=0.5M 28  29   *.db_cache_size=350M 30  31   然後shutdown資料庫 32  33   1.shutdown immediate;  2. 3.create spfile from pfile=‘d:/cj2.ora‘;  4. 5.startup;  然後啟動,就可以了。 34  35   以上就是調整oracle記憶體參數,減少資料庫記憶體佔用的方法介紹。

ORACLE_修改執行個體的記憶體大小

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在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.