The Problem
On Oracle database 12.2.0.1 version, cpu_count is not correct: OS has 128 CPU in total, however CPU_COUNT is only 104.
SQL> show parameter cpu NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ cpu_count integer 104 <<<<<<<<<<<< 104 from database
$ lscpu Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Byte Order: Little Endian CPU(s): 128 <<<<<<<<<<<< 128 on OS
Alert log shows:
2017-12-14T18:01:48.697520+08:00 Domain name: sys <============== 2017-12-14T18:01:48.697583+08:00 Per process system memlock (soft) limit = 909G <....> 2017-12-14T18:01:49.557071+08:00 LICENSE_MAX_SESSION = 0 LICENSE_SESSIONS_WARNING = 0 Initial number of CPU is 104 <============== initial number of CPU is 104 Number of processor cores in the system is 64 Number of processor sockets in the system is 4
The Solution
cgroups is configured and limited the total CPU oracle can be using.
1. alert log shows that a domain sys is being used:
2017-12-14T18:01:48.697520+08:00 Domain name: sys <============== 2017-12-14T18:01:48.697583+08:00 Per process system memlock (soft) limit = 909G ....
2. Use "cgsnapshot -s" to check the cgroups configuration, and observed that sys group only gets 104 CPU allocated
# cgsnapshot -s > /tmp/cg.conf
# cat /tmp/cg.conf # Configuration file generated by cgsnapshot mount { cpuset = /cgroup/cpuset; memory = /cgroup/cpuset; } .... group sys { <===================== group: sys cpuset { cpuset.memory_spread_slab="0"; cpuset.memory_spread_page="0"; cpuset.memory_migrate="0"; cpuset.sched_relax_domain_level="-1"; cpuset.sched_load_balance="1"; cpuset.mem_hardwall="0"; cpuset.mem_exclusive="0"; cpuset.cpu_exclusive="0"; cpuset.mems="0-3"; cpuset.cpus="0-25,32-57,64-89,96-121"; <============== only allocated 104 CPU to this group }
The solution here is to remove CGROUPS configuration to have all CPU allocated to Oracle.