J'ai ce qui suit dans /etc/security/limits.conf (J'ai spécifié root séparément car * ne l'inclura pas).
user2 - core unlimited
\* - core 0
root - core 0
\* - rss 512000
root - rss 512000
\* - nproc 100
root - nproc 100
\* - maxlogins 1
root - maxlogins 1
Je lance un programme en tant qu'utilisateur2 (./programname) mais /proc/3498/limits indique que les cœurs sont désactivés :
Limit Soft Limit Hard Limit Units
Max cpu time unlimited unlimited seconds
Max file size unlimited unlimited bytes
Max data size unlimited unlimited bytes
Max stack size 8388608 unlimited bytes
Max core file size 0 0 bytes
Max resident set 524288000 524288000 bytes
Max processes 100 100 processes
Max open files 1024 1024 files
Max locked memory 65536 65536 bytes
Max address space unlimited unlimited bytes
Max file locks unlimited unlimited locks
Max pending signals 14001 14001 signals
Max msgqueue size 819200 819200 bytes
Max nice priority 0 0
Max realtime priority 0 0
Max realtime timeout unlimited unlimited us
Les deux ulimit -Sa et ulimit -Ha indiquent que les cœurs sont désactivés :
core file size (blocks, -c) 0
data seg size (kbytes, -d) unlimited
scheduling priority (-e) 0
file size (blocks, -f) unlimited
pending signals (-i) 14001
max locked memory (kbytes, -l) 64
max memory size (kbytes, -m) 512000
open files (-n) 1024
pipe size (512 bytes, -p) 8
POSIX message queues (bytes, -q) 819200
real-time priority (-r) 0
stack size (kbytes, -s) unlimited
cpu time (seconds, -t) unlimited
max user processes (-u) 100
virtual memory (kbytes, -v) unlimited
file locks (-x) unlimited
Pourquoi les cœurs sont-ils désactivés ?