Strange terminal characters in Red Hat RHEL3 from gcc, g++, man, etc

The default locale for RHEL3 is en_US.UTF-8. If you do not have a UTF-8 terminal (most people do not), this will cause strange characters to be printed in place of certain characters, such as the pipe character. Setting LANG/LANGVAR in /etc/profile won't work, because these variables are overwritten by the locales support in glibc.

The proper fix is to edit /etc/sysconfig/i18n and replace en_US.UTF-8 with en_US wherever it appears in that file.

Leave a Reply