Over a million developers have joined DZone.

Troubleshooting Connection Problems: HANA Express From HANA Studio

DZone's Guide to

Troubleshooting Connection Problems: HANA Express From HANA Studio

In this article, you will learn the methods required to troubleshoot problems you may experience while connecting HANA express from HANA Studio.

· Database Zone ·
Free Resource

MariaDB TX, proven in production and driven by the community, is a complete database solution for any and every enterprise — a modern database for modern applications.

After repeatedly seeing questions around failed connections to HANA Express, I'm compiling the basic troubleshooting steps I take when, for example, HANA Studio does not connect to my HXE instance. The most typical error is:

The system cannot be reached. logon data cannot be used.

The order in the steps is not random. If any of the tests fail, moving forward with the next step does not make any sense without fixing whatever is causing the test to fail.

Sounds obvious but worth checking.

From the console in your server, you can use ./HDB info and make sure you can actually connect using hdbsql -i <<instance number>> -d <<database name> -u <<some user>> and run something like:


Or check that the tenant database is actually running if that is what you want to connect to (if it is not, the error will say "general error: database 'hxe' is unavailable SQLSTATE: HY000"):

select * from "SYS"."M_DATABASES";

You can start the tenant database with:

alter system start database <<tenant name>>;

If you encounter any errors when starting the database or in the logs ( /usr/sap/<SID>/HDBXX/<server name>/trace ), go do a search for them and best of luck fixing your database.

If you can effectively connect with hdbsql, let's move to seeing if you can connect from outside.

Can Only Connect to SYSTEMDB But Not the Tenant

If your SQL client (HANA Studio) can connect to the SYSTEM database but not to the tenant database AND you could connect to the tenant in the previous step, you may need to take some additional steps like the ones described here.

Very old versions of HANA Studio could also be the problem.

In a cloud environment, you will find the external or public IP in the dashboard where you can manage your virtual machine.

On Google Cloud Platform:

On Amazon Web Services:

On MS Azure:

On SAP Cloud Appliance Library:

In a Virtual Machine, use the command sudo ifconfig to get his information from inside the VM. If you do not get an IPv4 address (something in the shape of ), it is not getting one assigned. This may be solved by changing the network configuration in the Virtual Machine but I'm not covering this here as it is already covered here.

On a command prompt in the same computer where you have the connection issues, ping the external IP:

If instead of a reply you get "Connection timeout... Destination host not reachable," your computer cannot reach the server. The IP may be wrong, you may be behind some corporate firewall or proxy or for some reason (not the case of the default configurations for HXE), there's no reply sent back.

A firewall kind of problem could be ruled out by using an online ping tool, such as https://ping.eu/ or connecting from another place like your phone or home network.

Most of the time, I've seen either the IP has changed because the server was restarted and the IP was set to ephemeral or the temptation to use the internal IP was too big.

Ping hxehost

Or whatever your hostname is. If you can reach the IP, but pinging the hostname gives you the message "Ping request could not find host...," it's time to go back to editing the host's file (explained on step 4 in this tutorial).

Some Coffee Corner Here

I have some weird anecdotes from people failing to edit the host's file for the first time: some choose to create a new file like "hosts.txt" because they do not have the necessary administrative rights while others just ignore the error message and don't save the changes. However, the prize goes to a user that decided to copy the entire driver's folder into the Desktop so that the permissions would not be a problem.

The default pre-configured images on cloud providers come with the proper ports open. Make sure you can reach the ones needed by SQL clients (for example, 3xx13, 3xx15, 3xx17 - where "xx" stands for your instance number and 90 is the default for HXE).

I use Telnet for this. In my Windows computer, I had to enable it in the programs and features.

The connection succeeds pretty much if you do not get an error (I get a black screen for a short while). A closed port would say something like "Could not open connection to the host, on port 30013: Connect failed."

Mac users can resort to nc -v hostname 3xx13 instead of telnet and should get a success message.

If you cannot reach the ports but got this far, you probably need to ask your network admins to enable the ports needed to reach your HANA instance. Make sure you match the instance number and version/flavor of your server.

You are not behind a firewall or proxy, all of the previous steps worked and still cannot connect from the SQL client? Enable the JDBC trace

In HANA Studio, Right click on the connection -> Properties->JDBC trace:

Options for other clients can be found in the help section.

Further help, as usual, can be found in the Q&A. Be sure to search for your question before you post it and add all the information you consider relevant (what error you are getting, what have you already tried and failed, some screenshots).

MariaDB AX is an open source database for modern analytics: distributed, columnar and easy to use.

sap hana ,sap hana implementation ,database

Published at DZone with permission of

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}