> error: %prein(selinux-policy-targeted-3.13.1-157.fc23.noarch)
scriptlet failed, exit status 126
> Error in PREIN scriptlet in rpm package selinux-policy-targeted
> How can I diagnose this? Where can I dig out the exact reason why the scriptlets are
Once you know a specific package that fails like that, you could query its
scriptlets section and try to reproduce manually:
rpm -q --scripts selinux-policy-targeted
At the top find the %prein section. It doesn't do much, but it may run some
Thanks a lot for the hint. So I tried looking at the very first package that had any
failure at all (albeit nonfatal), during the initial filesystem installation. That was
glibc. :-( It was a POSTIN failure.
"rpm -q --scripts glibc" tells me that "postinstall program" is set to
/usr/sbin/glibc_post_upgrade.x86_64. This binary is both in the installation environment
and in the sysimage (even twice, perhaps hardlinked, in /sbin and /usr/sbin).
When I chroot into the sysimage, I can run the glibc_post_upgrade.x86_64 binary just fine
and its exit code is 0. Yet upon glibc (re)installation, I'm getting that non-fatal
error message saying that its exit code was 126.
So the question is why glibc_post_upgrade.x86_64 can't be run by/from rpm. Does rpm
try to execute the postinstall oneliner using a shell that could be missing? Executing
simply "sh" in the sysimage chroot works fine though...
Could someone please point me to the sources of rpm/dnf/whatever where the
"postinstall program" command gets executed? It seems that I can't reproduce
the failure manually. And it's probably not worth looking into all the subsequent
failures until I know more about the very first one.