Wednesday, August 7, 2013

Oracle Database Preinstallation – Part 14

Dear Readers,

My name is Franz Devantier, creator of this blog.  I am an Oracle Certified Professional (OCP DBA 11g) Security DBA.  I will be sharing with you the basic duties of an Oracle DBA, and also some of the undocumented, and not so well known tasks. 

For Companies:
Free Database health check, for your database installation.  One months free database support, for you, as a proof of concept.

For individuals:
Refer me to a company for a database support contract.
=> I will then give you 10% of the monthly contract value, for the duration of the contract.  Plus when the contract is extended or renewed you will still get 10% of the monthly contract value, until I no longer support the company, sometime in the future.
=> This 10% is my marketing budget, so if you refer me to a company I will give you my marketing budget.  Now that is probably the best deal you will ever get for a referral.
Oracle Database Preinstallation – Part 14
Configuring the oracle User’s Environment
You are almost ready now to run Oracle Universal Installer(OUI) from the oracle account.

You run Oracle Universal Installer from the oracle account. However, before you start Oracle Universal Installer, you must configure the environment of the oracle user. To configure the environment, you must:
=> Set the default file mode creation mask.  The 022 is an octal number representation.  The 755 is the decimal number that is derived from converting the binary number: 111 101 101 to 755

Octal value : Permission
0 : read, write and execute
1 : read and write
2 : read and execute
3 : read only
4 : write and execute
5 : write only
6 : execute only
7 : no permissions

$ umask 022

This effectively gives the permissions of 755
Which means:
User  : read, write and execute
Group: read and execute
Other : read and execute

To set the oracle user’s environment:
=> Start a new terminal session, for example, an X terminal, by using a tool such as xterm.
=> Make sure that X Windows applications can display on this system
$ xhost fred.oracle.oneway.com
=> Log onto the system where you want to install the software as the oracle user.
=> If you are logged in as root, then you can just:
$ su – oracle
=> Determine which shell you are logged in to.
$ echo $SHELL
=> run the shell startup script.
Bash shell
$  ../.bash_profile

Bourne or Korn shell
$  ../.profile

C shell
% source ./.login

=> If yo are not installing the software on the local computer, then run the following command on the remote computer to set the DISPLAY variable.
Bourne, Bash, or Korn shell
$ export DISPLAY=<Host name or IP address>:0.0

C shell
% setenv DISPLAY <Host name or IP address>:0.0

Verify that the SHELL and DISPLAY environment variables are set properly on the remote computer.
$ echo $SHELL
$ echo $DISPLAY

Now back to the local computer, and enable X applications
$ xhost + <fully qualified remote host name>

Run the xclock application to verify that all is working corerectly
$xclock
You should get a small window popping up on your screen showing a clock.  You can close this application now.

Xclock is usually located at /usr/X11R6/bin/sclocks

=> if the /tmp directory has less than 1GB of free space, then find a file system with enough space, and set the TMP and TMPDIR environment variables to this identified file system.
$ df –h /tmp
$ sudo mkdir /<mount_point>/tmp
$ sudo chmod 760 /<mount_point>/tmp
$ TMP = /<mount_point>/tmp
$ TMPDIR = /<mount_point>/tmp
$ export TMP TMPDIR

=> set the ORACLE_BASE and ORACLE_SID environment variables.

$ export the ORACLE_BASE=/u01/app/oracle
$ export ORACLE_SID=SELLER

=> Make sure that the ORACLE_HOME and TNS_ADMIN environment variable is not set.
$ unset ORALE_HOME
$ unset TNS_ADMIN

Oracle recommends that if you set the ORACLE_BASE environment variable, that you should unset the ORACLE_HONE environment variable.  If you set the ORACLE_HOME environment variable, then OUI will use that value as the default path for the Oracle home directory.

Franz Devantier,
Need a database health check?
devantierf@gmail.com

Classifieds


Tuesday, August 6, 2013

Oracle Database Preinstallation – Part 13

Dear Readers,

My name is Franz Devantier, creator of this blog.  I am an Oracle Certified Professional (OCP DBA 11g) Security DBA.  I will be sharing with you the basic duties of an Oracle DBA, and also some of the undocumented, and not so well known tasks. 

For Companies:
Free Database health check, for your database installation.  One months free database support, for you, as a proof of concept.

