Solved: I was connecting to the wrong port, according to
/etc/services | grep db2
I have a DB2 Express C v.10.5 database running on localhost, but simply I can't connect to it.
Translation of the error message below: "java.net.ConnectException: An error occured when opening the socket to the server ... on port 50000 with message: Connection refused"
I am using DBeaver 3.1.1, Ubuntu 14.04 LTS 64 bit.
Can somebody please help? :|