Highlighted
Established Member..
Established Member..
540 views

Did not match the common regular expression

I've done a regular expression that matches on FlexAgent Regex tester and several regex testers but when I start Arcsight connector, I receive this error on agent.log.

Regular expression is: \s*\|\|(\w{7,13}\_\w{3}\_\d{2})\s*\|\|(\w{0,1})\s*\|\|(\w{0,3})\s*\|\|(\d{0,8})\s*\|\|(\d{0,6})\s*\|\|(\d{0,3})\s*\|\|(\w{0,9})\s*\|\|(\w*|(?:\w*\-\w*)|(?:\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3})|(?:\s*\w*\s*\w*\s*\w*))\s*\|\|(\w*|(?:\s*\w*\s*\w*\s*\w*\s*\w*))\s*\|\|(\w*|(?:\w*\s*\w*))\s*\|\|(\w{0,8})\s*\|\|(\w{0,8})

and a part of the log:

             ||                    ||               ||              ||          ||          ||      ||            ||                    ||                    ||                                                  ||                                                  ||                                                  ||                                                  ||                                                  ||

             ||xx1xxxx_EP1_00      ||D              ||004           ||20160331  ||145712    ||500   ||XXX1390     ||XXXX20093C1721      ||SLG1                ||Log Administration                                ||OPEN                                              ||                                                  ||                                                  ||                                                  ||
             ||xx1xxxx_EP1_00      ||D              ||001           ||20160331  ||145554    ||500   ||XXX1390     ||XXXX20093C1721      ||SLG1                ||Log Administration                                ||OPEN                                              ||                                                  ||                                                  ||                                                  ||
             ||xxxxxx0056xxx_EP1_00||D              ||056           ||20160331  ||103043    ||500   ||XXXXXXXXX   ||10.10.10.10         ||                    ||User Change                                       ||MODI                                              ||XXX02721                                          ||                                                  ||                                                  ||xx1xxxx_EP1_00      ||               ||              ||          ||          ||      ||            ||                                            FF Time Assignment                                ||XXXXXXXX9                                         ||XXXXXXX09                                         ||20141016                                          ||20171231                                          ||

Labels (2)
0 Likes
4 Replies
Highlighted
Trusted Contributor.. Trusted Contributor..
Trusted Contributor..

Could you attach or share error from agent.log?

0 Likes
Highlighted
Established Member..
Established Member..

Of course. Here you have:

[2016-05-19 12:13:23,510][INFO ][default.com.arcsight.agent.baseagents.l.t][fileStarted] Starting to read file [F:\SAPFlex\sap.txt]

[2016-05-19 12:13:23,511][INFO ][default.com.arcsight.agent.Agent][instantiateAgents] Agent [SAP_Custom] started.

[2016-05-19 12:13:23,515][WARN ][default.com.arcsight.agent.sdk.a.r][parseValues] Message [] did not match the common regular expression [\s*\|\|(\w{7,13}\_\w{3}\_\d{2})\s*\|\|(\w{0,1})\s*\|\|(\w{0,3})\s*\|\|(\d{0,8})\s*\|\|(\d{0,6})\s*\|\|(\d{0,3})\s*\|\|(\w{0,9})\s*\|\|(\w*|(?:\w*\-\w*)|(?:\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3})|(?:\s*\w*\s*\w*\s*\w*))\s*\|\|(\w*|(?:\s*\w*\s*\w*\s*\w*\s*\w*))\s*\|\|(\w*|(?:\w*\s*\w*))\s*\|\|(\w{0,8})\s*\|\|(\w{0,8})], ignoring...

[2016-05-19 12:13:23,519][INFO ][default.com.arcsight.agent.bg.h][getInputStream] Resource [additionalregexparsing\sdkrfilereader\regex.0.sdkrfilereader.properties] not found

[2016-05-19 12:13:23,521][INFO ][default.com.arcsight.agent.bg.h][getInputStream] Resource [additionalregexparsing\sdkrfilereader\regex.0.sdkrfilereader.properties] not found (AUP file ignored)

0 Likes
Highlighted
Absent Member.
Absent Member.

I think you should use \\ instead of \

0 Likes
Highlighted
Established Member..
Established Member..

On the sdkrfilereader regex it has \\ but this error is post interpretation of the agent, and transforms \\ in \

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.