For individuals:
Refer me to a company for a database support contract.
=> I will then give you 10% of the monthly contract value, for the duration of the contract.  Plus when the contract is extended or renewed you will still get 10% of the monthly contract value, until I no longer support the company, sometime in the future.
=> This 10% is my marketing budget, so if you refer me to a company I will give you my marketing budget.  Now that is probably the best deal you will ever get for a referral.

Oracle Database Preinstallation – Part 13
Configuring Storage for Oracle Database Files Using Block Devices
=> Firstly you need to use fdisk to create disk partitions on block devices for your database files.

=>  Create or modify the rules file in /etc/udev/rules.d, to change the permissions of the data files from the default root ownership.  Call this file 99-oracle.rules
Sample 1:
/etc/udev/rules.d/99-oracle.rules
#
# ASM disks
KERNEL=="sdb[6-9]", OWNER="oracle", GROUP="dba", MODE="0660"
KERNEL=="sdb10", OWNER="oracle", GROUP="dba", MODE="0660"

Sample 2:
/etc/udev/rules.d/99-oracle.rules
#
# ASM disks
KERNEL=="sdb[6-9]", OWNER="grid", GROUP="asmadmin", MODE="0660"
KERNEL=="sdb10", OWNER="grid", GROUP="asmadmin", MODE="0660"

KERNEL=="sdb[6-9]", OWNER="grid", GROUP="asmadmin", MODE="0660"
KERNEL=="sdb10", OWNER="grid", GROUP="asmadmin", MODE="0660"

Configuring Disk Devices for Oracle Database
The parameter O_DIRECT enables direct read and write to block devices, which avoids the kernel overhead.  With Oracle Database Server 10.2 and later, the Oracle Database files are configured by default to use direct input/output.

However with the 2.6 kernel or later for Red Hat Enterprise Linux, Oracle Linux, and SUSE Linux Enterprise Server, you will need to create a permissions file to maintain permissions on Oracle database files.  Without this permissions file, the permissions on disk devices revert to their default values, which are root:disk, this will result in Oracle failing to start.

=> On Red Hat Enterprise Linux 4 and Oracle Linux 4, you must create a permissions file number that is lower than 50.
=> On Asianux server 3, Red Hat Enterprise Linux 5 / 6, Oracle Linux 5 /6, SUSE Linux Enterprise Server 10 / 11, you must create a permissions file number that is higher than 50.

Configuring Block Device Storage for Oracle Database
=> Log on as the root user, or switch or sudo su switch to the root user.
$ sudo sh
Password
=> use the fdisk command to format a storage disk.  This could be something like /dev/sdb for example.
$ /sbin/fdisk /dev/sdb
=> Create a partition on this device, for example a few hundred megabytes that will be reserved for data files.
=> Update the kernel partition table for the shared storage device.
$ /sbin/partprobe diskpath

If you are installing additional Oracle Database 11.2 products in an existing oracle home.  Remember to stop all the processes, as well as the listener and database, that are running in this Oracle Home.  This is to enable OUI to relink the executables and libraries.  If everything is not stopped, then the relink could fail.

If you are going to use ASM and Oracle Restart, then you should start your Oracle 11.2 installation by installing the Oracle Grid Infrastructure.  If you have installed Oracle Grid Infrastructure, then the database must use the same listener that was created during the Oracle Grid Infrastructure installation, which will of course be running in the Oracle Grid Infrastructure home.

If you have an existing ASM infrastructure, then stop the existing ASM instance, Install the Oracle Grid Infrastructure software, and the start the Oracle ASM instance again.

If you choose to create a database, while you are installing the Oracle software with Oracle Universal Installer (OUI), then you will probably end up with an Oracle Net Listener using TCP/IP port 1521, and an IPC key value of “EXTPROC”.  If there is already an existing Oracle Net Listener process using for example 1521, then OUI will use the next available port, for example 1522, and will configure and start the new listener on this port (1522).

You must first determine if a listener process is running, and identify its name.
$ su – oracle

$ ps –ef | grep tnslsnr

You should get output something like:
$ORACLE_HOME/bin/tnslsnr LISTENER -inherit

You can set the ORACLE_HOME environment variable, if it is not already set by your .profile or similar file.

$ export ORACLE_HOME=/app/oracle…/home_1

Or in a C shell
$ setenv ORACLE_HOME <oracle_home>

=> Identify the TCP/IP port number and the IPC key value that the listener is using.

$ORACLE_HOME/bin/lsnrctl status <listener_name>

By default the listener name will be “LISTENER”.

If the listener running is using the default name, then you only need to enter.

$ lsnrctl status

To stop or start the listeners, you will enter something like the below for each listener on the server.

$ lsnrctl stop <listener_name>
$ lsnrctl start <listener_name>
And then to confirm that it is running as it should.

$ lsnrctl status <listener_name>

If you just enter:
$ lsnrctl
You will get the listener control prompt, whicu you can exit again with the “quit” command.

LSNRCTL> status <listener_name>

Franz Devantier,
Need a database health check?
devantierf@gmail.com

Classifieds

Sunday, August 4, 2013

Oracle Database Preinstallation – Part 12

Dear Readers,

My name is Franz Devantier, creator of this blog.  I am an Oracle Certified Professional (OCP DBA 11g) Security DBA.  I will be sharing with you the basic duties of an Oracle DBA, and also some of the undocumented, and not so well known tasks. 

I will make a deal with you:  If you refer me to a company that needs database support, from a few hours per week to full time, and I am able to sign a contract with them.
Then I will give you 10% of the monthly contract or deal price every month.  When the contract ends, and we re-sign the contract, I will again give you 10% of the monthly contract price.  This will go on until the company no longer employs or contracts me or my agents to look after their databases.
I can do this, because that 10% is my marketing budget.  When we re-sign the contract, in the future, it may depend on you giving the thumbs up again, and that is worth 10% of the monthly contract price, to be given to you as commission.

Oracle Database Preinstallation – Part 12
Choosing a Storage Option for Oracle Database and Recovery Files
The database files include data files, control files, redo log files, server parameter file (spfile), and the password file.  If you are going to enable automated backups during the installation, then you should also choose the storage option for the recovery files.  The recovery files will be in the fast recovery area.  You can use different storage options for each file type.  The good news in 11.2 is that database files and recovery files are supported on file systems and Oracle ASM.  This means that we can go all for ASM or file systems, or a combination of the two.

Guidelines for choosing your storage options.
=> You can implement on any combination of the supported storage options, for each file type.
=> Decide whether you want to store your database files, or your recovery files on Oracle ASM, or if you want to store both of them on ASM.

Creating Directories for Oracle Database or Recovery Files
Guidelines for Placing Oracle Database Files on a File System
If you have chosen to put your database files on a file system.
=> The default path that Oracle Universal Installer (OUI) will suggest is a subdirectory of the Oracle Base Directory.
=> You can choose to store your database files on a single file system, or on multiple file systems.
If you decide to go with a single file system, then you should choose a file system on a physical device that is dedicated to the database.  For best performance and reliability you should choose a RAID device, or you should choose a logical volume that is housed on more than one physical device and implement the stripe-and-mirror-everything (SAME) methodology.

If you decide to use more than one file system, then choose file systems on separate physical devices that are dedicated to the database.  Doing this allows you to distribute input-output operations and create separate control files on different physical devices for increased reliability.  This arrangement also allows you to fully implement the OFA guidelines.  To implement this method, you can choose the advanced database creation option.

=> If you are going to create a preconfigured database during the installation, then the file system or file systems that you choose, must have a minimum of 2GB of free disk space.  For a production database, you must estimate the disk space requirement depending on how the database is to be used.

=> For optimum performance, the file systems that you choose must be on physical devices that are used only by the database, no compromise on this one.

=> The oracle user must have write permissions to create the files in the path that you specify.

It is always good to create directories for the Oracle database or recovery files on separate file systems from the Oracle base directory.
=> determine the free disk space on each mounted file system
$ df –h
Examine the output to determine which are the best file-systems to use.

Database files: Choose either a single file system, or multiple files systems.
Recovery files: Choose a file system with at least 2.4 GB of free disk space

If you are going to be using one file system for all the different file types, then you must add the disk space requirements together for all of them, so that you can determine the total disk space required.

Make a note of the names of the mount point directories for the file systems that you identified.  Then you will need to create the recommended subdirectories in each of the mount point directories, and set the owner, group, and permissions on them.
Database file directory
$ mkdir /<mount_point>/oradata
$ chown oracle:oinstall /<mount_point>/oradata
$ chmod 775 /<mount_point>/oradata
We have now moved the database file directories away from the default file location which is $ORACLE_BASE/oradata

Recovery file directory (fast recovery area)
$ mkdir /<mount_point>/fast_recovery_area
$ chown oracle:oinstall /<mount_point>/fast_recovery_area
$ chmod 775 /<mount_point>/fast_recovery_area
We have now moved the recovery file directory away from the default of $ORACLE_BASE/fast_recovery_area.  Having the recovery file directory and the datafile directory on separate physical devices or disks, enables you to use the recovery area, if something has gone wrong with the database file storage area.

You can also use Oracle ASM for storage.

Franz Devantier,
Need a database health check?
devantierf@gmail.com

Classifieds

Saturday, August 3, 2013

Oracle Database Preinstallation – Part 11

Dear Readers,

My name is Franz Devantier, creator of this blog.  I am an Oracle Certified Professional (OCP DBA 11g) Security DBA.  I will be sharing with you the basic duties of an Oracle DBA, and also some of the undocumented, and not so well known tasks. 

I will make a deal with you:  If you refer me to a company that needs database support, from a few hours per week to full time, and I am able to sign a contract with them.
Then I will give you 10% of the monthly contract or deal price every month.  When the contract ends, and we re-sign the contract, I will again give you 10% of the monthly contract price.  This will go on until the company no longer employs or contracts me or my agents to look after their databases.
I can do this, because that 10% is my marketing budget.  When we re-sign the contract, in the future, it may depend on you giving the thumbs up again, and that is worth 10% of the monthly contract price, to be given to you as commission.

Oracle Database Preinstallation – Part 11
Identifying Required Software Directories
We must be able to identify or create the three required directory structures.  Oracle Base directory, Oracle Inventory Directory, and Oracle Home Directory.

It is important to make sure that the path for the Oracle Base and Oracle Home, use only ASCII characters.  This is because the installation owner names are used as part of some of the paths in these directory structures.  This ASCII character restriction applies to user names, file names, and directory names.  To comply with this requirement, you can use characters from the the following set only: "# % & ' () * + , - . / : ; < = > ? @ _ A-Z a-z 0-9
Remember that this restriction applies to Oracle 11.2
Further restrictions with regards to user and file naming rules from the Operating System, will also need to be adhered to.

Oracle Base Directory
The Oracle base directory is a top level directory, on which the Oracle installations are built.  The shorter this directory the better.  We also need to comply with Optimal Flexible Architecture (OFA), which recommends the following structure for the Oracle base directory:
/<mount point>/app/<software owner>
For example:
/u01/app/oracle
Or
/u02/app/grid

When you start a database instance using the server parameter file (spfile), with the ORACLE_BASE environment variable set, then the value of ORACLE_BASE is automatically stored in the spfile.  If you unset ORACLE_BASE, and restart the instance, then the database is able to use the value from the spfile, to find the oracle base directory.

If you have an existing ORACLE_BASE directory, then when you create a database using DBCA for example, it will be available to select during the database installation.  On the other hand if you don’t have an Oracle Base Directory, then you can create a new one in the list box, either by browsing for it, or typing it in.  By default the existing Oracle Base Directory will be stored in the list box.  Always best to define it before the time, and to make sure that it conforms to OFA standards.  Ie /u01/app/oracle

You can use the same Oracle Base Directory for multiple Oracle Installations.  You can also create separate Oracle Base Directories for different Oracle Software Installations.  If there are different Operating System users that are installing Oracle Software on the same system, then each of these Operating System users, must create a separate Oracle Base Directory.
For example:
/u01/app/oracle
/u01/app/orauser
/u01/app/grid

Oracle Inventory Directory
All the Oracle software installed on the system is reliant on the Oracle Inventory directory (oraInventory).  Once there is an Oracle Inventory path, the Oracle Universal Installer will continue to use that path or that Inventory.

When you install Oracle software on the system for the first time, then the path or location of Oracle Inventory is established from then onwards.  OUI tries to encourage you to use a OFA compliant path.  For example /u01/app would be the ideal path to give back to OUI.  Because then your oraInventory would be created as:
/u01/app/oraInventory
Which will go well with your Oracle base for example:
/u01/app/oracle
You see this is nicely laid out, easy to find, and does not get entangled in the ORACLE_BASE directory structure.

However if you have set the ORACLE_BASE during the OUI installation, then OUI will create the oracle inventory directory in the path ORACLE_BASE/oraInventory, which translates to /u01/app/oracle/oraInventory

If you have not created an OFA-compliant path, and you have not set ORACLE_BASE, then the Oracle Inventory directory is placed in the home directory of the user that is performing the oinstallation.
/home/oracle/oraInventory
OUI will create the directory, and set the correct owner, group, and permissions for it, you don’t need to create it.

Because all the Oracle software installations rely on the Oracle Inventory Directory, it is a point of failure, and so should be backed up regularly.  You should only delete this directory, once you have removed all Oracle products from the system.  The Oracle Inventory is not installed under the Oracle Base Directory, because there is only one Oracle inventory for all users.  Each user will have a separate Oracle Base directory.

Oracle Home Directory
This is where you install the Oracle software for a specific Oracle product.  You will need to install different Oracle products, as well as different releases of the same product, in different Home Directories.  When you run OUI, it will prompt you for the path to this directory, as well as a home name to identify it.

The directory that you specify, must be a subdirectory of the Oracle base directory.  For example:
ORACLE_BASE/product/11.1.0/dbhome_1
ORACLE_BASE/product/11.2.0/dbhome_1
ORACLE_BASE/product/11.2.0/grid

OUI will create the directory path that you specify, under the Oracle base directory.  OUI will also set the correct owner, group, and permissions to the directory structure.  So you don’t have to create this directory yourself.  You must not in fact specify an existing directory that has predefined permissions applied to it, as the Oracle Home Directory.  In a case like this you may experience installation failure due to file and group ownership permission errors.

Identifying or Creating an Oracle Base Directory
You must identify or create an Oracle Base Directory, before starting the installation.  You can create an Oracle Base Directory, even if other base directories already exist on the system.

Identifying an Existing Oracle Base Directory
You may find that the existing Oracle Base Directories, do not comply with the Optimal Flexible architecture (OFA).  Even so, if you can identify existing home directories, or Oracle Inventory directories, then you can usually identify the Oracle Base Directories.  It is not good practice to put the oraInventory directory under the Oracle Base directory for a new installation.

How to look for existing Oracle Home directories:
$ more /etc/oratab
If the oratab file exists, then it should contain code that looks something like:
*:/u01/app/oracle/product/11.2.0dbhome_1:N

These entries in the oratab file identify Oracle home directories.  The base directories usually end with the oracle username, so from the above example the base directory would probably be:
/u01/app/oracle

To install Oracle software, try to choose one of the directory paths that complies the most with the OFA.  You may find the Oracle inventory directory as well.
$ cat /u01/app/oraInventory/ContentsXML/inventory.xml

Before you use the newly found Oracle base directory, make sure that it is not on the same file system as the operating system, and that there is sufficient free disk space available.
If the Oracle base directory is to contain only the software files, then up to 4GB of free disk space is required.  If the Oracle base directory is to contain both software and database files (which would not do for a production system), then you would need up to 6GB of free space.

You will need to determine how much free space is available on the Oracle base directory.
$ df –h ORACLE_BASE_PATH
When you configure the Oracle users environment, then you will set the ORACLE_BASE environment variable with the oracle base directory that you have chosen.  If you were not able to find a suitable Oracle base directory, then you may need to create a new base directory.

Creating an Oracle Base Directory
Your first step is to identify a suitable file system with sufficient disk space on it.
Check all the mounted file systems, to see how much space is available:
$ df –h
You will examine the output to find a filesystem with sufficient space on it.  You can choose a local file system, a cluster file system, or a NFS file system on a certified NAS device.

Now you can make a note of the mount point name, for the file system that you identified.  You will now be able to create the Oracle base directory, and secify the owner, group and permissions on them.
$ mkdir –p /<mount_point>/app/<oracle_software_owner>
$ chown –R oracle:oinstall  /<mount_point>/app/<oracle_software_owner>
$ chmod –R 755 /<mount_point>/app/<oracle_software_owner>

Now you can set the ORACLE_BASE environment variable to point to the Oracle base directory that you have just created.

Franz Devantier,
Need a database health check?
devantierf@gmail.com

Classifieds

Friday, August 2, 2013

Oracle Database Preinstallation – Part 10

Dear Readers,

My name is Franz Devantier, creator of this blog.  I am an Oracle Certified Professional (OCP DBA 11g) Security DBA.  I will be sharing with you the basic duties of an Oracle DBA, and also some of the undocumented, and not so well known tasks. 

I will make a deal with you:  If you refer me to a company that needs database support, from a few hours per week to full time, and I am able to sign a contract with them.
Then I will give you 10% of the monthly contract or deal price every month.  When the contract ends, and we re-sign the contract, I will again give you 10% of the monthly contract price.  This will go on until the company no longer employs or contracts me or my agents to look after their databases.
I can do this, because that 10% is my marketing budget.  When we re-sign the contract, in the future, it may depend on you giving the thumbs up again, and that is worth 10% of the monthly contract price, to be given to you as commission.

