Description of problem: Installing this package fails on Fedora/s390x on Rawhide: Running scriptlet: java-1.8.0-openjdk-headless-1:1.8.0.131-1.b12.fc27.s 1/1 error: lua script failed: [string "%pretrans(java-1.8.0-openjdk-headless-1:1.8.0.131-1.b12.fc27.s390x)"]:27: attempt to concatenate a nil value (field 'path') Error in PRETRANS scriptlet in rpm package java-1.8.0-openjdk-headless Error in PRETRANS scriptlet in rpm package java-1.8.0-openjdk-headless ... Verifying : java-1.8.0-openjdk-1:1.8.0.131-1.b12.fc27.s390x 28/132 java-1.8.0-openjdk-headless-1:1.8.0.131-1.b12.fc27.s390x was supposed to be installed but is not! ... Failed: java-1.8.0-openjdk-headless.s390x 1:1.8.0.131-1.b12.fc27 Version-Release number of selected component (if applicable): java-1.8.0-openjdk-headless.s390x 1:1.8.0.131-1.b12.fc27 How reproducible: At least once. Steps to Reproduce: 1. Just install the package.
Hi! AS this is not replicable on other arches, I will need an HW box.
I sent details of an s390x server by private email.
(In reply to Richard W.M. Jones from comment #2) > I sent details of an s390x server by private email. I run various combinations: 698 wget https://kojipkgs.fedoraproject.org//packages/java-1.8.0-openjdk/1.8.0.131/1.b12.fc27/s390x/java-1.8.0-openjdk-headless-1.8.0.131-1.b12.fc27.s390x.rpm 699 sudo dnf install java-1.8.0-openjdk-headless-1.8.0.131-1.b12.fc27.s390x.rpm 700 sudo dnf remove java-headless 701 rm -rf /usr/lib/jvm 702 dnf install java-headless 703 dnf install --nogpgcheck java-headless 704 sudo dnf install java-1.8.0-openjdk-headless-1.8.0.131-1.b12.fc27.s390x.rpm 705 sudo dnf remove java-headless 706 ll /usr/lib/jvm 707 ll /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.131-1.b12.fc27.s390x/jre/lib/security/cacerts 708 rm -rf /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.131-1.b12.fc27.s390x/ 709 dnf remove copy-jdk-configs 710 dnf install --nogpgcheck java-headless 711 dnf remove copy-jdk-configs 712 ll /usr/lib/jvm 713 sudo dnf install java-1.8.0-openjdk-headless-1.8.0.131-1.b12.fc27.s390x.rpm 714 sudo dnf install java-1.8.0-openjdk-headless-1.8.0.131-1.b12.fc27.s390x.rpm copy-jdk-configs 715 wget https://kojipkgs.fedoraproject.org//packages/copy-jdk-configs/2.2/2.fc26/noarch/copy-jdk-configs-2.2-2.fc26.noarch.rpm 716 sudo dnf install java-1.8.0-openjdk-headless-1.8.0.131-1.b12.fc27.s390x.rpm copy-jdk-configs-2.2-2.fc26.noarch.rpm 717 dnf remove copy-jdk-configs 718 sudo dnf install java-1.8.0-openjdk-headless copy-jdk-configs-2.2-2.fc26.noarch.rpm 719 sudo dnf install --nogpgcheck java-1.8.0-openjdk-headless copy-jdk-configs-2.2-2.fc26.noarch.rpm 720 sudo dnf install java-1.8.0-openjdk-headless-1.8.0.131-1.b12.fc27.s390x.rpm 721 dnf remove copy-jdk-configs and never hit the issue:(
I don't know - I don't have any more information that what I copied and pasted from the error message. Perhaps this is a problem in the %pretrans from the pre-upgraded package? In any case I had a look at the script itself, and it does contain: package.path = package.path .. ";" .. SOURCE1 I suppose the error means that package.path was not set. Apparently package.path is a built in variable in Lua itself which is used to search for Lua packages.
Yes, I read the same. Could there be misconfiguration?
Please feel free to reopen if you hit it agian
Hi, We now reproduced current bug several times on oVirt CI [1][2][3]. [3] was pushed with a patch [4] that passes to dnf '--rpmverbosity=debug', but it sadly didn't help me understand why it fails, and I do not know how to further debug this. Can you please have a look? Do you want a new bug for this, or reopen current? Thanks, [1] https://jenkins.ovirt.org/job/otopi_master_check-patch-fcraw-x86_64/38/ [2] https://jenkins.ovirt.org/job/otopi_master_check-patch-fcraw-x86_64/40/consoleFull [3] https://jenkins.ovirt.org/job/otopi_master_check-patch-fcraw-x86_64/41/consoleFull [4] https://gerrit.ovirt.org/92298
Having read again the lua code in the spec file, I now suspect this is a bug in rpm (or lua?), so adding Panu.
Erm. You've no business messing with the configuration of rpm's built-in Lua, such as its paths. From rpm perspective, the relevant bug here is that you can. For now, I'll just ask nicely that you stop fiddling with package.path, in the future rpm will prevent this one way or the other.
Hi, I am just the user here :-)) Thanks for replying! Seems to me like the lua code doing this was written after consulting rpm maintainers, perhaps it should be reconsidered or some other solution provided. https://src.fedoraproject.org/rpms/java-1.8.0-openjdk/c/8aabfb4c https://bugzilla.redhat.com/show_bug.cgi?id=1038092 https://bugzilla.redhat.com/show_bug.cgi?id=1290388
I will be most happy to drop the pretrans and post scriplets fixing the 1038092 and 1290388. All this was added with request on multiple installable, parallel, JDKS (as Oracle had this). However that would require severe support from rpm and/or yum/dnf.
Also noting that the failure on oVirt CI seems to have been fixed, likely by a 'dnf update' or something similar, which perhaps included updates to rpm, lua, java*, or whatever other relevant stuff, no idea. So personally I can't reproduce anymore, feel free to ignore. It still might be nice to find a better solution than fiddling with lua internals in the java spec file, so keeping needinfo.
For the record - this now happened again: https://jenkins.ovirt.org/job/otopi_master_build-artifacts-fc28-x86_64/27/ https://jenkins.ovirt.org/job/otopi_master_build-artifacts-fc28-x86_64/27/artifact/exported-artifacts/mock_logs/script/stdout_stderr.log Search above for e.g. "java-1.8.0-openjdk-headless". Snippet follows: Running transaction Running scriptlet: java-1.8.0-openjdk-headless-1:1.8.0.181.b15-6.fc28.x 1/1 error: lua script failed: [string "%pretrans(java-1.8.0-openjdk-headless-1:1.8.0.181.b15-6.fc28.x86_64)"]:27: attempt to concatenate a nil value (field 'path') Preparing : 1/1 Installing : plexus-utils-3.0.24-5.fc28.noarch 1/162 error: java-1.8.0-openjdk-headless-1:1.8.0.181.b15-6.fc28.x86_64: install skipped Setting needinfo again on Jiri, hoping to get this ignited again. Jiri - if you suspect this is an infra problem on our (oVirt CI) side, please suggest how to further debug/fix this. Otherwise, please work with rpm maintainers to either fix the failing code so that it does not fail (does not seem so hard, I can try doing this myself, but no idea how to trigger the bug/verify the patch), or replace it altogether with something more robust (in the eyes of the rpm maintainers, at least). I do not think the current situation is so healthy, even if it happens quite seldom. Thanks!
I'm unabel to guess what you are doing. It is like reading from crystal ball:(