Re: Help with pgsql dataset for SigningTable and KeyTable
 
On Mon, 28 Jun 2010, Naresh V wrote:
> [root_at_staging opendkim-2.1.1]# /etc/init.d/opendkim start
> Starting OpenDKIM Milter: opendkim: /etc/opendkim.conf:
> pgsql://opendkim_at_localhost/odkim/table=signingtable?keycol=fromheader?datacol=keyname:
> dkimf_db_open(): Success
> opendkim                                                   [FAILED]
It looks like error reporting from within dkimf_db_open() for the DSN case 
could use some improvement.
The "Success" comes from the fact that errno is 0 at that time.  This 
means an error was returned either because the syntax of the configuration 
line, or because the odbx library returned an error.  Unfortunately you 
can't tell which was the case just based on the error.
I can tell you that the syntax you have is slightly wrong.  For example, 
you have:
SigningTable   pgsql://opendkim_at_localhost/odkim/table=signingtable?keycol=fromheader?datacol=keyname
opendkim doesn't know that the odbx library below it supports pgsql, so at 
compile time, opendkim has no idea if "pgsql:" is a valid prefix or not. 
Instead, you should put "dsn:" in front of this, which tells opendkim that 
the remainder of the string should be passed to odbx as an open 
instruction.
So try this instead:
SigningTable   dsn:pgsql://opendkim_at_localhost/odkim/table=signingtable?keycol=fromheader?datacol=keyname
I will open a bug report that requests better logging detail from the 
database open function, as "Success" is clearly not helpful.
Received on Mon Jun 28 2010 - 16:02:54 PST
This archive was generated by hypermail 2.3.0
: Mon Oct 29 2012 - 23:19:47 PST