Note to self: how to fix a broken #archlinux after a #stupid ctrl+c on a running #ldconfig as root ...

Upon a new boot using a recover key, #arch-root gives a seg fault.

You’re on your own now.

Try to remember last action and #RTFM: start by asking a nice man about #ldconfig.

Problem here is the cache file is corrupt. We need a new one.

- enter rescue mode, get access to the net, install #emacs
- decrypt root partition, mount it on /mnt
- edit a custom /tmp/ld.so.conf with the correct paths to /mnt
- create a new /etc/ld.so.cache with

ldconfig /mnt/lib /mnt/usr/lib -f /tmp/ld.so.conf -C /mnt/etc/ld.so.cache

- reboot
- ban sudo
- stop doing #stupidshit

Lucky this time.

@csantosb I wonder if deleting `/etc/ld.so.cache` and then entering the chroot to run `ldconfig` would have worked, since with that file missing the linker should fall back to searching `/usr/lib/`.
@heftig Good question: no ld.so.cache at all. For sure, a corrupt file gives segmentaton fault when one tries to chroot, but no file at all ?