Oracle Database Preinstallation – Part 10
Configuring Kernel Parameters for Linux
When you run Oracle Universal Installer (OUI), any kernel parameters that are not set to the minimal requirements, will be noted.  Although it is possible to run the “fixup script” to set the kernel parameters, and then continue with the installation, it is better practice to verify your kernel parameters, before you start the installation with OUI.  The “fixup script”, will be setting the kernel parameters to minimal values, where they were below the minimal values.  Oracle recommends that you should tune and optimize these kernel parameters, to get the most out of your oracle Installation.

Kernel parameters, minimal values
Parameter
Value
File
Semmsl
250
/proc/sys/kernel/sem
Semmns
32000
Semopm
100
Semmni
128
Shmall
2097152
/proc/sys/kernel/shmall
Shmmax
Minimum: 536870912
=> 32-bit Linux Systems
Maximum: A value that is 1 byte less than 4 GB, or 4294967295
Recommended: More than half the physical memory
=> 64-bit Linux Systems
Maximum: A value that is 1 byte less than the physical memory
Recommended: More than half the physical memory
/proc/sys/kernel/shmmax
Shmmni
4096
/proc/sys/kernel/shmmni
file-max
6815744
/proc/sys/fs/file-max
aio-max-nr
1048576
Note: This value limits concurrent outstanding requests and should be set to avoid I/O subsystem failures.
/proc/sys/fs/aio-max-nr
ip_local_port_range
Minimum: 9000
Maximum: 65500
Verifying UDP and TCP Kernel Parameters
/proc/sys/net/ipv4/ip_local_port_range
rmem_default
262144
/proc/sys/net/core/rmem_default
rmem_max
4194304
/proc/sys/net/core/rmem_max
wmem_default
262144
/proc/sys/net/core/wmem_default
wmem_max
1048576
/proc/sys/net/core/wmem_max

When you verify the parameters, keep in mind that the “fixup script”, does not change the value of any of the kernel parameters that are greater than the minimal values.

Displaying and Changing Kernel Parameter Values
The below command will display the semaphore kernel parameter and its values.
$ /sbin/sysctl –a |grep sem
kernel.semmsl = 250
kernel.semmns = 32000
kernel.semopm = 100
kernel.semni = 128

The below command will display the details of the shared memory segments.
$ /sbin/sysctl –a |grep shm
kernel.shmmax = 68719476736
kernel.shmall = 4294967296
kernel.shmmni = 4096

The below command will display the maximum number of file handles
$ /sbin/sysctl –a |file-max
fs.file-max = 98480

The Below command will display a range of port numbers
$  /sbin/sysctl -a | grep ip_local_port_range
net.ipv4.ip_local_port_range = 32768     61000

$ /sbin/sysctl -a | grep rmem_default
net.core.rmem_default = 229376

$ /sbin/sysctl -a | grep rmem_max
net.core.rmem_max = 131071

$ /sbin/sysctl -a | grep wmem_default
net.core.wmem_default = 229376

$ /sbin/sysctl -a | grep wmem_max
net.core.wmem_max = 131071

$ /sbin/sysctl -a | grep aio-max-nr
fs.aio-max-nr = 1048576

Now that you have gathered the information, you can compare it against the table of default values.  If any of the kernel parameters is different from the minimal value, then you can do the following.

Edit the /etc/sysctl.conf file, and you can either add lines that are missing or edit the values of the entries that are there.  For the semaphore parameters, you must specify all four values.  If any of the current values are larger than the minimum value, then you can leave it at the minimum.

Added these entries, in this case:
fs.aio-max-nr = 1048576
fs.file-max = 6815744
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048576

Because we have added the values to the /etc/sysctl.conf file, they will persist when we restart the operating system.  To change the current value of the kernel parameters:
$ /sbin/sysctl –p
Review the output to make sure that all the values are correct.  If not, then edit /etc/sysctl.conf again, then enter the /sbin/sysctl –p again, until you are happy with the output.

Then to further confirm, you can enter:
$ /sbin/sysctl -a |less

When you are satisfied with the results, and remember we have focussed on Oracle Linux on intel hardware here, then you can either restart the computer, or run the command sysctl –p to make the changes in the /etc/sysctl.conf file available in the active kernel memory.

Franz Devantier,
Need a database health check?
devantierf@gmail.com

Classifieds