Cannot determine port due to unknown HANA version

Found it:

Maybe some other hints from this thread could help you determine your problem.

1 Like

Thank you again.
The query from the CLI string doeas not return the same result as the query from the HANA studio. This is on the first picture. Just the command prompt from the DB.
I will test and inform of the progress.

Hello,
here it goes:
HANA DB is on Red Hat enterprise Linux 8.1 (ver. 4.18.0-147.el8.x86_64) and there is a syntax error in querries in the mk_sap_hana plugin, that causes plugin to fail querying the database version.
I have tried stripping quotes but with no positive effect.

Can you please give me the exact lines (in preformatted text) from you HANA plugin, i can try to fix it for you.
If you post your checkmk version i also will check if the wrong syntax is still in the source and may send a pull request to fix it in further versions.

Hello,

same problem here (CMK 2.0.0p12 CEE).
This Cannot determine port due to unknown HANA version - #21 by tosch
was helpful. After changing this:

if [ "$RUNAS" = "agent" ]; then
        result="$(${hdbsql_path} -C -F\; -x -a -n localhost -i ${instance} "${credentials}" "$query" 2>/dev/null)"

to that

   if [ "$RUNAS" = "agent" ]; then
        result="$(${hdbsql_path} -C -F\; -x -a -n localhost -i ${instance} ${credentials} "$query" 2>/dev/null)"

in “/usr/lib/check_mk_agent/plugins/mk_sap_hana” it worked for me (unquoting credentials)

Furthermore I had my user got blocked because excessive tests. I would recommed to check that as well.

Thank you tosch, for your efforts :slight_smile:
CMK_VERSION=“2.0.0p9”
Now I have upgraded to CMK 2.0.0p17 but… do not see any difference.
Probably will put this “on hold” as some other urgent matters have got my attention and SAP has its own tools to take care of itself :wink:

Thank you SamVimes - I will try playing with syntax as time allows and post results here. I have full year as I understand the rules of thread preservation :slight_smile:

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed. Contact an admin if you think this should be re-opened.