Fix: Can’t exec “locale”: No such file or directory at /usr/share/perl5/Debconf/Encoding.pm
https://itsfoss.com/fix-exec-locale-file-directory/
In a terminal, use the following commands to download and extract the libc-bin package:
apt-get download libc-bin
dpkg -x libc-bin*.deb unpackdir/
Next you need to copy these files:
sudo cp unpackdir/sbin/ldconfig /sbin/
Now you need to make sure that things are in order. Run these commands to ensure that:
sudo apt-get install --reinstall libc-bin
sudo apt-get install -f
Normally, this should fix the problem of Can’t exec “locale”: No such file or directory at /usr/share/perl5/Debconf/Encoding.pm line 16. Do let me know in the comment section whether or not this fixes your problem.