I have setup /etc/security/limits.conf to limit all human users to just be able to run 50 process to help prevent fork bombs.
@users hard nproc 50
When testing this works great:
){ :|:& };:
I now see -bash: fork: Resource temporarily unavailable
same thing with perl
perl -e "while(1) {fork(); }"
the problem is I need to get alerts if these limits are reached.
I have search and can not find any way to get notified. I dont see any entries being logged to syslog either.
Any thoughts?
Thanks!