how to specify the same log for different servers [client-local.cfg and LOG in hobbit-clients.cfg]
list Szymon Bakowski
Hello to all,
A quick question:
I do have to servers, load balanced, generating two logs comming from
the same application. My goal is to be able to log error messages from
these two machines, having different log names but logs holding the
same content.
Log on the firs machine is in format:
host1.log
and log on the other machine is
host2.log
What I did is in client-local.cfg file I have defined new class as following:
log:/var/lib/app/host*.log:10240
and tried to use it within hobbit-clients.cfg by doing (I do remember
that we can not uses classes within this file, just bb-hosts):
HOST=%host..\.domain\.com
...
LOG %/var/lib/app/host* "ERROR" yellow
But unfortunatelly it doesnt work :(
Is there any viable exit from this situation? Am I missing something
here or it is simply not possible to do it that way?
Kind regards
Szymon
list Steve Anderson
Try LOG %/var/lib/app/host.* "ERROR" yellow Iirc, this is using regular expression pattern matching, and a * means '0 or more of the preceding character'. So you need the . (any character) for it to extend.
▸
-----Original Message-----
From: user-7527983188e8@xymon.invalid [mailto:user-7527983188e8@xymon.invalid] On Behalf Of Szymon Bakowski
Sent: 12 February 2008 17:14
To: user-ae9b8668bcde@xymon.invalid
Subject: [hobbit] how to specify the same log for different servers [client-local.cfg and LOG in hobbit-clients.cfg]
Hello to all,
A quick question:
I do have to servers, load balanced, generating two logs comming from
the same application. My goal is to be able to log error messages from
these two machines, having different log names but logs holding the
same content.
Log on the firs machine is in format:
host1.log
and log on the other machine is
host2.log
What I did is in client-local.cfg file I have defined new class as following:
log:/var/lib/app/host*.log:10240
and tried to use it within hobbit-clients.cfg by doing (I do remember
that we can not uses classes within this file, just bb-hosts):
HOST=%host..\.domain\.com
...
LOG %/var/lib/app/host* "ERROR" yellow
But unfortunatelly it doesnt work :(
Is there any viable exit from this situation? Am I missing something
here or it is simply not possible to do it that way?
Kind regards
Szymon
This email has been scanned by Netintelligence http://www.netintelligence.com/email BiP Solutions Limited is a company registered in Scotland with Company Number SC086146 and VAT number 38303966 and having its registered office at Park House, 300 Glasgow Road, Shawfield, Glasgow, G73 1SQ **************************************************************************** This e-mail (and any attachment) is intended only for the attention of the addressee(s). Its unauthorised use, disclosure, storage or copying is not permitted. If you are not the intended recipient, please destroyall copies and inform the sender by return e-mail. This e-mail (whether you are the sender or the recipient) may be monitored, recorded and retained by BiP Solutions Ltd. E-mail monitoring/ blocking software may be used, and e-mail content may be read at any time. You have a responsibility to ensure laws are not broken when composing or forwarding e-mails and their contents. ****************************************************************************
list Szymon Bakowski
Hmm, I am not sure of that. I believe that * stands for ANY character, not just proceeding one - you have to use classes to be able to use preceding characters. Secondly, non-escaped dot stands for exactly one character so it has to be escaped, hasn't it ? (So the entry in hobbit-client.cfg should look more like this: LOG %/var/lib/app/host\.* "ERROR" yellow - but what I am really after is something like "LOG %/var/lib/app/host* "ERROR" yellow" in hobbit-client.cfg and "log:%/var/lib/app/host*:10240" in clients-local.cfg) Also, as Henrik said, I cannot use regexp in clients-local.cfg (which is a pain in the *** :D - just joking) but here is another question coming: Having two logs on two machines, from the same program but differently named and not being able to use regex in clients-local.cfg, how can I define files that I am after (files that particular hobbit client will be exporting to server? - is the only solution here to make these logs being named identical ?)? Are regex expression not being paresed through whole client-local.cfg file or just classes ? ex. In client-local.cfg I cannot use "log:%/var/lib/app/host??.log:10240" (which would perfectly sorted my problem out matching one of the two logs on both servers) or can I? Regs Szymon
▸
On 12/02/2008, Steve Anderson <user-a1c59649b432@xymon.invalid> wrote:Try
LOG %/var/lib/app/host.* "ERROR" yellow
Iirc, this is using regular expression pattern matching, and a * means '0 or more of the preceding character'. So you need the . (any character) for it to extend.
-----Original Message-----
From: user-7527983188e8@xymon.invalid [mailto:user-7527983188e8@xymon.invalid] On Behalf Of Szymon Bakowski
Sent: 12 February 2008 17:14
To: user-ae9b8668bcde@xymon.invalid
Subject: [hobbit] how to specify the same log for different servers [client-local.cfg and LOG in hobbit-clients.cfg]
Hello to all,
A quick question:
I do have to servers, load balanced, generating two logs comming from
the same application. My goal is to be able to log error messages from
these two machines, having different log names but logs holding the
same content.
Log on the firs machine is in format:
host1.log
and log on the other machine is
host2.log
What I did is in client-local.cfg file I have defined new class as following:
log:/var/lib/app/host*.log:10240
and tried to use it within hobbit-clients.cfg by doing (I do remember
that we can not uses classes within this file, just bb-hosts):
HOST=%host..\.domain\.com
...
LOG %/var/lib/app/host* "ERROR" yellow
But unfortunatelly it doesnt work :(
Is there any viable exit from this situation? Am I missing something
here or it is simply not possible to do it that way?
Kind regards
Szymon
This email has been scanned by Netintelligence
http://www.netintelligence.com/email
BiP Solutions Limited is a company registered in Scotland with Company Number SC086146 and VAT number 38303966 and having its registered office at Park House, 300 Glasgow Road, Shawfield, Glasgow, G73 1SQ ****************************************************************************
This e-mail (and any attachment) is intended only for the attention of the addressee(s). Its unauthorised use, disclosure, storage or copying is not permitted. If you are not the intended recipient, please destroyall copies and inform the sender by return e-mail.
This e-mail (whether you are the sender or the recipient) may be monitored, recorded and retained by BiP Solutions Ltd.
E-mail monitoring/ blocking software may be used, and e-mail content may be read at any time. You have a responsibility to ensure laws are not broken when composing or forwarding e-mails and their contents.
****************************************************************************
list Galen Johnson
I've done something like this successfully: log:`date +"/path/to/logs/Server_%Y.%m.%d.log"`:10240 So you might be able to do to use the shell to do what you need via the `...` command. =G=
▸
-----Original Message-----
From: user-7527983188e8@xymon.invalid [mailto:user-7527983188e8@xymon.invalid] On Behalf Of Szymon Bakowski
Sent: Wednesday, February 13, 2008 9:30 AM
To: user-ae9b8668bcde@xymon.invalid
Subject: Re: [hobbit] how to specify the same log for different servers [client-local.cfg and LOG in hobbit-clients.cfg]
Hmm, I am not sure of that.
I believe that * stands for ANY character, not just proceeding one -
you have to use classes to be able to use preceding characters.
Secondly, non-escaped dot stands for exactly one character so it has
to be escaped, hasn't it ? (So the entry in hobbit-client.cfg should
look more like this: LOG %/var/lib/app/host\.* "ERROR" yellow - but
what I am really after is something like "LOG %/var/lib/app/host*
"ERROR" yellow" in hobbit-client.cfg and
"log:%/var/lib/app/host*:10240" in clients-local.cfg)
Also, as Henrik said, I cannot use regexp in clients-local.cfg (which
is a pain in the *** :D - just joking) but here is another question
coming:
Having two logs on two machines, from the same program but differently
named and not being able to use regex in clients-local.cfg, how can I
define files that I am after (files that particular hobbit client will
be exporting to server? - is the only solution here to make these logs
being named identical ?)?
Are regex expression not being paresed through whole client-local.cfg
file or just classes ?
ex.
In client-local.cfg I cannot use "log:%/var/lib/app/host??.log:10240"
(which would perfectly sorted my problem out matching one of the two
logs on both servers) or can I?
Regs
Szymon
On 12/02/2008, Steve Anderson <user-a1c59649b432@xymon.invalid> wrote:Try
LOG %/var/lib/app/host.* "ERROR" yellow
Iirc, this is using regular expression pattern matching, and a * means '0 or more of the preceding character'. So you need the . (any character) for it to extend.
-----Original Message-----
From: user-7527983188e8@xymon.invalid [mailto:user-7527983188e8@xymon.invalid] On Behalf Of Szymon Bakowski
Sent: 12 February 2008 17:14
To: user-ae9b8668bcde@xymon.invalid
Subject: [hobbit] how to specify the same log for different servers [client-local.cfg and LOG in hobbit-clients.cfg]
Hello to all,
A quick question:
I do have to servers, load balanced, generating two logs comming from
the same application. My goal is to be able to log error messages from
these two machines, having different log names but logs holding the
same content.
Log on the firs machine is in format:
host1.log
and log on the other machine is
host2.log
What I did is in client-local.cfg file I have defined new class as following:
log:/var/lib/app/host*.log:10240
and tried to use it within hobbit-clients.cfg by doing (I do remember
that we can not uses classes within this file, just bb-hosts):
HOST=%host..\.domain\.com
...
LOG %/var/lib/app/host* "ERROR" yellow
But unfortunatelly it doesnt work :(
Is there any viable exit from this situation? Am I missing something
here or it is simply not possible to do it that way?
Kind regards
Szymon
This email has been scanned by Netintelligence
http://www.netintelligence.com/email
BiP Solutions Limited is a company registered in Scotland with Company Number SC086146 and VAT number 38303966 and having its registered office at Park House, 300 Glasgow Road, Shawfield, Glasgow, G73 1SQ ****************************************************************************
This e-mail (and any attachment) is intended only for the attention of the addressee(s). Its unauthorised use, disclosure, storage or copying is not permitted. If you are not the intended recipient, please destroyall copies and inform the sender by return e-mail.
This e-mail (whether you are the sender or the recipient) may be monitored, recorded and retained by BiP Solutions Ltd.
E-mail monitoring/ blocking software may be used, and e-mail content may be read at any time. You have a responsibility to ensure laws are not broken when composing or forwarding e-mails and their contents.
****************************************************************************
list Ger Maguire
Hi, I have been looking through the config files and man pages but can't find where to put the PIXELS definition to change the default size for the history bargraphs. Can someone point me in the right direction ? Thanks, Ger.
list Iain M Conochie
▸
On Wed, 2008-02-13 at 14:51 +0000, Ger Maguire wrote:
Hi, I have been looking through the config files and man pages but can't find where to put the PIXELS definition to change the default size for the history bargraphs. Can someone point me in the right direction ?
See the RRDHEIGHT and RRDWIDTH settings in hobbitserver.cfg file. Cheers Iain
Thanks, Ger.
list Szymon Bakowski
Cheers for that hint. Will give it a go. Szymon
▸
On 13/02/2008, Galen Johnson <user-87f955643e3d@xymon.invalid> wrote:I've done something like this successfully: log:`date +"/path/to/logs/Server_%Y.%m.%d.log"`:10240 So you might be able to do to use the shell to do what you need via the `...` command. =G= -----Original Message----- From: user-7527983188e8@xymon.invalid [mailto:user-7527983188e8@xymon.invalid] On Behalf Of Szymon Bakowski Sent: Wednesday, February 13, 2008 9:30 AM To: user-ae9b8668bcde@xymon.invalid Subject: Re: [hobbit] how to specify the same log for different servers [client-local.cfg and LOG in hobbit-clients.cfg] Hmm, I am not sure of that. I believe that * stands for ANY character, not just proceeding one - you have to use classes to be able to use preceding characters. Secondly, non-escaped dot stands for exactly one character so it has to be escaped, hasn't it ? (So the entry in hobbit-client.cfg should look more like this: LOG %/var/lib/app/host\.* "ERROR" yellow - but what I am really after is something like "LOG %/var/lib/app/host* "ERROR" yellow" in hobbit-client.cfg and "log:%/var/lib/app/host*:10240" in clients-local.cfg) Also, as Henrik said, I cannot use regexp in clients-local.cfg (which is a pain in the *** :D - just joking) but here is another question coming: Having two logs on two machines, from the same program but differently named and not being able to use regex in clients-local.cfg, how can I define files that I am after (files that particular hobbit client will be exporting to server? - is the only solution here to make these logs being named identical ?)? Are regex expression not being paresed through whole client-local.cfg file or just classes ? ex. In client-local.cfg I cannot use "log:%/var/lib/app/host??.log:10240" (which would perfectly sorted my problem out matching one of the two logs on both servers) or can I? Regs Szymon On 12/02/2008, Steve Anderson <user-a1c59649b432@xymon.invalid> wrote:Try LOG %/var/lib/app/host.* "ERROR" yellow Iirc, this is using regular expression pattern matching, and a * means '0 or more of the preceding character'. So you need the . (any character) for it to extend. -----Original Message----- From: user-7527983188e8@xymon.invalid [mailto:user-7527983188e8@xymon.invalid] On Behalf Of Szymon Bakowski Sent: 12 February 2008 17:14 To: user-ae9b8668bcde@xymon.invalid Subject: [hobbit] how to specify the same log for different servers [client-local.cfg and LOG in hobbit-clients.cfg] Hello to all, A quick question: I do have to servers, load balanced, generating two logs comming from the same application. My goal is to be able to log error messages from these two machines, having different log names but logs holding the same content. Log on the firs machine is in format: host1.log and log on the other machine is host2.log What I did is in client-local.cfg file I have defined new class as following: log:/var/lib/app/host*.log:10240 and tried to use it within hobbit-clients.cfg by doing (I do remember that we can not uses classes within this file, just bb-hosts): HOST=%host..\.domain\.com ... LOG %/var/lib/app/host* "ERROR" yellow But unfortunatelly it doesnt work :( Is there any viable exit from this situation? Am I missing something here or it is simply not possible to do it that way? Kind regards Szymon This email has been scanned by Netintelligence http://www.netintelligence.com/email BiP Solutions Limited is a company registered in Scotland with Company Number SC086146 and VAT number 38303966 and having its registered office at Park House, 300 Glasgow Road, Shawfield, Glasgow, G73 1SQ **************************************************************************** This e-mail (and any attachment) is intended only for the attention of the addressee(s). Its unauthorised use, disclosure, storage or copying is not permitted. If you are not the intended recipient, please destroyall copies and inform the sender by return e-mail. This e-mail (whether you are the sender or the recipient) may be monitored, recorded and retained by BiP Solutions Ltd. E-mail monitoring/ blocking software may be used, and e-mail content may be read at any time. You have a responsibility to ensure laws are not broken when composing or forwarding e-mails and their contents. ****************************************************************************
list Ger Maguire
Hi Iaian, Its the colourbar that i am trying to resize as opposed to the graphs. If you look at http://hobbitmon.sourceforge.net/docs/man1/bb-hist.cgi.1.html there is a PIXELS parameter for this. I have set PIXELS="360" in the hobbitserver.cfg file but it doesn't seem to make any difference, does anyone know if this needs to go somewhere else or different sytax ? Thanks, Ger.
▸
On Wed, 13 Feb 2008 14:54:32 +0000, Iain M Conochie <user-c784e16a5170@xymon.invalid> wrote:On Wed, 2008-02-13 at 14:51 +0000, Ger Maguire wrote:Hi, I have been looking through the config files and man pages but can't find where to put the PIXELS definition to change the default size for the history bargraphs. Can someone point me in the right direction ?See the RRDHEIGHT and RRDWIDTH settings in hobbitserver.cfg file. Cheers IainThanks, Ger.
list Bill Benedetto
Ger Maguire writes:
Ger> Its the colourbar that i am trying to resize as opposed to Ger> the graphs. If you look at Ger> http://hobbitmon.sourceforge.net/docs/man1/bb-hist.cgi.1.html Ger> there is a PIXELS parameter for this. Ger> Ger> I have set PIXELS="360" in the hobbitserver.cfg file but Ger> it doesn't seem to make any difference, does anyone know Ger> if this needs to go somewhere else or different sytax ? That webpage says that PIXELS is parameter passed to the cgi script. So to make it narrower, you'd have to pass PIXELS like this: http://HOBBITHOST/hobbit-cgi/bb-hist.sh?HISTFILE=SOME_HOST.disk&ENTRIES=50&IP=0.0.0.0&DISPLAYNAME=SOME_HOST&PIXELS=800 which looks pretty good on my screen. Does this help at all? Or did you already know that? -- - Bill +=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ Bill Benedetto <user-8bb6d2788b33@xymon.invalid> The Goodyear Tire & Rubber Co. I don't speak for Goodyear and they don't speak for me. We're both happy.
list Ger Maguire
Yes, That’s what I am trying to do, I have hobbit displayed within a windown of a cms system and need to narrow the history pages to display properly. Ger.
▸
-----Original Message-----
From: Bill Benedetto [mailto:user-8bb6d2788b33@xymon.invalid]
Sent: 13 February 2008 16:51
To: user-ae9b8668bcde@xymon.invalid
Subject: Re: [hobbit] History PIXELS setting
Ger Maguire writes:
Ger> Its the colourbar that i am trying to resize as opposed to Ger> the graphs. If you look at Ger> http://hobbitmon.sourceforge.net/docs/man1/bb-hist.cgi.1.html Ger> there is a PIXELS parameter for this. Ger> Ger> I have set PIXELS="360" in the hobbitserver.cfg file but Ger> it doesn't seem to make any difference, does anyone know Ger> if this needs to go somewhere else or different sytax ? That webpage says that PIXELS is parameter passed to the cgi script. So to make it narrower, you'd have to pass PIXELS like this:
http://HOBBITHOST/hobbit-cgi/bb-hist.sh?HISTFILE=SOME_HOST.disk&ENTRIES=50&I P=0.0.0.0&DISPLAYNAME=SOME_HOST&PIXELS=800
▸
which looks pretty good on my screen.
Does this help at all? Or did you already know that?
--
- Bill
+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=
++=+=+
Bill Benedetto <user-8bb6d2788b33@xymon.invalid> The Goodyear Tire & Rubber
Co.
I don't speak for Goodyear and they don't speak for me. We're both happy.
15:20
15:20