Bug 1227117 - systemd-sysctl[189]: Couldn't write '4194304' to 'kernel/pid_max': Invalid argument
Summary: systemd-sysctl[189]: Couldn't write '4194304' to 'kernel/pid_max': Invalid ar...
Status: NEW
Alias: None
Product: openSUSE Tumbleweed
Classification: openSUSE
Component: Basesystem (show other bugs)
Version: Current
Hardware: armv7 Other
: P5 - None : Normal (vote)
Target Milestone: ---
Assignee: Michal Koutný
QA Contact: E-mail List
URL: https://openqa.opensuse.org/tests/430...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-06-27 08:02 UTC by Guillaume GARDET
Modified: 2024-06-27 08:48 UTC (History)
2 users (show)

See Also:
Found By: openQA
Services Priority:
Business Priority:
Blocker: Yes
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Guillaume GARDET 2024-06-27 08:02:23 UTC
## Observation

openQA test in scenario opensuse-Tumbleweed-JeOS-for-AArch64-arm-jeos@aarch32-HD20G fails in
[journal_check](https://openqa.opensuse.org/tests/4302790/modules/journal_check/steps/11)

On armv7 (32-bit arm) we have the following problem since snapshot 20240625 (20240624 was fine):
**********
systemd-sysctl[189]: Couldn't write '4194304' to 'kernel/pid_max': Invalid argument
**********


## Test suite description
Maintainer: fvogt, mnowak

Start JeOS from the HDD image, configure it using the firstboot wizard and then run basic tests. console=tty0 added as needed for aarch64.


## Reproducible

Fails since (at least) Build [20240625](https://openqa.opensuse.org/tests/4301144)


## Expected result

Last good: [20240624](https://openqa.opensuse.org/tests/4298579) (or more recent)


## Further details

Always latest result in this scenario: [latest](https://openqa.opensuse.org/tests/latest?arch=arm&distri=opensuse&flavor=JeOS-for-AArch64&machine=aarch32-HD20G&test=jeos&version=Tumbleweed)
Comment 2 Michal Hocko 2024-06-27 08:23:19 UTC
/*
 * This controls the default maximum pid allocated to a process
 */
#define PID_MAX_DEFAULT (IS_ENABLED(CONFIG_BASE_SMALL) ? 0x1000 : 0x8000)

/*
 * A maximum of 4 million PIDs should be enough for a while.
 * [NOTE: PID/TIDs are limited to 2^30 ~= 1 billion, see FUTEX_TID_MASK.]
 */ 
#define PID_MAX_LIMIT (IS_ENABLED(CONFIG_BASE_SMALL) ? PAGE_SIZE * 8 : \
        (sizeof(long) > 4 ? 4 * 1024 * 1024 : PID_MAX_DEFAULT))

So on 32b this is 32k

Michal could you take a look please?
Comment 3 Michal Koutný 2024-06-27 08:35:51 UTC
32b, I didn't thought of them.
The simplest seems to

    -kernel.pid_max = 4194304
    +-kernel.pid_max = 4194304

So that write failures won't fail whole sysctl invocation. That should satisfy all cases.
Comment 4 Michal Koutný 2024-06-27 08:48:08 UTC
This should fix it
https://github.com/openSUSE/aaa_base/pull/156