Highlighted
Frequent Contributor.. Frequent Contributor..
Frequent Contributor..
1824 views

UCMDB Enrichment Rule Question

I'm trying to update a CI with information from a Configuration file. I've got the file discovered, and the DocumentContent Attribute shows the document. I was able to write the regular expression to parse the file into the parts I want. 

 

My problem is what I believe to be a data type issue. I want to parse out part of the string and place the value into a Custom Field in the CI of type "string". I can do that, but when I look at the CI, the field is populated with Hex data. 

 

I'm wondering if the issue is that ConfigurationDocument is in bytes, and it won't convert the string. I can't seem to figure out a way to convert it?? Can this be done?

Thanks!

Stephen

0 Likes
15 Replies
Highlighted
Acclaimed Contributor.. Acclaimed Contributor..
Acclaimed Contributor..

Re: UCMDB Enrichment Rule Question

You most probably right regarding the data type failure here.

To get precise answer I'd suggets to review cmdb.enrichment.log and probably error.log for relevant exception message.

Regards
-Dmitry Gomel, PMP
Click the Like button at the bottom to say 'Thanks'.
0 Likes
Highlighted
Frequent Contributor.. Frequent Contributor..
Frequent Contributor..

Re: UCMDB Enrichment Rule Question

This is from the cmdb.enrichment log:

 

2015-01-22 10:50:14,026 [qtp1788469293-1350] INFO appender.addEnrichmentDefinition(99) - LinuxServerTest -- add enrichment definition
2015-01-22 10:52:21,376 [qtp1788469293-1353] INFO appender.updateEnrichmentDefinition(121) - LinuxServerTest -- update enrichment definition
2015-01-22 10:52:21,567 [Enrichment Calculator Task-145] INFO appender.calculateEnrichment(126) - LinuxServerTest -- Trigger the calculate enrichment 3
2015-01-22 10:52:21,568 [Enrichment Calculator Task-145] INFO appender.calculateEnrichment(141) - LinuxServerTest -- Going to retreive TQL result
2015-01-22 10:52:21,595 [Enrichment Calculator Task-145] INFO appender.calculateEnrichment(155) - LinuxServerTest -- Obtained TQL result: Nodes result
Node -10: 1 object(s)
Node -11: 1 object(s)
Links result
Link -12: 1 link(s)

2015-01-22 10:52:21,595 [Enrichment Calculator Task-145] INFO appender.calculateEnrichment(204) - LinuxServerTest -- Calculation is required
2015-01-22 10:52:21,618 [Enrichment Calculator Task-145] INFO appender.calculateEnrichment(211) - LinuxServerTest -- Start calculate enrichment related to pattern: LinuxServerTest with version PatternVersion:2@ResultVersion:1
2015-01-22 10:52:21,627 [Enrichment Calculator Task-145] INFO appender.fillBulk(50) - LinuxServerTest -- enrichment definition update 1 object/s
2015-01-22 10:52:21,627 [Enrichment Calculator Task-145] INFO appender.updateObjectsAndLinks2Model(790) - Enrichment LinuxServerTest: Sending to Data-In bulk #1
2015-01-22 10:52:21,715 [Enrichment Calculator Task-145] INFO appender.calculateEnrichment(237) - LinuxServerTest -- Finished calculate enrichment related to pattern: LinuxServerTest

 

It's putting a value in the field, but it's just not the "right" value. Is there a way to convert it??

Thanks,

Stephen

0 Likes
Highlighted
Acclaimed Contributor.. Acclaimed Contributor..
Acclaimed Contributor..

Re: UCMDB Enrichment Rule Question

You'er failing during data-in.

Go to cmdb.reconciliation.audit.log. Find the two string related to your enrichment (you could serach by the name or by the timestamp). Take the operation number (long string of numbers after the timestamp).

Search cmdb.reconciliation.log for the operation.

Post an error.

