Smarts NCM: NCM is not pulling any data for a device with a custompackage; AutoDisc.log error: PACKAGE FAILED TO COMPILE!;
search cancel

Smarts NCM: NCM is not pulling any data for a device with a custompackage; AutoDisc.log error: PACKAGE FAILED TO COMPILE!;

book

Article ID: 331099

calendar_today

Updated On:

Products

VMware Smart Assurance

Issue/Introduction

Symptoms:


None of the devices configuration units are being pulled.

In this particular case the devices are Cisco routers and the APR tables, interfaces, ACLs etc are not being pulled

Syntax error in the custompackage files

Environment

VMware Smart Assurance - NCM

Cause

When creating your own custom code / package always check for syntax errors

One thing to check is autodisc.log for message "DASL::Compile: Complete" if you get any error messages then these have to be resolved

Resolution

In this particular instance the following error was seen in the autodisc.log:
##############
May 21 04:30:06 -1437526048#1: PACKAGE /opt/smarts-ncm/custompackage/checkpoint/devCP.dasl FAILED TO COMPILE!
May 21 04:30:06 -1437526048#1: !> Error In   : /opt/smarts-ncm/custompackage/checkpoint/devCP.dasl#158:
May 21 04:30:06 -1437526048#1: !>             if ((strfind(sysDesc,"IP530",0) == -1) {
May 21 04:30:06 -1437526048#1: !>                                                    ^
May 21 04:30:06 -1437526048#1: !> DriverCompiler::bnfDeviceDriver: Compiler::expectName: Expected ")", got "{" (BlockCompiler.cpp#181) :Error in function discoverViaSnmp:/opt/smarts- ##############
 
The error message points to the file "/opt/smarts-ncm/custompackage/checkpoint/devCP.dasl" at line number "158" there is sysntax error.

On review of the file the user could see the bracket for line is not closed:

"if ((strfind(sysDesc,"IP530",0) == -1) {"

Changing line to the following resolved the issue:

"if (strfind(sysDesc,"IP530",0) == -1) {"
 
After fixing the syntax error, recompile the drivers by restarting the device server service:

service voyence restart

Configuration pull will work correctly afterwards.