
On 03-10-2006 10:27:29 +0200, Ronald Oussoren wrote:
Hi,
I finally have time to work on porting our app to monetdb again and am immediately running into a problem: I can't get MonetSQLdb to work properly :-(
I've started an Mserver process:
$ Mserver --dbinit="module(sql_server); sql_server_start();"
This works correcty, I can connect to it using the MapiClient binary and do SQL queries. However, this python code fails:
import MonetSQLdb c = MonetSQLdb.connect()
It says:
!ERROR mapi_reconnect: connect: Connection refused
What version of MonetDB are you using? As far as I know, MonetDB should listen to port 50000 for all languages these days. One reason for your connection refuse can be that you connect to the hostname of your computer, instead of localhost (127.0.0.1). By default the server only listens on the local loopback interface.
Looking into the source code for the python client it should try to connect to port 45123, which the server is listening to. What it actually seems to do is connect to port 42312, but I have no idea why it does so (and hunting this down through several layers of generated code, one of which is swig, is no fun at all).
Weird.