Failed to set locale, defaulting to C warning message on CentOS Linux when running yum

Posted on in Categories , , , last updated January 18, 2018

Whenever I run yum command, I get an error or warning that read as Failed to set locale, defaulting to C. How do I fix this issue on CentOS 7 Linux server? Why do I get “Failed to set locale, defaulting to C” when using yum on CentOS 6 or Fedora Linux system? How do I fix it?