Cacti (home)ForumsDocumentation
Cacti: offical forums and support
It is currently Sun Jun 25, 2017 2:06 pm

All times are UTC - 5 hours




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: AutoM8 0.35 Reg Ex help?
PostPosted: Mon Aug 01, 2011 9:59 am 
Offline

Joined: Sat Jun 11, 2011 7:31 pm
Posts: 14
I'm trying to write a regex for host graph tree creation. Got two of them created, but can't seem to get this one to match.
Here's what I've got.
Matching on host desc, which is B100 Bink to Str0, some are B100, some are B28 or B14. So I need to match the first 3-4 chars, to a space. And I want that to be the subtree.
Tried this matching pattern, which should work I think, ^(B[0-9]*)
With replacement pattern of ${1}

But as the result, I get the whole string back B100 Bink to Str0

What am I missing?
Thanks


Top
 Profile  
 
 Post subject: Re: AutoM8 0.35 Reg Ex help?
PostPosted: Tue Aug 02, 2011 2:52 am 
Offline

Joined: Thu Jul 15, 2010 8:56 am
Posts: 24
Location: Tours, FRANCE
Hi,

Try ^(B[0-9]+) .*$
Begin with B, then one or more figure, then a space, then whatever.

_________________
Cacti Version - 0.8.7g
Plugin Architecture - 2.8
Poller Type - Spine
Server Info - Linux 2.6.16.60-0.21-smp
Web Server - Apache/2.2.3 (Linux/SUSE)
PHP - 5.2.5
MySQL - 5.0.26
RRDTool - 1.2.12
SNMP - 5.3.0.1
Plugins Autom8 - Aggregate - Realtime


Top
 Profile  
 
 Post subject: Re: AutoM8 0.35 Reg Ex help?
PostPosted: Wed Feb 15, 2017 1:22 am 
Offline

Joined: Wed Oct 13, 2010 3:22 am
Posts: 22
Hi There,

I am using cacti 1.0.1, having issue with regular expression matching for data query output field 'ifDescr'

ifDescr showing as below,
Found item [ifDescr='V1'] index: 1 [from value]
Found item [ifDescr='V2'] index: 2 [from value]
Found item [ifDescr='V3'] index: 3 [from value]
Found item [ifDescr='V4'] index: 4 [from value]



Graph Creation Criteria

Operation - blank

Field Name - ifDescr

Matching Pattern - ^(V[1-4])


Attachments:
Graph-criteria.JPG
Graph-criteria.JPG [ 40.52 KiB | Viewed 216 times ]
Autom Graph.JPG
Autom Graph.JPG [ 98.25 KiB | Viewed 216 times ]
Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  

Protected by Anti-Spam ACP Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group