apt not working: installed libc-bin package post-installation script subprocess returned error exit status 134

Interestingly enough, when I tried what Eric Gazoni did when his slapd failed, of course dpkg didn't want me to forcibly remove vital organs of Ubuntu ;) ... But after stubbornly executing through his instructions, replacing slapd by libc-bin, and afterwards moving /tmp/libc-bin.* back to /var/lib/dpkg/info/, it repaired itself!

So, essentially this did the trick, although it is possible that not every command is necessary:

sudo mv /var/lib/dpkg/info/libc-bin.* /tmp/
sudo dpkg --remove --force-remove-reinstreq libc-bin
sudo dpkg --purge libc-bin
sudo apt install --reinstall libc-bin
sudo mv /tmp/libc-bin.* /var/lib/dpkg/info/

A slightly less invasive fix:

for PROBDIR in "" "/usr" "/usr/local"; do find "${PROBDIR}/lib/x86_64-linux-gnu" -type f -ls; done;

Source: https://github.com/microsoft/WSL/issues/4760