KS-Soft. Network Management Solutions
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister    ProfileProfile    Log inLog in 

Get ODBC error into email?

 
Post new topic   Reply to topic    KS-Soft Forum Index -> Configuration, Maintenance, Troubleshooting
View previous topic :: View next topic  
Author Message
grussell



Joined: 21 Jan 2010
Posts: 36

PostPosted: Thu Jan 21, 2010 2:29 am    Post subject: Get ODBC error into email? Reply with quote

We are using an ODBC driver to push the log results to an SQL database. We’ve setup the option to notify us via email should the system be unable to publish the log.

But how do we get the error message generated by the SQL server/ODBC driver into the email? I have gone through the macro variables but can’t see an option?

For instance – the SQL database may return “unable to convert string to int….” or "timeout" ..etc – how do we get this into the email? I can see the message in the bottom message bar of HostMonitor?

Thanks,

Gavin.
Back to top
View user's profile Send private message
KS-Soft



Joined: 03 Apr 2002
Posts: 12791
Location: USA

PostPosted: Thu Jan 21, 2010 12:38 pm    Post subject: Reply with quote

Logging errors recorded into system log file specified on System Log page in the Options dialog. If you are using text file for system log then you may setup Text Log test method to check for some specific error and assign "Send e-mail" action to the test.
On the other hand, if you want to check connection to SQL server and send e-mail in case of some problem, you should use ODBC Query test.

Regards
Alex
Back to top
View user's profile Send private message Visit poster's website
grussell



Joined: 21 Jan 2010
Posts: 36

PostPosted: Tue Jan 26, 2010 10:33 am    Post subject: Unclear Reply with quote

Thanks for your response - it didn't quite answer my question.

I am wondering how we get the last system error into a variable to be used within an alert email?

Thanks.
Back to top
View user's profile Send private message
KS-Soft



Joined: 03 Apr 2002
Posts: 12791
Location: USA

PostPosted: Tue Jan 26, 2010 1:52 pm    Post subject: Reply with quote

If you are using text file for system log then you may setup Text Log test method to check for some specific error and assign "Send e-mail" action to the test.
Otherwise I do not see any option.

Regards
Alex
Back to top
View user's profile Send private message Visit poster's website
grussell



Joined: 21 Jan 2010
Posts: 36

PostPosted: Fri Jan 29, 2010 5:44 am    Post subject: Suggestion Reply with quote

ok - then a useful feature request would be a variable that holds the details of the last system error.

Thanks
Back to top
View user's profile Send private message
KS-Soft



Joined: 03 Apr 2002
Posts: 12791
Location: USA

PostPosted: Fri Jan 29, 2010 12:24 pm    Post subject: Reply with quote

And how you can use this variable? Start some action every 5 min?

Regards
Alex
Back to top
View user's profile Send private message Visit poster's website
grussell



Joined: 21 Jan 2010
Posts: 36

PostPosted: Sat Jan 30, 2010 12:38 pm    Post subject: Reply with quote

In the "Options" under "Log settings" I have "Execute alert profile when log inaccessible" generating an "Email"

I would want to use this variable in this alert email so I receive an email telling me the SQL error that preventing the log from being written.

Thanks
Back to top
View user's profile Send private message
KS-Soft



Joined: 03 Apr 2002
Posts: 12791
Location: USA

PostPosted: Sat Jan 30, 2010 3:45 pm    Post subject: Reply with quote

Ok, we implement this option in next version.

Regards
Alex
Back to top
View user's profile Send private message Visit poster's website
grussell



Joined: 21 Jan 2010
Posts: 36

PostPosted: Thu Mar 11, 2010 3:43 pm    Post subject: Reply with quote

Is this in 8.50 now?

Thanks
Back to top
View user's profile Send private message
KS-Soft



Joined: 03 Apr 2002
Posts: 12791
Location: USA

PostPosted: Thu Mar 11, 2010 4:45 pm    Post subject: Reply with quote

Yes.
Quote:
==================
New %HM_LastLoggingError% macro variable can be used as parameter of the actions. It represents description of last logging error (if any); can be useful for actions triggered by HostMonitor when it cannot save data into the log
==================

http://www.ks-soft.net/hostmon.eng/news.htm

Regards
Alex
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    KS-Soft Forum Index -> Configuration, Maintenance, Troubleshooting All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group

KS-Soft Forum Index