Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

RE: process limit/su problem



su - root ?

Jo

-----Original Message-----
From: Tarmo Järvi [mailto:tarmoj@xxxxxxxxx]
Sent: Thursday, January 25, 2001 4:33 AM
To: zsh-users@xxxxxxxxxxxxxx
Subject: process limit/su problem


Hello dear list,

I have following lines in /etc/zshenv to prevent fork-bombing etc by
ordinary users :

if [ `id -gn` = `id -un` -a `id -u` -gt 14 ]
then
        ulimit -H -u 64 -c 65536 -f 2097152 -n 128
else
        ulimit -u 2048 -c 65536 -f 4194394 -n 1024
fi

Everything works nicely except 'su root' (by few selected "power users").
Usually my server is running about 100 processes owned by root. When I'm
logged in as, for example, tarmoj and do 'su root',  I get following errors:

/etc/zshenv: fork failed: resource temporarily unavailable [33]

So, obviously, the process limit for user is limiting the execution of
/etc/zshenv etc and thus (as root after 'su' )I have to manually set  higher
process limit and set other variables.

So, my question is, is there any other way to prevent this (otherthan ssh
root@localhost)?



Messages sorted by: Reverse Date, Date, Thread, Author