/var/core/ files
list Nick Pettefar
Is there a way to be alerted if any core files are created in /var/core/ (Solaris 10)? Just the presence of any core* file is sufficient. Regards, Nick Pettefar
list Martin Ward
Hi Nick,
In the analysis.cfg file you can test for the existence or otherwise of a file or files. The section from the man page is:
----
FILE filename [color] [things to check] [TRACK]
DIR directoryname [color] [size<MAXSIZE] [size>MINSIZE]
[TRACK]
These entries control the status of the "files" column. They
allow you to check on various data for files and direc-
tories.
filename and directoryname are names of files or direc-
tories, with a full path. You can use a regular expression
to match the names of files and directories reported by the
client, if you prefix the expression with a '%' character.
----
Since you want the non-existance of a core file to be green you could create an entry like this:
HOST=*
FILE=/var/core/* red noexist
Which should report the FILE column as green if nothing exists in /var/core and red if anything appears.
I haven’t tried this so you may need to poke at it a little, but hopefully it will give you a starting point.
▸
|\/|
From: Xymon [mailto:xymon-bounces at xymon.com] On Behalf Of Nick Pettefar
Sent: 08 August 2013 15:44
To: xymon
Subject: [Xymon] /var/core/ files
Is there a way to be alerted if any core files are created in /var/core/ (Solaris 10)? Just the presence of any core* file is sufficient.
Regards,
Nick Pettefar
[Colt Disclaimer] This email is from an entity of the Colt group of companies. Colt Group S.A., K2 Building, Forte 1, 2a rue Albert Borschette, L-1246 Luxembourg, R.C.S. B115679. Corporate and contact information for our entities can be found at http://colt.net/uk/en/Colt-Group-of-Companies/index.htm. Internet communications are not secure and Colt does not accept responsibility for the accurate transmission of this message. Content of this email or its attachments is not legally or contractually binding unless expressly previously agreed in writing by Colt
list Nick Pettefar
Thanks Martin, I'll give that a try. Regards, Nick Pettefar
▸
On 8 August 2013 16:06, Ward, Martin <user-2d33a6eb6a05@xymon.invalid> wrote:
Hi Nick,****
** **
In the analysis.cfg file you can test for the existence or otherwise of a
file or files. The section from the man page is:****
** **
----****
FILE filename [color] [things to check] [TRACK]****
** **
DIR directoryname [color] [size<MAXSIZE] [size>MINSIZE]****
[TRACK]****
** **
These entries control the status of the "files" column. They****
allow you to check on various data for files and direc-****
tories.****
** **
filename and directoryname are names of files or direc-****
tories, with a full path. You can use a regular expression****
to match the names of files and directories reported by the****
client, if you prefix the expression with a '%' character.****
----****
Since you want the non-existance of a core file to be green you could
create an entry like this:****
** **
HOST=*****
FILE=/var/core/* red noexist****
** **
Which should report the FILE column as green if nothing exists in
/var/core and red if anything appears.****
** **
I haven’t tried this so you may need to poke at it a little, but hopefully
it will give you a starting point.****
** **
|\/|****
** **
*From:* Xymon [mailto:xymon-bounces at xymon.com] *On Behalf Of *Nick
Pettefar
*Sent:* 08 August 2013 15:44
*To:* xymon
*Subject:* [Xymon] /var/core/ files****
** **
Is there a way to be alerted if any core files are created in /var/core/
(Solaris 10)? Just the presence of any core* file is sufficient.
****
Regards,
Nick Pettefar****
[Colt Disclaimer] This email is from an entity of the Colt group of
companies. Colt Group S.A., K2 Building, Forte 1, 2a rue Albert Borschette,
L-1246 Luxembourg, R.C.S. B115679. Corporate and contact information for
our entities can be found at
http://colt.net/uk/en/Colt-Group-of-Companies/index.htm. Internet
communications are not secure and Colt does not accept responsibility for
the accurate transmission of this message. Content of this email or its
attachments is not legally or contractually binding unless expressly
previously agreed in writing by Colt
list Vernon Everett
Hi
We do check for core files, and we do it as follows.
client-local.cfg
file: `/opt/csw/bin/sudo /usr/bin/find /var/core/ -type f 2> /dev/null`
This assumes appropriate sudo permissions are already set up for xymon user
on the client.
analysis.cfg
HOST=myserver
FILE %^/var/core/.* NOEXIST red
Salt to taste.
Cheers
V
▸
On 8 August 2013 23:12, Nick Pettefar <user-2027539dd102@xymon.invalid> wrote:
Thanks Martin, I'll give that a try. Regards, Nick Pettefar On 8 August 2013 16:06, Ward, Martin <user-2d33a6eb6a05@xymon.invalid> wrote:Hi Nick,**** ** ** In the analysis.cfg file you can test for the existence or otherwise of a file or files. The section from the man page is:**** ** ** ----**** FILE filename [color] [things to check] [TRACK]**** ** ** DIR directoryname [color] [size<MAXSIZE] [size>MINSIZE]**** [TRACK]**** ** ** These entries control the status of the "files" column. They**** allow you to check on various data for files and direc-**** tories.**** ** ** filename and directoryname are names of files or direc-**** tories, with a full path. You can use a regular expression**** to match the names of files and directories reported by the**** client, if you prefix the expression with a '%' character.**** ----**** Since you want the non-existance of a core file to be green you could create an entry like this:**** ** ** HOST=***** FILE=/var/core/* red noexist**** ** ** Which should report the FILE column as green if nothing exists in /var/core and red if anything appears.**** ** ** I haven’t tried this so you may need to poke at it a little, but hopefully it will give you a starting point.**** ** ** |\/|**** ** ** *From:* Xymon [mailto:xymon-bounces at xymon.com] *On Behalf Of *Nick Pettefar *Sent:* 08 August 2013 15:44 *To:* xymon *Subject:* [Xymon] /var/core/ files**** ** ** Is there a way to be alerted if any core files are created in /var/core/ (Solaris 10)? Just the presence of any core* file is sufficient. **** Regards, Nick Pettefar**** [Colt Disclaimer] This email is from an entity of the Colt group of companies. Colt Group S.A., K2 Building, Forte 1, 2a rue Albert Borschette, L-1246 Luxembourg, R.C.S. B115679. Corporate and contact information for our entities can be found at http://colt.net/uk/en/Colt-Group-of-Companies/index.htm. Internet communications are not secure and Colt does not accept responsibility for the accurate transmission of this message. Content of this email or its attachments is not legally or contractually binding unless expressly previously agreed in writing by Colt
--
"Accept the challenges so that you can feel the exhilaration of victory"
- General George Patton
list Nick Pettefar
Thanks! It is now working. However, when there are no core files, the alert symbol is white and sad. How can I make it green and happy please? Regards, Nick Pettefar Dublin
list Vernon Everett
That's odd. It's green for me. But we are also checking a few things for other files too. Might be a minor bug - if no file data comes through, it assumes no checks - hence white. Can you add a check for the existence of a file. Something that will ALLWAYS be there, like /etc/passwd or similar. If that works, you can leave it as a workarround, or talk to Henrik about a minor bug fix. Cheers Vernon
▸
On 10 August 2013 01:17, Nick Pettefar <user-2027539dd102@xymon.invalid> wrote:
Thanks! It is now working. However, when there are no core files, the alert symbol is white and sad. How can I make it green and happy please? Regards, Nick Pettefar Dublin
-- "Accept the challenges so that you can feel the exhilaration of victory" - General George Patton