Various DB2 failures may occur on Linux with Address Space Layout Randomization (ASLR)
Some of the behaviors seen include the following:
For the db2pd command, it will print the following message:
Exceeded re-exec max count trying to attach to the database manager. This is likely due to ASLR currently being enabled on this system. Please retry the db2pd command.
For the db2egcf process, used for HA monitoring, the db2egcf may incorrectly determine the instance is down and initiate a failover.
For the db2vend process, backup and log archive methods might fail with an error indicating a child process could not be started:
SQL2043N Unable to start a child process or thread.
Diagnosing The Problem
FUNCTION: DB2 UDB, SQO Memory Management, sqlocshr, probe:180
MESSAGE : ZRC=0x850F0005=-2062614523=SQLO_NOSEG
"No Storage Available for allocation"
DIA8305C Memory allocation failure occurred.
CALLED : OS, -, shmat OSERR: EINVAL (22)
Resolving The Problem
Run "sysctl -w kernel.randomize_va_space=0" as root.
2) Disable ASLR immediately and on all subsequent reboots:
Add the following line to /etc/sysctl.conf:
and then run "sysctl -p" as root to make the change take effect immediately.
Note that you may find more information about sysctl -p at: http://pic.dhe.ibm.com/infocenter/db2luw/v9r7/topic/com.ibm.db2.luw.qb.server.doc/doc/t0008238.html
For further discussion on this topic, visit this developerWorks forum thread:
Related informationTable 2. Configuring other Linux kernel parameters
More support for:
DB2 for Linux, UNIX and Windows
Component: Operating System / Hardware - Other OS/Hardware
Software version: 9.5, 9.7, 10.1, 10.5, 11.1, 11.5
Operating system(s): Linux
Reference #: 1365583
Modified date: 19 July 2019