LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 04-10-2014, 05:27 AM   #1
Spiros85
LQ Newbie
 
Registered: Apr 2014
Posts: 4

Rep: Reputation: Disabled
Default values of shmal, shmmax and shmmni


I read this article where it presents some ways to calculate the shmall and shmmax.

My distro is Oracle Linux and I wanted to find out the initial amount of memory my distro uses in order to calculate those values.

The first step was to take a look at the values contained at /etc/sysctl.conf
[root@server ~]# sysctl -a | grep shm
kernel.shmmax = 68719476736
kernel.shmall = 4294967296
kernel.shmmni = 4096

Second I used 'ipcs -lm' command
[root@server ~]# ipcs -lm

------ Shared Memory Limits --------
max number of segments = 4096 -----> shmmni (It is expressed in Pages)
max seg size (kbytes) = 67108864 -----> shmmax (It is expressed in Kbytes)
max total shared memory (kbytes) = 17179869184 -----> shmall (It is exressed in Kbytes)
min seg size (bytes) = 1

According to the article I posted, if you want to find shmall for 11GBs of memory you have to do the following mathematical equation:
(11*1024*1024*1024)/4096

By given the values of 'ipcs -lm' command, I wanted to verify the values contained to '/etc/sysctl.conf'
shmall = (17179869184/4096)*1024 = 4294967296
shmmax = 67108864*1024 = 68719476736

Let's find the value of 'shmmax' from 'shmall'
shmmax = (17179869184/1024)*4096 = 68719476736 (This is the value in '/etc/sysctl.conf')
68719476736/1024 = 67108864 ----> (This is the value in Kbytes displayed by 'ipcs -lm')

So based on the upon information to find out the initial amount of RAM used to calculate those values, I did:
((4294967296*4096)/1024*1024*1024) = 16384

That means my Oracle Linux does this calculations for 16384 Gbs?

Thanks In advance
 
Old 04-11-2014, 01:53 PM   #2
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
check out http://www.puschitz.com/TuningLinuxForOracle.shtml
 
Old 04-12-2014, 09:27 AM   #3
Spiros85
LQ Newbie
 
Registered: Apr 2014
Posts: 4

Original Poster
Rep: Reputation: Disabled
Dear Habitual

I also checked yesterday this link by doing examples for other values too, and I came to the conclusion those mathematical calculations are correct!

Thanks

Spiros
 
Old 04-12-2014, 10:00 AM   #4
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
I've relied on what puschitz.com writes about Oracle+Linux(CentOS) since 2000, but I have not verified any of what's written since about 2002.
What he wrote and said should be used, I did and it worked at that time.

See also https://search.oracle.com/search/sea...r=all&q=shmmax
and
https://search.oracle.com/search/sea...r=all&q=shmall
for something to compare his recommendations against, which should be "more" current.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Where does default ulimit values come from? suhas! Linux - Server 9 12-13-2012 04:57 PM
[SOLVED] Value of shmmni d072330 Linux - Newbie 2 11-15-2010 05:53 PM
how can I see the default UID values on different distros? elrom Programming 1 11-13-2007 09:15 AM
How to know SHMSEG, SHMMIN,SHMMAX and SEMMAP current values sunilvadranapu SUSE / openSUSE 1 09-19-2007 03:18 AM
useradd with default values ?! realos Linux - Newbie 1 08-09-2002 07:38 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 08:55 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration