[Novalug] chroot ldconfig

Jason Kohles jkohles@palantir.com
Fri Nov 22 17:24:54 EST 2013


-r tells ldconfig to treat /srv/chroot/test/ as though it were /, so it's
actually trying to write the new cache to
/srv/chroot/test/srv/chroot/test/etc/ld.so.cache~

You want:  ldconfig -r /srv/chroot/test/ -C /etc/ld.so.cache -f
/etc/ld.so.conf


-- 
Jason Kohles
Palantir Technologies  | IT Site Engineer
jkohles@palantir.com   | 703-957-5784





On 11/22/13, 5:18 PM, "shawn wilson" <ag4ve.us@gmail.com> wrote:

>I'm trying to setup an ld.so.cache for a chroot. I'm thinking there
>must be a step to create an initial cache file before populating it or
>something?
>
>vm-debian-64-v72 /etc/schroot # ls -l /srv/chroot/test/etc/ld.so.c*
>-rw-r--r-- 1 root root    0 Nov 22 17:07 /srv/chroot/test/etc/ld.so.cache
>-rw-r--r-- 1 root root    0 Nov 22 17:08 /srv/chroot/test/etc/ld.so.cache~
>-rw-r--r-- 1 root root   34 Oct 14 10:34 /srv/chroot/test/etc/ld.so.conf
>
>/srv/chroot/test/etc/ld.so.conf.d:
>total 8
>-rw-r--r-- 1 root root 44 Dec 30  2012 libc.conf
>-rw-r--r-- 1 root root 68 Dec 30  2012 x86_64-linux-gnu.conf
>vm-debian-64-v72 /etc/schroot # ldconfig -r /srv/chroot/test/ -C
>/srv/chroot/test/etc/ld.so.cache -f /etc/ld.so.conf
>ldconfig: Can't create temporary cache file
>/srv/chroot/test/etc/ld.so.cache~: No such file or directory
>vm-debian-64-v72 /etc/schroot # ldconfig -r /srv/chroot/test/ -C
>/srv/chroot/test/etc/ld.so.cache -f /srv/chroot/test/etc/ld.so.conf
>ldconfig: Can't open configuration file
>/srv/chroot/test/etc/ld.so.conf: No such file or directory
>ldconfig: Can't create temporary cache file
>/srv/chroot/test/etc/ld.so.cache~: No such file or directory
>_______________________________________________
>Novalug mailing list
>Novalug@calypso.tux.org
>http://calypso.tux.org/mailman/listinfo/novalug
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5024 bytes
Desc: not available
URL: <https://lists.firemountain.net/pipermail/novalug/attachments/20131122/e2c9b4da/attachment.p7s>


More information about the Novalug mailing list