Nп/п : 51 из 100
 От   : Kalevi Kolttonen                    2:5075/128        29 авг 23 15:24:08
 К    : Kenny McCormack                                       29 авг 23 18:26:03
 Тема : Re: getrlimit RLMIT_NPROC
----------------------------------------------------------------------------------
                                                                                 
@MSGID: 1@dont-email.me> ae7068c9
@REPLY: 1@news.xmission.com>
0477845f
@REPLYADDR Kalevi Kolttonen <kalevi@kolttonen.fi>
@REPLYTO 2:5075/128 Kalevi Kolttonen
@CHRS: CP866 2
@RFC: 1 0
@RFC-Message-ID: 1@dont-email.me>
@RFC-References:
1@news.xmission.com>
@TZUTC: -0000
@PID: tin/2.6.2-20221225 ("Pittyvaich")
(Linux/6.4.12-200.fc38.x86_64 (x86_64))
@TID: FIDOGATE-5.12-ge4e8b94
Kenny McCormack <gazelle@shell.xmission.com> wrote:
> Neither of these results seem reasonable or tied to anything.

On my Fedora 38 amd64 "uname -a" shows e.g.

 6.4.12-200.fc38.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Aug 23 17:46:49 UTC
2023 x86_64 GNU/Linux

and the result of running your program is:

Result: 0
cur = 60988, max = 60988
RLIM_INFINITY = -1

> What is going on?

You used "%lu" and that is correct based on the Linux
headers. On my Fedora 38 we have these:

struct rlimit {
        __kernel_ulong_t        rlim_cur;
        __kernel_ulong_t        rlim_max;
};

#define RLIM64_INFINITY         (~0ULL)

struct rlimit64 {
        __u64 rlim_cur;
        __u64 rlim_max;
};


Using grep, I was unable to find where 60988 is set
on my Fedora 38. So my best guess is that this value 
has been set when compiling the kernel.

Have you tried using a recursive grep invocation 
to find the values you mentioned?

br,
KK
--- tin/2.6.2-20221225 ("Pittyvaich") (Linux/6.4.12-200.fc38.x86_64 (x86_64))
 * Origin: A noiseless patient Spider (2:5075/128)
SEEN-BY: 5001/100 5005/49 5010/352 5015/255 5019/40
5020/715 848 1042 4441
SEEN-BY: 5020/12000 5030/49 1081 5075/128
@PATH: 5075/128 5020/1042 4441



   GoldED+ VK   │                                                 │   09:55:30    
                                                                                
В этой области больше нет сообщений.

Остаться здесь
Перейти к списку сообщений
Перейти к списку эх