Operating System - Linux
1754219 Members
3676 Online
108812 Solutions
New Discussion юеВ

Re: kernel parameters in Linux?

 
SOLVED
Go to solution
Geetam
Frequent Advisor

kernel parameters in Linux?

How do I check/change kernel parameters in Linux (RedHat6.2)?

I am trying to install an Oracle database and the installation procedure specifies recommended values for e.g. shmmax and semmni

Thanks
9 REPLIES 9
Albert E. Whale, CISSP
Honored Contributor

Re: kernel parameters in Linux?

Geetam,

The first thing thast you'll need are the kernel source rpms. You should also probably install the Kernel-Header files as well.

There are MANY Exceptional resources which can guide you through the Kernel Compilation process.

The one that probably answers all of your questions is at http://www.linuxdoc.org/HOWTO/Kernel-HOWTO.html I would consider this as the definitive resource for the Linux Kernel.

Please let me know if this resolved your problem.

Have a Great Day!
Sr. Systems Consultant @ ABS Computer Technology, Inc. http://www.abs-comptech.com/aewhale.html & http://www.ancegroup.com
Albert E. Whale, CISSP
Honored Contributor

Re: kernel parameters in Linux?

Geetam,

One more thing, the file you are looking for should be in /usr/src/linux/asm-i386/shmparam.h

Hope that helps!

Have a Great Day!
Sr. Systems Consultant @ ABS Computer Technology, Inc. http://www.abs-comptech.com/aewhale.html & http://www.ancegroup.com
Geetam
Frequent Advisor

Re: kernel parameters in Linux?

I am sorry to say that it does not help me very much.

I have had a good look around HOW_TOs and kernel config files and I have seen lots of things to do with configuring modules and drivers into the kernel, but I have nothing related to shmmax, semmni etc.

Can you be a bit more specific. Thanks
Albert E. Whale, CISSP
Honored Contributor

Re: kernel parameters in Linux?

Geetam,

Ok, then let's start with this, when you type:

rpm -qa | grep kernel

Do you get:

kernel-doc-2.2.15-4mdk
kernel-headers-2.2.15-4mdk
kernel-source-2.2.15-4mdk

Or something similar?

If not, these are the very first thing that you'll need inorder to compile a kernel.

In order to change shmmax on a permanent basis, you need these files. You see the shmparam.h file is contained in the Kernel Header file:

rpm -qf shmparam.h
kernel-headers-2.2.15-4mdk

I have attached the shmparam.h file for your convenience.

Hope that gets you started!
Sr. Systems Consultant @ ABS Computer Technology, Inc. http://www.abs-comptech.com/aewhale.html & http://www.ancegroup.com
Geetam
Frequent Advisor

Re: kernel parameters in Linux?

Albert

I think I am getting the idea, is this right?
. These parameters are compiled into the kernel (same as HP-UX).
. To change them I need to change the relevant .h files and recompile.

So there is no nice interface like HP-UX SAM?


Here is the output of the 'rpm' commands you suggested:

# rpm -qa | grep kernel
kernel-headers-2.2.14-5.0
kernel-2.2.14-5.0
kernel-pcmcia-cs-2.2.14-5.0
kernel-source-2.2.14-5.0
kernel-utils-2.2.14-5.0
kernelcfg-0.5-5

# rpm -qf shmparam.h
file shmparam.h: No such file or directory

Is this because 'kernel-doc' is missing?
But I can see shmparam.h in /home/src/linux-2.2.14/include/asm-i386/ and in various other places.


This is a full list of the parameters Oracle is suggesting:
SHMMAX 4294967295
SHMMIN 1
SHMMNI 100
SHMSEG 10
SEMMNS 200
SEMMNI 70
SEMMSL Equal to or greater than the value of the PROCESSES initialization parameter.

I don't see all of them in shmparam.h

Thanks
Albert E. Whale, CISSP
Honored Contributor

Re: kernel parameters in Linux?

Hey, is any of this information worth a few 10 pointers? If so, could you apply the points for me?

Now back to your question.

try the following:

cd /home/src/linux-2.2.14/include/asm-i386/

then type

grep SHMM *.h

You will see that all of the SHMM variables are int he shmparam.h file.

If you like I can track down the implementation of the semaphore values.

Please let me know.

Sr. Systems Consultant @ ABS Computer Technology, Inc. http://www.abs-comptech.com/aewhale.html & http://www.ancegroup.com
Geetam
Frequent Advisor

Re: kernel parameters in Linux?

Points: sure, I always assign points (I thought I had done it already...)

I still cannot find reference to the kernel parameters starting with SEM

Thanks
Albert E. Whale, CISSP
Honored Contributor
Solution

Re: kernel parameters in Linux?

Geetam,

The reason that you cannot find the SEM (or semaphore) parameters, is because they have been located in the /usr/src/linux/include/linux directory, in the file called sem.h.

That should cover all of your Semaphore and Shared Memory parameters.

I tried several site to locate a White Paper, but as of yet cannot find one. Even tried Oracle, but alas they want to charge you for this same information. Information that only costs you the time to give a few points away.

Hope this helps you. If not feel free to post again. I leave the lights on.

Have a Great Day!
Sr. Systems Consultant @ ABS Computer Technology, Inc. http://www.abs-comptech.com/aewhale.html & http://www.ancegroup.com
Jerome Fenal_1
Valued Contributor

Re: kernel parameters in Linux?

I don't think that recompiling the kernel is good way to do that. Maybe for HP-UX with SAM... Or for variables not exported in /proc.

To avoid recompiling your kernel (for parameters available), you have the sysctl interface. It is available in the /proc fs. A good reading about it could be found at http://www.bb-zone.com/Proc/.
The variables could be permanently (ie. over reboots) by using the file /etc/sysctl.conf, found in Mandrake 7.1, which could also be in RH6.2.

Regards,

Jerome
Bienvenue chez moi