[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

how to increase the SGA_MAX_SIZE IN ORACLE 10G

Posted on 2009-05-19
5
Medium Priority
?
2,998 Views
Last Modified: 2013-12-18
HI EXPERT, I  HAVE THE ORACLE 10G SERVER, I HAVE ADDED RAM IN IT,NOW THE TOTAL RAM IS 8 GB AND THE OS IS WINDOWS SERVER 2003 32- BIT ENTERPRISE EDITION.
STILL THE PERFORMANCE OF THE DATABASE IS SAME,SO I WANT TO INCREASE THE SGA_MAX_SIZE.SO PLEASE LET ME KNOW THE WAY TO INCREASE IT.
0
Comment
Question by:ajayg161073
  • 2
  • 2
5 Comments
 
LVL 48

Accepted Solution

by:
schwertner earned 1500 total points
ID: 24422526
From Oracle point of view it is easy:

SQL> ALTER SYSTEM SET SGA_MAX_SIZE = 2G SCOPE=BOTH;

From Windows point of view you have to ensure that windows will be able to manage the whole RAM:

Use PAE feature:

http://www.microsoft.com/whdc/system/platform/server/PAE/PAEmem.mspx

http://www.microsoft.com/whdc/system/platform/server/PAE/pae_os.mspx
0
 
LVL 4

Expert Comment

by:Ronb23
ID: 24422553
Step 1:
      SQL> ALTER SYSTEM SET SGA_MAX_SIZE=2000M SCOPE=spfile;
Step 2:
      SQL> shutdown immediate;
      SQL> startup

To verify that the change was made:
      SQL> show parameter sga_max_size
Step 3:
      SQL> Create pfile from spfile;

*** Remember that you will need to restart the database
0
 
LVL 35

Expert Comment

by:Mark Geerlings
ID: 24426513
Please be advised that 32-bit Windows by default will not allow any single program to use more than 2GB of RAM (no matter how much RAM the server has).  If you add the "/3GB" switch to the C:\boot.ini file, then reboot, Windows can allow a single program (like an Oracle database) to use up to 3GB of RAM (but not 8GB).  Also, an Oracle database running on Windows requires memory for user connections and other parts of the database so the SGA_MAX_SIZE cannot be 3GB even if you use the "/3GB" switch in the boot.ini file.

The Windows O/S also needs some memory for itself (at least 1-2GB, for best results) so Oracle cannot use all of the RAM.  When we ran Oracle9 on 32-bit WindowsServer2003 with 8GB of RAM, we found that we still could set the SGA_MAX_SIZE no larger than 1.5GB.  But we needed to support up to 520 concurrent user connections.  We had to use "orastack.exe" to reduce the amount of memory used per connection to support that number of user connections.  If you have to support only a few dozen connections or less, you may be able to have a an SGA_MAX_SIZE closer to 2GB, if you use the "/3GB" switch.

We used RAMdisk software (from: www.superspeed.com) to use 1GB of our RAM for a RAMdisk, then we moved the Oracle temp tablespace to the RAMdisk.  That greatly speeded up some of our processes and queries that needed lots of temp tablespace I/O.

i think there is a way that Oracle on 32-bit Windows can support a larger SGA that what I described earlier but *ONLY* for block buffer space, and only if you make some other adjustments and concessions.
0
 
LVL 35

Expert Comment

by:Mark Geerlings
ID: 24612863
You accepted the comment that specifically answered your question, but I doubt that that step helped you very much.  I suspect the problem is bigger than simply making the SGA larger.
0
 
LVL 48

Expert Comment

by:schwertner
ID: 24613481
I agree.
But be aware that the performance of a DB is connected mainly with the throughout
of the disk devices, the parallel work of tablespaces (tables and index), the network bandwith if you use SAN
and so on. There are not so much cases when big RAM will help you.
The explanation is that I/O activity is prevalent in the DB work.
RAm is used for caches. They also can help, but if you do not deliver fresh statistics, do not divide the tablespaces on separate disks there will be not significant performance improvement.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
This video shows syntax for various backup options while discussing how the different basic backup types work.  It explains how to take full backups, incremental level 0 backups, incremental level 1 backups in both differential and cumulative mode a…
This video shows how to Export data from an Oracle database using the Datapump Export Utility.  The corresponding Datapump Import utility is also discussed and demonstrated.
Suggested Courses
Course of the Month17 days, 18 hours left to enroll

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question