perl: warning: setting locale failed error solution

I have been getting this error while restarting Nagios and I have quite ignored it for some time until when I needed to install some nagios plugins which made me to look for a solution out there for this problem.

perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory

Finally I was able to fix it with this simple solution.

$ locale-gen en_US en_US.UTF-8 hu_HU hu_HU.UTF-8

then

$ dpkg-reconfigure locales

Advertisements

2 thoughts on “perl: warning: setting locale failed error solution

  1. MrBarns says:

    Hey very nice blog!!….I’m an instant fan, I have bookmarked you and I’ll be checking back on a regular….See ya

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: