Update System Resources
NvSciIpc must open endpoint-related resources such as shared memory, message queues, and device node. When the number of endpoints increases, the number of resources to open also increases, and it can exceed the system resource limit, which leads to NvSciIpc failure at initialization.
- RLIMIT_NOFILE–maximum number of files to open
- RLIMIT_MSGQUEUE–maximum number bytes to be allocated for message queue
The resources can be increased in
/etc/security/limits.d/driveos-limits.conf
.
$cat /etc/security/limits.d/driveos-limits.conf
* hard nofile 131072
* soft nofile 131072
root hard nofile 131072
root soft nofile 131072
* hard msgqueue 134217728
* soft msgqueue 134217728
root hard msgqueue 134217728
root soft msgqueue 134217728
#Check your current resource limits using "ulimit -a" command then compare it to above settings.
#If your limits are lower than recommended values, you have to update them.
Existing sessions still have old limit values.
To apply new limits, reboot the system or use a new session (login).
/etc/security/limits.d/driveos-limits.conf
overrides the settings in
the /etc/security/limits.conf
during boot time.
Regarding msgqueue, NvSciIpc has one more tuning point in /etc/sysctl.conf.
$cat /etc/sysctl.conf
fs.mqueue.msg_max=256
fs.mqueue.queues_max=16384
#Check your current resource limits using "sysctl fs.mqueue.msg_max" and "sysctl fs.mqueue.queues_max" command, and compare it to upper setting.
#If your limits are lower than recommended values, you have to update them.
To apply new limits, reboot the system or execute the sudo sysctl -p
command.
The User Application Process Under systemd
systemd
is a system and service mamanger for Linux OS. NVIDIA
DRIVE? OS users can add custom applications or services using
NvSciIpc
to systemd
.
In this case, the /etc/security/limits.d/driveos-limits.conf file does not affect the
system resources setting of the systemd
service.
NVIDIA DRIVE OS Linux uses custom systemd
resource settings with the
/etc/systemd/systemd.conf.d/driveos-system.conf file.
[Manager]
DefaultLimitNOFILE=131072:131072
DefaultLimitMSGQUEUE=134217728:134217728
These settings are the minimum requirement of NvSciIpc
.
If the user's custom systemd
service has its own additional resource
requirements, these settings will increase.