Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No connection to local databases #77

Closed
j08ur opened this issue Jan 23, 2024 · 2 comments
Closed

No connection to local databases #77

j08ur opened this issue Jan 23, 2024 · 2 comments
Labels
question Further information is requested

Comments

@j08ur
Copy link

j08ur commented Jan 23, 2024

I have PostgreSQL and Clickhouse databases running on a server. Both are accessible via DBeaver or via http
But when I try to make a connection in Datalens, connection attempt fails, with the error like this(for clickhouse):
Data source refused connection. ERR.DS_API.DB.SOURCE_CONNECT_ERROR { "data": { "details": { "db_message": "HTTPSConnectionPool(host='192.168.1.224', port=8123): Max retries exceeded with url: /?query_id=e7c0bdde-b9f7-11ee-bdd0-0242ac120006&database=system&join_use_nulls=1&distributed_ddl_task_timeout=280&send_progress_in_http_headers=0&output_format_json_quote_denormals=1 (Caused by ConnectTimeoutError(<urllib3.connection.HTTPSConnection object at 0x7f43f6287130>, 'Connection to 192.168.1.224 timed out. (connect timeout=1.0)'))" }, "message": "Data source refused connection.", "debug": { "db_message": "HTTPSConnectionPool(host='192.168.1.224', port=8123): Max retries exceeded with url: /?query_id=e7c0bdde-b9f7-11ee-bdd0-0242ac120006&database=system&join_use_nulls=1&distributed_ddl_task_timeout=280&send_progress_in_http_headers=0&output_format_json_quote_denormals=1 (Caused by ConnectTimeoutError(<urllib3.connection.HTTPSConnection object at 0x7f43f6287130>, 'Connection to 192.168.1.224 timed out. (connect timeout=1.0)'))", "query": "select 1" }, "code": "ERR.DS_API.DB.SOURCE_CONNECT_ERROR" } }
The same problem appears while running Datalens container on the server or on the other machine in network.

Could you please tell me, what may be the issue?

@MCPN
Copy link
Contributor

MCPN commented Feb 21, 2024

Hi! connect timeout=1.0 means DataLens cannot connect to your PostgreSQL/ClickHouse. This can be caused by a multitude of reasons, for example, if your DB is not reachable from your docker container.

You can check it by connecting to the data-api container using docker exec -it <container id> bash and querying the DB from it (for example, with ClickHouse's http interface ).

If that is not the case, please let us know where your DBs are deployed (e.g. locally on the same host as DataLens or on another remote one) and how do you connect to them via dbeaver/http

@resure resure added the question Further information is requested label Apr 1, 2024
@resure
Copy link
Contributor

resure commented Apr 1, 2024

Feel free to reopen the issue with additional information if this problem is still relevant.

@resure resure closed this as not planned Won't fix, can't repro, duplicate, stale Apr 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants