Table of Contents
1.1 Verify VAN remote collector config and status.
1.2 Verify logs are received on the VAN.
1.3 Verify if logs are received on Versa Director.
1.4 Verify SMTP notification rule config.
1.5 Verify the reachability to SMTP server.
1.7 Validate the SMTP server configuration.
1.8 Test config to check if SMTP server is fine.
1.9 Review logs to check issue with SMTP server.
1.9.1 Reachability to SMTP is not working.
1.9.2 Authentication failure due to wrong SMTP username password.
2.0 In case of Secure (TLS) SMTP server.
NOTE: Log the putty/terminal session to capture all outputs when performing requested steps, will be helpful when engaging Support.
Purpose
Versa Director can be used to generate SMTP notification for network events. To generate the notification Versa Director depends on the data received from Versa analytics. To make this work we need to configure a remote collector on Versa Analytics to send log events from Versa Analytics to Versa Director.
1.1 Verify VAN remote collector config and status
Here is the sample config from Versa analytics. In the collector config destination address should be Versa Director south bound IP address and source should be local analytics IP.
Remote collector status should be established, stats should show message sent.
Note: - For more details on remote collector refer Versa Doc LINK, which extensively talks about remote collector and its configuration.
1.2 Verify logs are received on the VAN
Switch to root user in shell and go to DIR “/var/tmp/log/<sub-org-name>/backup”. At this location we can check if Analytics is receiving the latest logs/alarms for which SMTP notification will be sent by Director. Same can be verified via Versa Analytics GUI, which confirms Analytics have processed the received logs.
Once we are able to see logs in Versa Analytics UI and CLI, these will be sent to Versa Director through the remote collector which we have configured.
1.3 Verify if logs are received on Versa Director
To verify from UI: We can then check in VD GUI >> Monitor Tab >> Click on Details
Detail output:
Verify from Shell:
Check if logs are received on VD “/var/log/vnms/spring-boot/vnms-alarms-ingress.log”
If you don’t see logs in Monitor Tab or vnms-alarms-ingress.log file, then first confirm if logs event is being received or not.
Run following command on Director Shell to confirm if packets are being received from Analytics on configured remote collector port number.
sudo tcpdump -i any port 20514 -nn
1.4 Verify SMTP notification rule config
Make sure the “correct org” has been selected and the “match condition” is correctly defined.
If still not working, follow steps 1.5 to 1.8
1.5 Verify the reachability to SMTP server
A> Check SMTP server resolving to IP and its reachable from Director. If you are using Secure SMTP(TLS) please also check step 1.9
E.g. Check if DNS is resolving and ping is working to mail server.
B> Check if SMTP server ports are reachable from VD, In case any firewall is blocking smtp port.
1.6 API to test email
Execute following api to test SMTP configuration and substitute ip, email and username/password.
curl -k -X GET \
'https://<vd-ip>:9182/vnms/template/test?email=<email_addresse>' \
-H 'Accept: application/xml' \
-H 'Accept-Encoding: gzip, deflate' \
-u 'username:password'
1.7 Validate the SMTP server configuration
Next, verify the “SMTP config” and “rule config” under Administrator >>> Notification configuration.
1.8 Test config to check if SMTP server is fine
If the notification is still not working, please try to create a test rule as per below. This will generate a notification when the someone is trying to login with wrong username/password on VD , so no dependency on logs received from Analytics.
1.9 Review logs to check issue with SMTP server.
Review “/var/log/vnms/spring-boot/vnms-alarms-core.log” and look for the errors when performing test mentioned in step 1.8.
Possible causes:
1.9.1 Reachability to SMTP is not working.
1.9.2 Authentication failure due to wrong SMTP username password.
2.0 In case of Secure (TLS) SMTP server
If using Secure SMTP, we need to install the root certificate in java trust store using below cmd
“keytool -import - trustcacerts - keystore /etc/ssl/certs/java/cacerts -alias <alias name> -import -file <certfile name>”
otherwise below exception will be seen in “/var/log/vnms/spring-boot/vnms-alarms-core.log” file
javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
2.1 Contact Support
Capture Logs all above outputs and contact Versa Support.