Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nix-store no libgssapi_krb5.so.2 #86

Open
jra opened this issue Feb 6, 2024 · 2 comments
Open

nix-store no libgssapi_krb5.so.2 #86

jra opened this issue Feb 6, 2024 · 2 comments

Comments

@jra
Copy link

jra commented Feb 6, 2024

nix-portable-010
RHEL 7.9
Linux 3.10.0-1160.53.1.el7.x86_64

The first time I tried to run nix-portable, I got:

$ nix-portable nix-shell -p zsh
...
tar: /etc/group: bad record
tar: /etc/group: bad record
tar: /etc/group: bad record
/p/home/jraa/.nix-portable/store/cqvxiq4l98b7d1ra0sqj1p83cb8sk99z-nix-2.18.0/bin/nix-store: error while loading shared libraries: libgssapi_krb5.so.2: cannot open shared object file: No such file or directory

This is a large HPC system with many users. file /etc/groups says ... with very long lines. Not sure if that is relevant?

Subsequent attempts to run give:

$ nix-portable nix-shell -p zsh
Fatal error: nix is unable to build packages

Is there something I can do to fix this?

@jra
Copy link
Author

jra commented Feb 6, 2024

some debug stuff...

$ export NP_DEBUG=1
$ export NP_RUNTIME=bwrap
$ nix-portable nix-shell -p zsh
installing files
figuring out ssl certs
SSL_CERT_FILE not defined. trying to find certs automatically
found /etc/ssl/certs/ca-bundle.crt with real path /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem
figuring out which runtime to use
bwrap executable: /p/home/jraa/.nix-portable/bin/bwrap
proot executable: /p/home/jraa/.nix-portable/bin/proot
runtime selected via NP_RUNTIME: bwrap
base command will be: /p/home/jraa/.nix-portable/bin/bwrap --bind /p/home/jraa/.nix-portable/emptyroot / --dev-bind /dev /dev --bind /p/home/jraa/.nix-portable/ /nix --bind /sys /sys --bind /p/work1 /incoming --bind /archive /archive --bind /var /var --bind /p/app /app --bind /media /media --bind /lost+found /lost+found --bind /etc /etc --bind /Quarantine /Quarantine --bind /usr/sbin /sbin --bind /p/home/sitecfg/acct /acct --bind /10d.out /10d.out --bind /usr/lib /lib --bind /p /p --bind /usr /usr --bind /core.81279 /core.81279 --bind /p/home/sitecfg/acct /acct.old --bind /localhome /localhome --bind /proc /proc --bind /tmp /tmp --bind /ELT /ELT --bind /core.93066 /core.93066 --bind /tmpmnt /tmpmnt --bind /scripts /scripts --bind /mnt /mnt --bind /srv /srv --bind /home /home --bind /run /run --bind /usr/lib64 /lib64 --bind /boot /boot --bind /pbs_server /pbs_server --bind /.readahead /.readahead --bind /opt /opt --bind /root /root --bind /usr/bin /bin --bind /core.27897 /core.27897 --bind /etc/host.conf /etc/host.conf --bind /etc/hosts /etc/hosts --bind /etc/hosts.equiv /etc/hosts.equiv --bind /etc/networks /etc/networks --bind /etc/passwd /etc/passwd --bind /etc/group /etc/group --bind /etc/nsswitch.conf /etc/nsswitch.conf --bind /etc/resolv.conf /etc/resolv.conf --bind /usr/share/zoneinfo/UTC /usr/share/zoneinfo/UTC --bind /p/home/jraa /p/home/jraa --bind /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem /p/home/jraa/.nix-portable/ca-bundle.crt
cat: can't open '/p/home/jraa/.nix-portable/conf/last_runtime': No such file or directory
Testing if nix can build stuff without sandbox
/p/home/jraa/.nix-portable/store/cqvxiq4l98b7d1ra0sqj1p83cb8sk99z-nix-2.18.0/bin/nix-build: error while loading shared libraries: libgssapi_krb5.so.2: cannot open shared object file: No such file or directory
Fatal error: nix is unable to build packages

@jra
Copy link
Author

jra commented Feb 6, 2024

With some sym link and LD_LIBRARY_PATH hacking I was able to get as far as:

