On Tue, 5 Aug 2003, Cliff wrote:

> Hello Tom,
> 
> Thursday, July 31, 2003, 11:34:56 AM, you wrote:
> 
> TD> On Thu, 31 Jul 2003, Matt M wrote:
> 
> >> Hello I am new to the list and I just wanted to say hi AND ask for some 
> >> help
> >> on an issue I have encountered.
> >> This is what I get:
> >> 
> >> -----------------------------------------------------------------------
> >> ERROR: Mrtg will most likely not work properly when the environment
> >>        variable LANG is set to UTE-8. Please run mart in an environment
> >>        where this is not the case:
> >> 
> >>        env LANG=C /usr/local/src/mrtg/bin/mrtg ...
> >> -----------------------------------------------------------------------
> 
> TD> The answer is above!!
> What is above is confusion and possibly maybe typos.
> 
> "LANG is set to UTE-8" ....huh?
> Mine shows LANG is set to UTF-8, not UTE-8.
> Is this setting different on different platforms?
> 
> "Please run mart in an environment...."
> Mart? Must be MRTG I suppose.
> 
> 
> TD> Set LANG=en_us or en or C and it should work. The above error is telling 
> you
> TD> what it thinks is wrong. RHL8.0 by default sets LANG=en_us.utf_8 or 
> something
> TD> like that. This assumes you set it to English to begin with. If you set 
> it to
> TD> something other than English then suggest using LANG=C.
> TD> Do an echo $LANG at the command line to see what it is set to.
> 
>  When I do an echo $LANG - here is the output on my RH9 box:
>  en_US.UTF-8
> 
>  So do I edit a config file...which one?
>  And what do I put in it?

Typically mrtg is run from a cronjob. So if you find the cronjob 
and add the following to the beginning of it:
env LANG=C 

On Red Hat it is usually in /etc/crontab. On my system it looks like this:

0-59/5 * * * * root /usr/bin/mrtg /etc/mrtg/mrtg.cfg

So if yours looks like the above then change it to look like this:
0-59/5 * * * * root env LANG=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg

and it shoule work. In addition if you do not need utf8 support then you
can edit /etc/sysconfig/i18n and set the LANG variable to C or en_us.

Either one should work. You have to reboot for the second one to work though.
> 
>  And what does proper output from the echo $LANG command look like?

This is what I use:
(icarus pts10) $ echo $LANG
en_US
(icarus pts10) $

It could also look like this:
(icarus pts10) $ echo $LANG
C
(icarus pts10) $

If you set it for C.

>  There has been much discussion of this problem.
>  Perhaps I've missed the 1 email that has the
>  clear & consise solution posted in it.

My original answer assumed (maybe incorrectly) that you understood how to
set shell variables. 

HTH.

-- 
......Tom               Registered Linux User #14522    http://counter.li.org
[EMAIL PROTECTED]       My current SpamTrap ------->    [EMAIL PROTECTED]

--
Unsubscribe mailto:[EMAIL PROTECTED]
Archive     http://www.ee.ethz.ch/~slist/mrtg
FAQ         http://faq.mrtg.org    Homepage     http://www.mrtg.org
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi

Reply via email to