pcp
[Top] [All Lists]

Re: [pcp] Processing multiple archives with pmie

To: Jason Rappleye <jason.rappleye@xxxxxxxx>
Subject: Re: [pcp] Processing multiple archives with pmie
From: Ken McDonell <kenj@xxxxxxxxxxxxxxxx>
Date: Sun, 01 Aug 2010 07:01:59 +1000
Cc: pcp@xxxxxxxxxxx
In-reply-to: <0F1D40F2-EC9A-4B96-AC2D-7D9A7602A7D6@xxxxxxxx>
References: <8379D715-C33F-4F9B-AF15-1F3D455502B1@xxxxxxxx> <0F1D40F2-EC9A-4B96-AC2D-7D9A7602A7D6@xxxxxxxx>
Reply-to: kenj@xxxxxxxxxxxxxxxx
Thanks for the bug/patch Jason.

The first archive mentioned with -a becomes the default host, so rules
with no host qualification are evaluated against the default.  To
specify a non-default or explicit host, you need to add :hostname to the
pmie rules to qualify all metric name uses (see below).

This from the new QA #378 to exercise this set of issues ...

The rule below is only evaluated for the archive src-oss/kenj-pc-1
 
cat <<End-of-File | pmie -a src-oss/kenj-pc-1 -a src-oss/naslog
kernel.all.load #'1 minute' > 1.5 -> print "%h: %v";
End-of-File

The rule below is only evaluated for the archive src-oss/naslog

cat <<End-of-File | pmie -a src-oss/naslog -a src-oss/kenj-pc-1
kernel.all.load #'1 minute' > 1.5 -> print "%h: %v";
End-of-File

The first rule below names a host that matches the second archive, the
second rule names a host that matches the first archive ... so the first
rule is evaluated against the second archive and the second rule is
evaluated against the first archive.

cat <<End-of-File | pmie -a src-oss/naslog -a src-oss/kenj-pc-1
kernel.all.load :'kenj-pc' #'1 minute' > 1.5 -> print "%h: %v";
kernel.all.load :snort #'1 minute' > 1.5 -> print "%h: %v";
End-of-File

The rule below never true ... because the archives cover disjoint time
intervals and there is no point in time where values are available for
both hosts ... this means the ">" expression fails to be evaluated
before some_host gets a chance ... you could argue this is a bit
strange, but there is no way internally within pmie for "no value
available" to be represented within a set of values that range over
hosts.

cat <<End-of-File | pmie -a src-oss/naslog -a src-oss/kenj-pc-1
some_host ( kernel.all.load :'kenj-pc' :snort  #'1 minute' ) > 1.5 -> print 
"%h: %v";
End-of-File

Thanks again for raising this issue.

On Sat, 2010-07-31 at 01:33 -0700, Jason Rappleye wrote: 
> On Jul 30, 2010, at 4:02 PM, Jason Rappleye wrote:
> 
> > However, with that patch in place, it only processes the first archive  
> > specified on the command line.
> 
> Ah, my mistake. Now that I've read the documentation, I see that pmie only 
> considers the first archive on the command line unless one or more hostnames 
> are specified in a metric expression.
> 
> Jason
> 
> --
> Jason Rappleye
> System Administrator
> NASA Advanced Supercomputing Division
> NASA Ames Research Center
> Moffett Field, CA 94035
> 
> 
> 
> 
> 
> _______________________________________________
> pcp mailing list
> pcp@xxxxxxxxxxx
> http://oss.sgi.com/mailman/listinfo/pcp



<Prev in Thread] Current Thread [Next in Thread>