$ NP_DEBUG=1 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/krb5/lib:$HOME/pks/rpms/keyutils-libs/lib64:$HOME/.local/lib nix-portable nix-shell -p zsh
installing files
figuring out ssl certs
SSL_CERT_FILE not defined. trying to find certs automatically
found /etc/ssl/certs/ca-bundle.crt with real path /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem
figuring out which runtime to use
bwrap executable: /p/home/jraa/.nix-portable/bin/bwrap
proot executable: /p/home/jraa/.nix-portable/bin/proot
bwrap seems to work on this system -> will use bwrap
base command will be: /p/home/jraa/.nix-portable/bin/bwrap --bind /p/home/jraa/.nix-portable/emptyroot / --dev-bind /dev /dev --bind /p/home/jraa/.nix-portable/ /nix --bind /sys /sys --bind /p/work1 /incoming --bind /archive /archive --bind /var /var --bind /p/app /app --bind /media /media --bind /lost+found /lost+found --bind /etc /etc --bind /Quarantine /Quarantine --bind /usr/sbin /sbin --bind /p/home/sitecfg/acct /acct --bind /10d.out /10d.out --bind /usr/lib /lib --bind /p /p --bind /usr /usr --bind /core.81279 /core.81279 --bind /p/home/sitecfg/acct /acct.old --bind /localhome /localhome --bind /proc /proc --bind /tmp /tmp --bind /ELT /ELT --bind /core.93066 /core.93066 --bind /tmpmnt /tmpmnt --bind /scripts /scripts --bind /mnt /mnt --bind /srv /srv --bind /home /home --bind /run /run --bind /usr/lib64 /lib64 --bind /boot /boot --bind /pbs_server /pbs_server --bind /.readahead /.readahead --bind /opt /opt --bind /root /root --bind /usr/bin /bin --bind /core.27897 /core.27897 --bind /etc/host.conf /etc/host.conf --bind /etc/hosts /etc/hosts --bind /etc/hosts.equiv /etc/hosts.equiv --bind /etc/networks /etc/networks --bind /etc/passwd /etc/passwd --bind /etc/group /etc/group --bind /etc/nsswitch.conf /etc/nsswitch.conf --bind /etc/resolv.conf /etc/resolv.conf --bind /usr/share/zoneinfo/UTC /usr/share/zoneinfo/UTC --bind /p/home/jraa /p/home/jraa --bind /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem /p/home/jraa/.nix-portable/ca-bundle.crt
cat: can't open '/p/home/jraa/.nix-portable/conf/last_runtime': No such file or directory
Testing if nix can build stuff without sandbox
/p/home/jraa/.nix-portable/store/cqvxiq4l98b7d1ra0sqj1p83cb8sk99z-nix-2.18.0/bin/nix-build: /p/app/gnu/11.2.0/lib64/libstdc++.so.6: version `GLIBCXX_3.4.30' not found (required by /nix/store/cqvxiq4l98b7d1ra0sqj1p83cb8sk99z-nix-2.18.0/lib/libnixstore.so)
/p/home/jraa/.nix-portable/store/cqvxiq4l98b7d1ra0sqj1p83cb8sk99z-nix-2.18.0/bin/nix-build: /p/app/gnu/11.2.0/lib64/libstdc++.so.6: version `GLIBCXX_3.4.30' not found (required by /nix/store/cqvxiq4l98b7d1ra0sqj1p83cb8sk99z-nix-2.18.0/lib/libnixutil.so)
/p/home/jraa/.nix-portable/store/cqvxiq4l98b7d1ra0sqj1p83cb8sk99z-nix-2.18.0/bin/nix-build: /p/app/gnu/11.2.0/lib64/libstdc++.so.6: version `GLIBCXX_3.4.30' not found (required by /nix/store/428ig60cc3n8q8kg0cmpws07a12ksrqx-aws-sdk-cpp-1.11.37/lib/libaws-cpp-sdk-transfer.so)
/p/home/jraa/.nix-portable/store/cqvxiq4l98b7d1ra0sqj1p83cb8sk99z-nix-2.18.0/bin/nix-build: /p/app/gnu/11.2.0/lib64/libstdc++.so.6: version `GLIBCXX_3.4.30' not found (required by /nix/store/428ig60cc3n8q8kg0cmpws07a12ksrqx-aws-sdk-cpp-1.11.37/lib/libaws-cpp-sdk-core.so)
/p/home/jraa/.nix-portable/store/cqvxiq4l98b7d1ra0sqj1p83cb8sk99z-nix-2.18.0/bin/nix-build: /p/app/gnu/11.2.0/lib64/libstdc++.so.6: version `GLIBCXX_3.4.30' not found (required by /nix/store/v4r4x88y91nc72sjbi9791hqsziiz4ns-aws-crt-cpp-0.19.8/lib/libaws-crt-cpp.so)
Fatal error: nix is unable to build packages

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant