[IQUG] How much percentage of RAMs should be allocated to shared memory at Linux?

Steve Shen sshen at sscinc.com
Fri Sep 14 12:05:00 MST 2018


Hi Kerby,

I did observe relatively high O/S paging while the development managers were complaining about the performance bottleneck.  The O/S paging that I observed included swapping from RAMs to disks and from disks to RAMs.

What is the general guideline for allocating the maximum shared memory at Linux.  I can easily request UNIX SAs to reset it to 7/8 or 3/4; but is this the best practice because I have no way to tell how much shared memory is really needed by IQ.

I do not think any of the following parameters used shared memory; but feel free to correct me if I am wrong:
-iqlm
-iqmc
-iqtc

They took away around 75% of the total RAMs in that IQ host.

Thanks and regards,
Steve Shen
From: Gehman, Kirby [mailto:kirby.gehman at sap.com]
Sent: Friday, September 14, 2018 2:53 PM
To: Steve Shen; 'Mark Mumy'
Cc: iqug at iqug.org
Subject: RE: [IQUG] How much percentage of RAMs should be allocated to shared memory at Linux?

You can absolutely set SHMMAX larger than your system RAM and the OS will boot successfully.  SHMMAX is simply the largest memory segment that can be allocated.  It may not be the best thing for your system, though:

“There are no practical implications of having SHMMAX > physical RAM, unless you actually start using that RAM. Just be aware that if you start allocating more shared memory than your system has available RAM your system will swap (just like any other time you over-allocate RAM), which is certainly a performance killer.”



Kirby Gehman
Platinum Technical Support Engineer
Digital Business Services
SAP North America
T +1 519 883-4803, E kirby.gehman at sap.com<mailto:kirby.gehman at sap.com>

http://www.sap.com/ unsubscribe<https://global.sap.com/profile/unsubscribe.epx?PID=10386&PFID=12894>



From: iqug-bounces at iqug.org<mailto:iqug-bounces at iqug.org> <iqug-bounces at iqug.org<mailto:iqug-bounces at iqug.org>> On Behalf Of Steve Shen
Sent: Friday, September 14, 2018 1:43 PM
To: 'Mark Mumy' <markdmumy at gmail.com<mailto:markdmumy at gmail.com>>
Cc: iqug at iqug.org<mailto:iqug at iqug.org>
Subject: Re: [IQUG] How much percentage of RAMs should be allocated to shared memory at Linux?

Hi Mark,

I did know that IQ needed the shared memory; but IQ is not like ASE.  ASE could not work without having enough shared memory allocated.

The following statement should be more applicable to ASE instead of IQ:
                Never set shmmax to a value greater than 7/8 of physical memory.

It’s still a valid statement; but 7/8 were too high!

We totally separated IQ server from the client machines.  So the following configuration seemed wrong to me:

sybase at ykt1eiqprd37: /siqsoftware/sybase ==> cat /proc/sys/kernel/shmmax
18446744073692774399

It’s much more than 100% of the total RAM.  How could the Linux be booted successfully?  Could it be that Linux just ignore it and IQ also ignore it?  It did not seem likely, right?

Thanks and regards,
Steve Shen
From: Mark Mumy [mailto:markdmumy at gmail.com]
Sent: Friday, September 14, 2018 2:32 PM
To: Steve Shen
Cc: iqug at iqug.org<mailto:iqug at iqug.org>; mark.mumy at sap.com<mailto:mark.mumy at sap.com>; Baker, Chris
Subject: Re: How much percentage of RAMs should be allocated to shared memory at Linux?

IQ does use shared memory for the server.  By default.  It can be used for clients on the same host.
Mark

========================

Sent from my mobile device

On Sep 14, 2018, at 13:20, Steve Shen <sshen at sscinc.com<mailto:sshen at sscinc.com>> wrote:
Today’s Topic:
                How much percentage of total RAMs should be allocated to shared memory at Linux?
                What was the negative impacts from over-allocating shared memory at Linux?

Today I spotted something very odd;  but I have not received any feedbacks from UNIX SA managers so far.
Refer to the following:

sybase at ykt1eiqprd37: /siqsoftware/sybase ==> cat /proc/sys/kernel/shmmax
18446744073692774399

There are 762 GB of RAMs in the machine.  Defining 18,446,744,073,692,774,399 KB was beyond my imagination!

The statement below should be applicable to both Solaris and Linux:
                Never set shmmax to a value greater than 7/8 of physical memory.

How could the shared memory defined so high and the Linux O/S was booted successfully?

sybase at ykt1eiqprd37: /siqsoftware/sybase ==> ipcs -l

------ Messages Limits --------
max queues system wide = 32768
max size of message (bytes) = 8192
default max size of queue (bytes) = 16384

------ Shared Memory Limits --------
max number of segments = 4096
max seg size (kbytes) = 18014398509465599
max total shared memory (kbytes) = 18014398442373116
min seg size (bytes) = 1

------ Semaphore Limits --------
max number of arrays = 4096
max semaphores per array = 250
max semaphores system wide = 32000
max ops per semop call = 32
semaphore max value = 32767

I had read the document below.  I am not using wired memory at all.  We have different dedicated IQ server and client machines.

http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc30066.1540/doc/html/san1282692444252.html

Manage Shared Memory
In some cases, increasing the shared memory segment can lead to better network performance.
Sybase IQ uses shared memory for two purposes:

  *   When the client and Sybase IQ are on the same system, shared memory is the default communication mechanism, not TCP/IP.
  *   When you specify the server command-line option -iqwmem, shared memory is used to provide wired memory.
If the -iqwmem option is used, you need to increase the maximum shared memory segment size parameter in the /etc/system configuration file. Sybase recommends that you specify a configuration for the largest amount of wired memory you expect your system to support.
To create a shared segment to support a maximum physical memory of 3350MB for your system, for example, add the following line to the /etc/system file:
set shmsys:shminfo_shmmax=0xffffffff
Never set shmmax to a value greater than 7/8 of physical memory.
Local connections through shared memory are not supported for Sun Solaris x64 systems. Use standard network connectivity by adding the parameters -host <hostname> and -port <portnumber> to the client connection string.
See the Sybase IQ System Administration Guide for more information on using the -host and -port parameters.
Regards,
Steve Shen
This email with all information contained herein or attached hereto may contain confidential and/or privileged information intended for the addressee(s) only. If you have received this email in error, please contact the sender and immediately delete this email in its entirety and any attachments thereto.
This email with all information contained herein or attached hereto may contain confidential and/or privileged information intended for the addressee(s) only. If you have received this email in error, please contact the sender and immediately delete this email in its entirety and any attachments thereto.
This email with all information contained herein or attached hereto may contain confidential and/or privileged information intended for the addressee(s) only. If you have received this email in error, please contact the sender and immediately delete this email in its entirety and any attachments thereto.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://iqug.org/pipermail/iqug/attachments/20180914/a88ec56e/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.png
Type: image/png
Size: 4700 bytes
Desc: image001.png
URL: <http://iqug.org/pipermail/iqug/attachments/20180914/a88ec56e/attachment-0001.png>


More information about the IQUG mailing list