Perl error on locales

Perl complaining about locale settings

Problem description

When you encounter the following warning while running the Perl interpreter on your Linux board:

perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LC_CTYPE = "UTF-8",
LANG = (unset)
are supported and installed on your system.

This means that the target system lacks some of the locales that the client is transmitting into the SSH session environment.

Solution

Instead of installing unwanted locales on the target, you can modify the client configuration to prevent it from sending all locales.

For example, if your client is running Linux, comment out the following line in the /etc/ssh/ssh_config configuration file.

SendEnv LANG LC_*

Of course, you will need to log out and then log back in to the target system for the changes to take effect.