No syslog notification are received and error is logged as, UNDEFINED_VARIABLE_ACCESS-Variable 'INSTANCEDISPLAYNAME' has not been assigned a value
search cancel

No syslog notification are received and error is logged as, UNDEFINED_VARIABLE_ACCESS-Variable 'INSTANCEDISPLAYNAME' has not been assigned a value

book

Article ID: 425305

calendar_today

Updated On:

Products

VMware Smart Assurance

Issue/Introduction

You configured Smarts Syslog Manager to generate notifications from messages in the Linux system syslog file using the defauly files. The adapter is running and reading the log file, but no notifications are appearing in the SAM console.  The following messages are repeatedly logged in the Syslog Adapter logfile

ASL-W-ERROR_RULE_SOURCE-While executing rule set '/opt/InCharge/SAM/smarts/local/rules/icoi-syslog/syslog_mgr.asl'
ASL-ERROR_ACTION-While executing action at:
ASL-CALL_STACK_RULE-   RuleName: ASL_HOOK, Line: 421
ASL-CALL_STACK_RULE-   RuleName: START, Line: 91
ASL-ERROR_INVOKE-While attempting to invoke operation 'getVariable' of object 'GA_PersistentDriver::syslog_ICS_Domain_Persistent-Driver'
ASL-ERROR_UNDEFINED_VARIABLE_ACCESS-Variable 'INSTANCEDISPLAYNAME' has not been assigned a value

Cause

INSTANCEDISPLAYNAME is not defined in the my_hook_syslog.asl file. 

Resolution

In the my_hook_syslog.asl file, add the following in the initialization section: 


INSTANCEDISPLAYNAME = ""; 

And also  to the "MODIFY_ATTRIBUTES"  section. of the same file e.g.
MODIFY_ATTRIBUTES {
} do {
    DISCARD = "FALSE";
    
    /* Variable Assignments */
    INSTANCENAME = HOST."_".APPLICATION_NAME."_".PROCESS_ID ? LOG;
    
    // FIX: Assign value to INSTANCEDISPLAYNAME to prevent ASL-ERROR
    INSTANCEDISPLAYNAME = INSTANCENAME;