Subject | Re: [firebird-support] Connecting to FB database with Kinterbasdb |
---|---|
Author | Uwe Grauer |
Post date | 2005-07-04T09:07:30Z |
Maurice Ling wrote:
Please make shure that what you try to do works in general.
Use isql to connect with the same params.
Does this work for you?
Uwe
> Hi,I never got problems with kinterbasdb.
>
> I've been using FB1.5 and access the database using Kinterbasdb +
> Python. My connection is established using kinterbasdb.connect() method
> and the parameters host, dns, database, user, password are all defaulted
> to 'None'.
>
> On my own machine running Mac OSX 10.3, I can connect using the following:
> host = 'localhost'
> database = '<my path to FB database>'
> user = '<user>'
> password = '<password>'
>
> At the same time, I can also connect if I set host=None on my machine.
>
> However, I cannot use 'localhost' on a shared Linux machine (not
> allowed. Don't ask why, system admin's mandate. And the Linux machine is
> without inetd). So when I set host=None, I get this error:
>
> Connecting to Muscopedia Database
> Connection:
> localhost:/mnt/disk/home/mling/muscorian/BioDatabases/muscopedia.fdb:mouse:mouse
>
> <-- default
> None <-- actual host (with 'print self.dbhost' where
> kinterbasdb.connect(host = self.dbhost,.....)
> OperationalError
> (-902, 'isc_attach_database: Unable to complete network request to host
> "localhost".. Failed to establish a connection.. Connection refused. ')
> File "muscorian.py", line 641, in main
> result = mosys.run(command)
>
> File "muscorian.py", line 597, in run
> elif (command[0] == 'linkmuscopedia'):
> self.commandLinkMuscopediaDB(command)
>
> File "muscorian.py", line 129, in commandLinkMuscopediaDB
> self.muscopedia = PubMedGrabber.FBUtilities(str(command[1]))
>
> File "abcrawl/PubMedGrabber.py", line 340, in __init__
> user = self.dbuser, password = self.dbpwd, charset='UNICODE_FSS')
>
> File "/usr/lib/python2.2/site-packages/kinterbasdb/__init__.py", line
> 470, in connect
> return Connection(*args, **keywords_args)
>
> File "/usr/lib/python2.2/site-packages/kinterbasdb/__init__.py", line
> 608, in __init__
> self._C_con = _k.attach_db(dsn, dpb, dialect)
>
> Has anyone got any ideas?
>
> Thanks
> Maurice
>
Please make shure that what you try to do works in general.
Use isql to connect with the same params.
Does this work for you?
Uwe