Regards
-Dmitry Gomel, PMP
Click the Like button at the bottom to say 'Thanks'.
0 Likes
Highlighted
Frequent Contributor.. Frequent Contributor..
Frequent Contributor..

Re: UCMDB Enrichment Rule Question

Dima,

  Here's what I'm seeing in the cmdb.reconciliation audit.log:

2015-01-22 10:52:21,628 INFO - [ID=1183875312] [Customer ID=1] [Changer=Enrichment: Enrichment's rule: LinuxServerTest] [Datas to update- 1] [Referenced Data- 0] updateIfExist : [Objects For Update- unix(1)] [Links For Update-] [Referenced Objects-] [Referenced Links-]
2015-01-22 10:52:21,681 INFO - [ID=1183875312] [Customer ID=1] [Changer=Enrichment: Enrichment's rule: LinuxServerTest] [total= 0.053 , manipulation= 0.005 , identification= 0.013 , identification.query= 0.008 , identification.match= 0.000 , merge= 0.008 , update= 0.019 , merge.loa= 0.005 , update.model.topology= 0.000 , update.model.post_validation= 0.006 , update.model.db= 0.002 , update.history= 0.008 , update.loa= 0.001 , update.ha= 0.002 ] [durations: identify= 0.013 dataIn= 0.013] [Ignore From Cmdb- 0 Ignore From Bulk- 0 Merge Operations- 0 Merged CIs- 0 Type Changes- 0 Max Topology Level- 1] [Datas to update- 1] [Referenced Data- 0] updateIfExist : [Objects For Update- unix(1)] [Links For Update-] [Referenced Objects-] [Referenced Links-]

 

I'm not sure what to make of this. 😞
Thakns,

Stephen

 

ETA - Here's the Reconcoliation Log. It's for a new run, but it still represents the same rule and use case.

 

2015-01-22 13:06:42,788 DEBUG - Auto excluded value read from persistence: [RecType:node, CiType:interface, Attribute:mac_address, Value:00000000000000E0, ]
2015-01-22 13:06:42,788 DEBUG - Auto excluded value read from persistence: [RecType:node, CiType:interface, Attribute:mac_address, Value:020054554E01, ]
2015-01-22 13:06:42,788 DEBUG - Auto excluded value read from persistence: [RecType:node, CiType:interface, Attribute:mac_address, Value:80000048FE80, ]
2015-01-22 13:06:42,788 DEBUG - Auto excluded value read from persistence: [RecType:node, CiType:interface, Attribute:mac_address, Value:00141B4CC800, ]
2015-01-22 13:06:42,791 DEBUG - updateIfExist: Level - 1:
DataContainer (total size=1):
Objects For Update(size=1)
{unix@31610093bd7145865b732d8eca7eea80}@[(string-COX_Location:[B@39404cbb)]
Links For Update(size=0)
Referenced Objects(size=0)
Referenced Links(size=0)
ListPropertiesUpdateEmpty
2015-01-22 13:06:42,802 DEBUG - [Operation #1610485580 Name=DataInBulkOperation] - Level 1 [datain analysis time=0] - Level - 1 datain results:
Input To Reconciled Map:
input: 31610093bd7145865b732d8eca7eea80 output: {unix@31610093bd7145865b732d8eca7eea80}@[(string-global_id:31610093bd7145865b732d8eca7eea80)]

Bulk for model update:
2015-01-22 13:06:42,807 DEBUG - [Operation #1610485580 Name=DataInBulkOperation] [identification time=11] Level - 1 identification results:
identification Vs Cmdb: Number of entries: 1
key=<31610093bd7145865b732d8eca7eea80> value=<(1){31610093bd7145865b732d8eca7eea80={unix@31610093bd7145865b732d8eca7eea80}@[(string-global_id:31610093bd7145865b732d8eca7eea80)]}>
identification in Bulk: Number of entries: 1
key=<31610093bd7145865b732d8eca7eea80> value=<(1){31610093bd7145865b732d8eca7eea80={unix@31610093bd7145865b732d8eca7eea80}@[(string-COX_Location:[B@39404cbb)], }>
links identification Vs Cmdb: Number of entries: 0
links identification in Bulk: Number of entries: 0
2015-01-22 13:06:42,807 DEBUG - [Operation #1610485580 Name=DataInBulkOperation] [datain analysis time=7] - Level - 1 datain results:
Input To Reconciled Map:
input: 31610093bd7145865b732d8eca7eea80 output: {unix@31610093bd7145865b732d8eca7eea80}@[(string-COX_Location:[B@39404cbb), (string_list-TenantsUses:[Empty CMDB property value]), (string-global_id:31610093bd7145865b732d8eca7eea80)] _maintenanceProperties=[(string-ENTIRE_CI_UPDATER__:Enrichment)]

Bulk for model update:
updateStrict
{unix@31610093bd7145865b732d8eca7eea80}@[(string-COX_Location:[B@39404cbb), (string_list-TenantsUses:[Empty CMDB property value])] _maintenanceProperties=[(string-ENTIRE_CI_UPDATER__:Enrichment)]
2015-01-22 13:06:42,829 DEBUG - [Operation #1610485580 Name=DataInBulkOperation] [model update time=22] - Level - 1

 

0 Likes
Highlighted
Acclaimed Contributor.. Acclaimed Contributor..
Acclaimed Contributor..

Re: UCMDB Enrichment Rule Question

Reconciliation.audit.log is showing that operation was successful.

What attribute of UNIX Ci was updated?

 

Regards
-Dmitry Gomel, PMP
Click the Like button at the bottom to say 'Thanks'.
0 Likes
Highlighted
Frequent Contributor.. Frequent Contributor..
Frequent Contributor..

Re: UCMDB Enrichment Rule Question


Correct. COX_Location was updated, but with the value of "[B@39404cbb)" which should have been a readable, english value.

Thanks,

Stephen

0 Likes
Highlighted
Acclaimed Contributor.. Acclaimed Contributor..
Acclaimed Contributor..

Re: UCMDB Enrichment Rule Question

What data type the source and target attributes are?

Regards
-Dmitry Gomel, PMP
Click the Like button at the bottom to say 'Thanks'.
0 Likes
Highlighted
Frequent Contributor.. Frequent Contributor..
Frequent Contributor..

Re: UCMDB Enrichment Rule Question

The flow is this:

1) Discovery Job runs to find ConfigurationDocument CI

2) For the output of the file (Attribute of DocumentContent, Type of Bytes) I want to parse the filename into 5 variables of type String.

 

So can I not do that? It seems to want to write the attribute in extended characters.

Thanks,
Stephen 

0 Likes
Highlighted
Acclaimed Contributor.. Acclaimed Contributor..
Acclaimed Contributor..

Re: UCMDB Enrichment Rule Question

My suggestion is following. To eliminate data transformation phase, please create new attribute under Configuration Type CI with the same data type to what you runnig Regex on. Populate it on the same CI. Will this works?

Regards
-Dmitry Gomel, PMP
Click the Like button at the bottom to say 'Thanks'.
0 Likes
Highlighted
Frequent Contributor.. Frequent Contributor..
Frequent Contributor..

Re: UCMDB Enrichment Rule Question

So you're suggesting I'd have to update the CI Attrubutes manually, using modified Discovery scripts in order to be able to store the discovered values into the correct fields? I'm also researching how to update the patterns as well. 🙂

Thanks,

Stephen

0 Likes
Highlighted
Acclaimed Contributor.. Acclaimed Contributor..
Acclaimed Contributor..

Re: UCMDB Enrichment Rule Question

No, i suggesting to move the data from/to attributes of the same type (string, decimal etc).

Regards
-Dmitry Gomel, PMP
Click the Like button at the bottom to say 'Thanks'.
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.