1830895 Members
2744 Online
110017 Solutions
New Discussion

Memory Windows

 
SOLVED
Go to solution
Sundar_7
Honored Contributor

Memory Windows

Hi all, I am little confused here. On a N4000 with 11.0, I have 3 development oracle instances running (Oracle 8.1.7 which I believe is a 32-bit database).

This development server has around 4GB of physical memory and the system has been experiencing memory pressures, with memory usage always at 99%. Huge portion of the memory is taken by the 170+ oracle client connections, each occupying 15-19 MB of memory.

Swap usage is only 37%.

I am suggesting we should add more physical memory to avoid Pages out (and thus performance degradation). But my DBA's were told by someone, since we are running 32 bit oracle, it cannot address more than 4GB and we should use memory windows to work around the limitation.

I understand 32-bit applications can only address up to 4GB of physical memory. But my understanding is that memory windows only help in creating bigger shared resources (like shared memory).

So, my theory is , if I add 1 GB more physical memory (total 5GB), the system can accommodate more oracle client sessions without paging, since each individual oracle client process is not going to take up more than 18-20 MB.

DBA's theory was agreed upon by my senior colleagues some 2 years ago. So, before I conclude they are wrong, I would want you folks opinion.

Any useful elaborate replies will be appreciated with bunnies :-)

- Sundar
Learn What to do ,How to do and more importantly When to do ?
7 REPLIES 7
Patrick Wallek
Honored Contributor
Solution

Re: Memory Windows

Since you've only got 4GB of RAM on the machine, memory windows will not help you a whole lot (in my opinion).

It is true that ALL 32-bit apps use the same shared memory, but without more RAM in the machine, there won't be a whole lot of working room for the programs to spread out even with memory windows.

At this point I believe you would be better off adding RAM. I would add at least 2GB and see how things work from there.
RAC_1
Honored Contributor

Re: Memory Windows

I agree with you. With memory windows, you can seperate memory windows (shared memory) for each of oracle instance. But with memory utilization at 99 %, it would not help mauch because--
1 Seperate windows will be fomred for each of oracle instances, grabbing the memory first.
2. Oracle clients grabbing 20-30 mb, will soon hit memory bottleneck and I think more swapping will take place.

with adding some more RAM, you atleast can get some free memory (with same no. oracle client connections that are there at the moment)

you may also want to have a loko at reducing SGA a bit for each of oracle instance, this would give more memry for users.

Anil
There is no substitute to HARDWORK
G. Vrijhoeven
Honored Contributor

Re: Memory Windows

Hi Sundar,

Shared memory can be max 1,75/2,75 GB in total for 32 bits programs. There are a couple of useful documents installed in /usr/share/doc.

mem_mgt.txt is the HP-UX memory management white paper.

mem_wndws.txt is the Memory Windows white paper and it describes how you can create multiple 'windows' of shared memory segments up to the 1.75Gb limit for 32 bit processes.

There are also kernel parameters involved:
http://docs.hp.com/hpux/onlinedocs/939/KCParms/KCparam.SharedMemParmsList.html

The total of 4 GB is the max for 32 bits apps, but your server also needs memory for buffercache, kernel etc..

Regards,

Gideon
A. Clay Stephenson
Acclaimed Contributor

Re: Memory Windows

Well, you're both right. Memory windows will help because each group of related processes (in your case, each Oracle instance) can get it's own 4GB virtual address space. This applies to more than simply shared memory. However, memory windows will not reduce your pageouts; only more memory will do that. The combination of more memory and memory windows will allow more efficient Oracle (bigger SGA's) and better performance. By the way, 4 or 5 GB of memory for multiple Oracle instances is considered tiny by today's standard so you might consider more than an additional 1GB.

One important point: If you are paging out to any significant degree, immediately reduce the size of the SGA's. Swapping will completely overwhelm (by ~ 2 orders of magnitude) any gains you get from caching in the database.
If it ain't broke, I can fix that.
Sundar_7
Honored Contributor

Re: Memory Windows

Thanks for all the replies. But unfortunately, I am not very clear, yet.

3 development instances have SGA size of (600 + 600+ 200 = 1400 MB). Does that mean only 350MB more shared resource can be allocated in the system by the oracle ?

If I add more memory to the system, can the oracle client process address the free space available from 4GB onwards ?
Learn What to do ,How to do and more importantly When to do ?
Victor BERRIDGE
Honored Contributor

Re: Memory Windows

Hi Sundar,
I would agree having configured and used memory windowing that it could solve some of your issues, but not all...
you say 37% of swap but we dont know how much swap you have...
Just to say well configured (find an acceptable compromize that is) can do if not miracles quite impressive results, I had till last year a K360 with 2GB of RAM 4 GB swap on external disks (it booted also on it with 2 scsi controllers) that run 6 oracle instances (8.0.4, 8.0.5 and 8.1.7)and a sybase instance, ok they werent big - total disk space 70GB the lot lived in perfect harmony with nobody complaining with on bad days more than 800 simultaeous connections but a day came when some DBA decided to "optimizing ORACLE" changed on a instance when as already said no complains the size of a instance SGA, this had as side effect the impossibility to restart th most important instance of the box...

Now you know nothings impossible, what can you do:
a)are you sure you need such sized SGA?
b)Turn off swapmem_on param since you are limited in RAM there is no reason to swap there.
c)Add maybe more swap to fool oracle
d)use 2 memory windows to overcome the 1.7 GB limitation
e) Try to resize dbc_min_pct and dbc_max_pct to gain some RAM (since you have privileged oracle SGA...) max to about 300MB
Im sure you could do with reducing the SGA size a bit since you have so many connections...

My 2 cents

All the best
Victor
A. Clay Stephenson
Acclaimed Contributor

Re: Memory Windows

No, the global shared memory limit for 32-bit processes is 1.75GB (2.75 GB if the applications use SHMEM_MAGIC). This means that even if you expanded to 10GB of memory only a total 1.75GB of shared memory would be available for the entire pool of 32-bit processes.

Memory windows creates a separate VAS for each group of related processes so that the global 1.75GB limit no longer applies.

Again, memory windows won't reduce your pageouts; only memory can do that but they would allow each of your Oracle instances, for example, to have a 1GB (or larger) SGA. Large SGA's like this only make sense if the pageout rate is very, very low (0) otherwise any gains your DBA's think they get from database and/or UNIX buffer caching are completely swamped (~ 100x) by the swapping.
If it ain't broke, I can fix that.