cancel
Showing results for 
Search instead for 
Did you mean: 

How much Solaris memory allocated by ASE 15.0.3?

Former Member
0 Kudos
281

Hi.

I'm running ASE 15.0.3 on a Solaris 10 system. There is 16GB physical memory. I have set max memory to 15GB. Also, allocate max shared memory is 0, and dynamic allocation on demand is 1. When I look at total logical memory it shows as 13GB.

I have been having problems on this system, getting occasional "Vfork failed" errors, which I take to mean the system is running out of memory. So I have been looking at top and other tools to try to get a handle on that.

Those tools are telling me that the ASE engine is using 15GB of memory. Also, when I had Oracle tech support analyze the problem, they said the same thing. But based on the ASE memory settings I listed above, I would expect that it should be using only 13GB.

I conclude that I must be misunderstanding either ASE's memory strategy, or the output of the top command. Does anyone have any insights?

Thanks.

- John.

Former Member
0 Kudos

Thanks Mark. I don't quite understand everything you said though.

"Because of your 'allocate max shared memory' and 'dynamic allocation on demand' settings I wouldn't be surprised if you have a lot of entries in the 'ipcs -a' output, ie, shared memory is fragmented."

I have 'allocate max shared memory' as 0, which as I understand it means that it'll allocate my entire 'total logical memory' (which is and has always been 13GB) at startup. This seemed to be confirmed by ipcs, which showed a big fragment of 13GB and then 1-2 additional small fragments. (Unfortunately I have rebooted the server since yesterday and I didn't record the exact details.)

"If possible you may want to consider setting 'allocate max shared memory = 1' and then bouncing the dataserver; this should reduce the number of fragments"

My 'max memory' was set to 15GB. So as I understand it, your suggestion would cause it to

allocate 15GB at startup. This seems like it's going the wrong direction. That would cause me to alloocate MORE memory than I would otherwise. And furthermore, since that's 2GB more than my 'total logical memory', I will be wasting 2GB. I don't understand how any of that would be a good thing.

"If you continue to have memory problems you may want to dial back 'max memory' some (eg, reduce by 1GB) and bounce the dataserver again."

That's what I did. I dialed it back by 2GB. So now my 'max memory' and 'total logical memory' are nearly the same, namely 13GB. At this point, now 'top' shows the dataserver using 13GB, which seems logical. What I still don't understand is how, prior to the reboot, 'top' showed usage of 15GB when my 'total logical memory' was only 13GB.

javier_barthe
Participant
0 Kudos

John,

Another good reason in order to allocate max shared memory and don`t allocate memory dynamically its that if you pinned memory locking (lock shared memory = 1) it memory pages used by dataserver are huge pages so this benefit ASE.

I have made this changes in AIX and REDHAT, never in solaris. Here is a very good link about performance in linux environments:

http://www.petersap.nl/SybaseWiki/index.php?title=Linux_configuration_settings_for_Sybase_ASE

I hope this help.

corral
Explorer
0 Kudos

Some pieces of warning about "lock shared memory". This configuration option should only be activated when the whole machine has enough physical memory for all the applications to run smoothly. By reserving physical memory for ASE shared memory, ASE is reserving a large portion of memory at the expenses of the rest. If this will drive other applications to starve on memory, better don't let ASE be so greedy and either deactivate "lock shared memory" or decrease ASE's configured memory.

If the plan is to give to ASE 15 GB of a total of 16, better don´t lock ASE shared memory.

Also, if ASE shared memory is not locked and ASE is experiencing heavy paging activity, perhaps is better to reduce ASE's memory. It is an inefficient situation if ASE thinks there is some memory for her use but those memory pages have been paged out to swap files. It is better to configure only the memory that normal ASE activity will be able to reference often enough as to never be paged out by Solaris. Solaris will page out the oldest pages (old in terms of their last reference, no matter it is a read or a write) Too large a cache will cause some pages being too old, so possibly being paged out by Solaris. In this case, my advice is to shrink that cache.

Regards,

Mariano Corral Herranz

javier_barthe
Participant
0 Kudos

Hi Mariano,

I´m totaly agree with you, I was talking about an escenario in which ASE was the only application running on Solaris. So all the phyisical memory will be assigned for ASE, taking care about leaving Solaris memory enough in order to run without problems even more if you have shell scripts inside ir order to send alerts. We have to avoid paging in order to get a better performance.-

Thanks!

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Thanks to everyone for all the hints. I still don't understand all the ins and outs, but this really helps me. In my case this is a statically-configured system, i.e. I set it up months or years ago with a particular max memory and a particular total logical memory, and I might make changes only very rarely, and when I do I will tend to reboot the machine soon afterwards. This machine is dedicated to running ASE. My puzzle was why, out of the blue, did this system start experiencing memory-related issues. Especially when other ASE systems of mine run fine with a nearly identical configuration. Anyway, since my last post I have played with the memory settings, and ended up reducing total logical memory by 1GB and max memory by 2GB, and the problems seem to have stopped. For now I'm just going to go with that and maybe I'll figure it all out later. (Someone hinted to me that the culprit could be the ZFS cache...)

Thanks.

- John.

claude
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi,

Here is a rule to remember:

"max memory" is the a configurable parameter (its the memory customer asks
                for while booting the server or change dynamically.)

"total physical memory " is the memory we got from the OS till now.  (This could be less than MM when we
                have not grabbed all the required memory from OS.
                Some times this could be greater than MM as we grab memory which should be pagesize alined.

"total logical memory" is the memory which is required for the for the current configuration of ASE.
                This value is calculated/used internally. The "max memory"  should be greater than TLM.

If "allocate max shared memory" = 1 ===> (MM > TLM)  & TPM >= MM

And if allocate max shared memory" = 0   ===> (MM > TLM)  & (TPM >=< MM)

I hope this will help .

javier_barthe
Participant
0 Kudos

John,

Monitor Solaris memory with prstat or vmstat in a constant way. Then try to increment Solaris memory, 20% of total memory  is recommended for SO in most installations.