exasol / kafka-connect-jdbc-exasol

Exasol dialect for the Kafka Connect JDBC Connector
Apache License 2.0
10 stars 7 forks source link

08001 Connection refused #18

Closed mst94 closed 3 years ago

mst94 commented 3 years ago

Hello,

I am trying to run kafka-connect in my docker-compose environment.

When I am trying to create my table via docker exec -it exasol-db exaplus -c n11:8888 -u sys -P exasol -f /test/country.sql, i get the following error:

Error: [08001] Connection refused (Connection refused)

Same problem for running this command with sudo.

The log shows the following outputs (via docker-compose logs --follow exasol-db):

exasol-db | [2021-01-07 14:53:55] 30 auto-restarted processes exited in the last 29 seconds. Starting to delay process death handling. exasol-db | [2021-01-07 14:53:55] child 2872 (Part:11 Node:0 bucketfsd) returned with state 1. exasol-db | [2021-01-07 14:53:55] Started /usr/opt/EXASuite-7/EXAClusterOS-7.0.5/libexec/bucketfsd with PID:2882 UID:0 GID:0 Part:11 Node:0 exasol-db | [2021-01-07 14:53:55] 30 auto-restarted processes exited in the last 29 seconds. Starting to delay process death handling. And more and more... (don't know if it is an error message or could be even normal).

After docker-compose ps, all containers have properly started.

Can somebody help me? I am running Kafka, Zookeper, Kafka-Connect, Schema-Registry in version 6.0.0 from confluent.

Thanks in advance.

morazow commented 3 years ago

Hello @mst94,

Sorry for the delay.

We are going to look into it.

morazow commented 3 years ago

Hello @mst94,

The issue is related to the port. Since Exasol Docker 7.0+ the default JDBC port has changed from 8888 to 8563.

Could you please try with port 8563?

I was able to connect to database:

docker exec -it exasol-db exaplus -c n11:8563 -u sys -P exasol -sql "select 1;"
EXAplus 7.0.4 (c) EXASOL AG

Monday, January 11, 2021 9:31:12 AM CET
Connected to database DB1 as user sys.
EXASolution 7.0.5 (c) EXASOL AG

EXA: select 1;

1   
----
   1

1 row in resultset.

Disconnected.

Thanks for pointing this out, we are going to update the documentation in #12, also for the updated ports.

mst94 commented 3 years ago

Hello @morazow,

thanks for your answer. After changing the port, the connection still wasn't possible unfortunately. After figuring out whether my docker infrastructure is the point, I resolved another error. I already have known this error, but it disappeared last time after configuring my container as "user: root". But now, it does not help anymore:

exasol-db | [2021-01-11 09:38:47] exadt:: creating EXAStorage devices exasol-db | Traceback (most recent call last): exasol-db | File "/usr/opt/EXASuite-7/EXAClusterOS-7.0.5/docker/exadt", line 1608, in <module> exasol-db | main() exasol-db | File "/usr/opt/EXASuite-7/EXAClusterOS-7.0.5/docker/exadt", line 1605, in main exasol-db | command.func(command) exasol-db | File "/usr/opt/EXASuite-7/EXAClusterOS-7.0.5/docker/exadt", line 533, in init_sc exasol-db | devh.auto_create_file_devices(container_internal=True, no_odirect = sc_no_odirect) exasol-db | File "/usr/opt/EXASuite-7/EXAClusterOS-7.0.5/docker/libexadt/device_handler.py", line 393, in auto_create_file_devices exasol-db | self.create_node_file_devices("11", self.def_disk_name, 1, bytes_per_node, exasol-db | File "/usr/opt/EXASuite-7/EXAClusterOS-7.0.5/docker/libexadt/device_handler.py", line 297, in create_node_file_devices exasol-db | d.truncate(size) exasol-db | OSError: [Errno 22] Invalid argument exasol-db exited with code 1

I already removed the "data" directory and restartet the container and so on. Seems like it's an I/O Error, maybe due to permission restrictions.

Sorry for asking again but do you have an idea for this problem as well? If I should open a separate issue, let me know.

Thanks in advance!

morazow commented 3 years ago

Hey @mst94,

Are you using macOS? For the exasol/docker-db to work, the host should support O_DIRECT access.

HostOS

Pleae try to disable it in the ExaConf (https://github.com/exasol/docker-db#error-during-container-start-because-of-missing-o_direct-support).

You can separately start the exasol/docker-db with modified ExaConf, and attach it to the kafka containers network, instead of using the usual docker-compose setup. In docker-compose we use the default config that comes with the container.

mst94 commented 3 years ago

Hi @morazow,

I use an Ubuntu 64bit VM (via vagrant+virtualBox) on a windows 10 pc.

Yes I have read this information, but because of the fact that it already has worked some time on this host VM, I thought this is not the cause.

I will try it out! Thanks a lot for your help!

morazow commented 3 years ago

Hey,

I have not used vagrant or virtualBox. But I used KVM/QEMU, in it you can choose CPU chipset (Skylake, Haswell, etc) emulation. Sometimes, this can change accidentally to the ones that does not work with docker. Please check if there is similar feature, and check if it can be changed.

mst94 commented 3 years ago

Hey @morazow,

I've got the simple solution for the OSError-Problem: The space left on my hard disk was just too small (about 600mb). :)

After changing the ports, removing the data files and making enough space on the disk, the SELECT-statement to the exasol was succesful! Thanks for your time and help.

Best regards, Mario

morazow commented 3 years ago

Hey @mst94,

Ah yeah, limited disk space can cause issues.

We can close this issue if you do not have any questions. For different issues please feel to open new Github issue.

mst94 commented 3 years ago

Hey @morazow,

yes, I am very fine with it, thanks again for your help.