what is the escape special character in Nagios

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
newuser1
Posts: 4
Joined: Thu May 09, 2013 4:25 pm

what is the escape special character in Nagios

Post by newuser1 »

Hello All,

I wanted to know what are the escape special character when doing a query in Nagios Oracle_Query? for example select * from table_name i get an error saying

Code: Select all

OUTPUT: UNKNOWN - got no valid response for select \* from table_name - ORA-00911: invalid character (DBD ERROR: error possibly near <*> indicator at char 7 in 'select <*>\* from table_name)

I try one escape '\' before the *
I also tried 2 and 3 slaches and no luck
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: what is the escape special character in Nagios

Post by lmiltchev »

Not all of the checks can be tested successfully via "Test Check Command" in the CCM. This button was placed in the CCM for convenience, but was never meant to be a replacement of checking via the CLI. It works in the majority of the cases but it may fail on database checks because of the escaping issues.

Can you show us the exact command that you are running from the command line and the output of it?
Be sure to check out our Knowledgebase for helpful articles and solutions!
newuser1
Posts: 4
Joined: Thu May 09, 2013 4:25 pm

Re: what is the escape special character in Nagios

Post by newuser1 »

But this is in the GUI not in the command line.
newuser1
Posts: 4
Joined: Thu May 09, 2013 4:25 pm

Re: what is the escape special character in Nagios

Post by newuser1 »

how would you write a simple query when you go to configure tab > Monitor wizard > Oracle Query > enter the database credential > enter the default query?

Code: Select all

select count(*) from v\$session where status = "active"
I know it must be something simple I am just having a hard time figuring it out. All suggestions will be very appreciated!
You do not have the required permissions to view the files attached to this post.
Last edited by slansing on Fri May 10, 2013 1:50 pm, edited 1 time in total.
Reason: Please edit your previous post with new information if you are the last poster.
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: what is the escape special character in Nagios

Post by slansing »

Do you have a specific query in mind to test this against? One that will without a doubt be valid in your oracle database? Unfortunately this is something only you or your DBA would be able to find out.
Locked