[SERVER-18763] Use get_mempolicy() or /proc/zoneinfo instead of /sys/devices/system/node/node1 to determine if NUMA is present Created: 01/Jun/15  Updated: 10/May/22

Status: Backlog
Project: Core Server
Component/s: Admin
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Kevin Pulo Assignee: DO NOT USE - Backlog - Platform Team
Resolution: Unresolved Votes: 1
Labels: move-sa, platforms-re-triaged
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to SERVER-10623 Mongod fails to start as unprivileged... Closed
related to SERVER-12464 Mongod fails to start as unprivileged... Closed
is related to SERVER-24133 Memory policy update from the mongod ... Closed
Participants:

 Description   

When the NUMA startup warning tries to determine if the host has more than 1 NUMA node, it looks for the existence of /sys/devices/system/node/node1. However, this is needlessly fragile because /sys might

  1. not be mounted,
  2. be mounted elsewhere,
  3. be missing certain hardware info (eg. NUMA nodes), or
  4. have restricted ownership or permissions (or be subject to other MAC restrictions like SELinux or AppArmor).

Better approaches to determine the number of NUMA nodes are to either use the get_mempolicy() Linux syscall, or as a fallback, look for a line starting with "Node 1" in /proc/zoneinfo.



 Comments   
Comment by Steven Vannelli [ 10/May/22 ]

Moving this ticket to the Backlog and removing the "Backlog" fixVersion as per our latest policy for using fixVersions.

Generated at Thu Feb 08 03:48:40 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.