Closed shundhammer closed 2 years ago
FTR: the Alternative Fix was already implemented in libsuseconnect. It will be reverted by https://github.com/SUSE/connect-ng/pull/124 once this PR is merged.
:heavy_check_mark: Public Jenkins job #361 successfully finished :heavy_check_mark: Created OBS submit request #960249
:heavy_check_mark: Internal Jenkins job #195 successfully finished :heavy_check_mark: Created IBS submit request #266990
Bugzilla
https://bugzilla.suse.com/show_bug.cgi?id=1196326
Trello
https://trello.com/c/YlPWQ3YP/
Problem
PR #1236 added a workaround for a long-standing problem on the aarch64 platform: An error Can't load libsuseconnect.so due to an error cannot allocate memory in static TLS block.
A well-known workaround in the aarch64 Linux world is to force-load the affected library with
LD_PRELOAD
. That is what that PR did.But since that is inherited by child processes, it also affects them, considerably adding to their memory footprint since now it force-links (!) libsuseconnect.so to every binary started that way, and YaST starts a lot of external binaries; for example for storage probing.
Fix
Don't use
LD_PRELOAD
; revert that first workaround.Alternative Fix
Use
LD_PRELOAD
, but sanitize it immediately after starting the YaST process (after libsuseconnect.so is already loaded), so child processes don't do that as well:Fetch the
LD_PRELOAD
environment variable, split it up into its components (it may contain several paths, just likeLD_CONFIG
orPATH
, remove the part with libsuseconnect, put it back together and write it to the process environment, so child processes inherit a sanitized version.Why not Use the Alternative Fix?
See https://bugzilla.suse.com/show_bug.cgi?id=1194996#c11:
What will this Break?
SLE products installation with registration on aarch64 in low-RAM setups.
What will this Fix?
SLE products installation on all other platforms in low-RAM setups.
It was never a problem with enough RAM or in non-SLE installations (because there is no libsuseconnect.so).