Active Checks Oracle Database

Dear Community.

I tried the rule “Check SQL Database” to connect to my oracle database and check if a login is possible.

The check appears but shows me, that i have to install cx_Oracle (via python).

This rule is an active check and after installing the called programm i got a new error message, telling me that i need some oracle libraries.

Am i right that this active check gets executed by the checkmk server, or do i have to install it on the database server with an agent installed?

Hi @AlexanderS,

in generall you have two options to monitor an oracle database.

  1. If you have direct access to the databse server you can install a checkmk agent with the oracle plugin, to monitor all instances, grid infrastracture, ASM directly and send this information via agent back to you monitoring server. For this you can use your agent bakery (i guess you are running CEE) to deploy the plugin and configure it via WATO. The rule is called ORACLE Databases (Linux, Solaris, AIX). Depending on your checkmk version you have to deplay and configure the plugin on Windows hosts manually.

  2. If you don’t have direct access to the database host you can run the plugin locally or any other monitored host to connect remotly to you oracle instance via normal SQL connect. If you like so, you have to install at least the oracle instant client to have plsql and sqlplus available to connect to the remote instances. It’s the same plugin from 1. which is handling all this and can configured via WATO too. But you won’t all services monitored like with direct agent and plugin installed.

Thank you for this information.

I am running the agent on the database server but my boss wants to monitor the login process on the database. It seams that we had failures in the past where the database was up and running but didn’t accepted login requests.

I am currently trying to install the oracle instant client. But i have some problems with the libraries.
The manual tells me, that i have to install “libaio” but i don’t find some useful informations about what it does or why i need it.
https://oracle.github.io/odpi/doc/installation.html#linux

Install the operating system libaio package with sudo or as the root user. For example:
sudo yum install libaio
On some Linux distributions this package is called libaio1 instead.

Do you know more?

libaio is the a requirement for all oracle database related stuff. It’s the asynchronous I/O handler.
This should be normally available via your OS repositories out of the box. You have to install libaio-devel package, additonally to the normal libs, maybe the error message is a bit confusing about this.

thank you for your help.

I’ve sucessfully got everything to run but i don’t have any config files, so i’ve got the error:

UNKNOWN - Error while connecting to database: ORA-12541: TNS:no listener

The config folder is empty. I tried to use the default configs from oracle with some changes to fit my system, but it does not help.

Do you know why there aren’t any config files or does i don’t need some?

Which config files do you mean? For instant client or mk_oracle plugin?

Is your database you like to connect to configured to be accessable from remote? Is there a listener running accepting remote connections?

i am not very familiar with all the details.

I only know that i am lacking of the config files located in the instant client/network/admin folder.

The database is accepting connections.

Maybe you should ask you DBA for some help about this.

Normally you won’t need the tnsnames.ora to monitor remote instances, because you directly use the connection string to connect against the remote database to run the SQLs.

do we talking about the same thing?

Can you say wether this is a local or database side problem?

I know that there are some files like TNSNAMES.ORA and LISTENER.ORA (on the checkmk server in the mentioned folder)
But i don’t have any of them.

Yes, i am sure we are talking about the same thing.

This could be a problem on both sides. The database could not be reached or there is no listener running on the database host, or it is not allowing remote connections.

Hi,

thank you for your help.

I had to change the network port.

You are welcome. Glad my help worked for you :slight_smile:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.