ShmPagesNoTouch

The ShmPagesNoTouch connection attribute prevents TimesTen from "touching pages" when creating a shared segment. In the database context, touching pages means a query or operation accesses or modifies specific data pages in memory.

By default, TimesTen pre-touches all pages in the shared memory segment during database initialization. In this context, touching a page means the database reads and writes to it, so the operating system immediately assigns physical memory to it. This process commits the entire memory footprint at startup and ensures the database has dedicated RAM before it starts processing requests. It may increase initialization time for large databases, but it does not increase total memory usage; it validates and commits memory earlier rather than during runtime.

Linux allocates physical memory only when a process first accesses a page. If you turn off page touching, TimesTen allocates memory on demand when it references those pages, rather than committing memory during initialization. This allocation reduces startup time and lowers immediate memory usage, but it also delays memory validation until the database is operating under load.

The ShmPagesNoTouch connection attribute turns off the pre-touch phase and enables demand-based allocation. This configuration reduces the chance of running out of memory during startup, but it increases the risk of runtime failures if the system runs out of physical memory. In that situation, the Linux Out-of-Memory (OOM) killer may terminate the TimesTen process, potentially invalidating the database. Because of this risk, configure ShmPagesNoTouch connection attribute to 1 only when the system can guarantee sufficient free memory throughout the database's lifecycle.

Before changing the value of the attribute to 1 to turn off page touching when you are experiencing an issue with the OOM Killer, Oracle recommends trying these steps first:

  1. Configure the Linux kernel parameters for shared memory settings. See Configure shmmax and shmall in Oracle TimesTen In-Memory Database Installation, Migration, and Upgrade Guide.
  2. Reduce OOM priority for the processes connecting to the database, such as timestend, timestensubd, timestenrepd, and timestenorad. See How to Configure the Linux Out-of-Memory Killer.

Required Privilege

Only the instance administrator can change the value of this attribute.

Setting

Set ShmPagesNoTouch as follows:

Where to set the attribute How the attribute is represented Setting

C or Java programs or UNIX and Linux systems odbc.ini file in TimesTen Classic

ShmPagesNoTouch

0 (default) - Allows TimesTen to touch all pages in the shared memory segment when loading the database.

1 - ​Prevents TimesTen from touching all pages in the shared memory segment when loading the database. Do not set 1 on non- Linux systems.

Windows ODBC Data Source Administrator

Not applicable