Re: [exim] exim4 needs CAP_SYS_RESOURCE?

Pàgina inicial
Delete this message
Reply to this message
Autor: Marc Schiffbauer
Data:  
A: exim-users
Assumpte: Re: [exim] exim4 needs CAP_SYS_RESOURCE?
* Michael Haardt schrieb am 15.09.04 um 11:25 Uhr:
>
>   if (rlp.rlim_cur < 1000)
>     {
>     rlp.rlim_cur = rlp.rlim_max = 1000;
>     (void)setrlimit(RLIMIT_NOFILE, &rlp);
>     }
>   #endif

>
> Does Apache start Exim with less than 1000 descriptors?


How could I test this?

I have no rlimits set in my /etc/security/limits.conf except
for one group of users and www-data (apache) is not member of
that group.


>
>   #ifdef RLIMIT_NPROC
>     #ifdef RLIM_INFINITY
>     rlp.rlim_cur = rlp.rlim_max = RLIM_INFINITY;
>     #else
>     rlp.rlim_cur = rlp.rlim_max = 1000;
>     #endif
>   (void)setrlimit(RLIMIT_NPROC, &rlp);
>   #endif

>
> This part does not check if the limit is already set to RLIM_INFINITY
> (or 1000 if not defined). May that cause the described problem?
>
> Does anybody vote against checking the error code of setrlimit and
> logging errors?


logging an error (or warning) and telling that this
might not matter perhaps is good for a user experiencing this thing
but I think exim should test what limits it has before setting
something... so that this error message will only be shown if
resources are really too restrictive


-Marc

--
+-O . . . o . . . O . . . o . . . O . . . ___ . . . O . . . o .-+
| Ein Service von Links2Linux.de:         /  o\   RPMs for SuSE   |
| --> PackMan! <-- naeheres unter        |   __|   and  others    |
| http://packman.links2linux.de/ . . . O  \__\  . . . O . . . O . |