[horde] Trying to setup MySql logging

Kevin Reed reedkm at comcast.net
Sun Nov 14 13:32:37 PST 2004


Hello.  I am using
Horde: 2.2.6
IMP: 3.2.1
Turba: 1.2.2
Kronolith: 1.1.2
Nag: 1.1.1

PHP: 4.3.9
Apache-AdvancedExtranetServer: 2.0.48
MySQL: 4.0.18

Each of the above works well, but now I am trying to set up logging via
mysql.
I have the following in the logging section of /horde/config/horde.php:

$conf['log']['enabled'] = true;
$conf['log']['type'] = 'sql';
$conf['log']['name'] = 'horde_log';
$conf['log']['priority'] = LOG_NOTICE;
$conf['log']['ident'] = 'HORDE';
$conf['log']['params'] = array();
$conf['log']['params']['username'] = 'horde';
$conf['log']['params']['password'] = 'my_horde_pass';
$conf['log']['params']['database'] = 'horde';
$conf['log']['params']['hostspec'] = 'localhost';

I created the table horde.horde_log with the following command (as listed in
my
/usr/share/pear/Log/sql.php):

CREATE TABLE horde_log (
 id          INT NOT NULL,
 logtime     TIMESTAMP NOT NULL,
 ident       CHAR(16) NOT NULL,
 priority    INT NOT NULL,
 message     VARCHAR(200),
 PRIMARY KEY (id)
);

The database user horde has SELECT, INSERT, UPDATE, DELETE, CREATE, DROP
privs on table horde_log

When I log in (using IMP for authentication), I get
"Notice: Undefined index: dsn in /usr/share/pear/Log/sql.php on line 117

Warning: Cannot modify header information - headers already sent by (output
started at /usr/share/pear/Log/sql.php:117) in
/var/www/html/horde/imp/redirect.php on line 103

Notice: (null)(): Mailbox is empty (errflg=1) in Unknown on line 0"

I am guessing that I need more log conf. params., although I have no idea
what is missing.
This error is not present when logging to a file, and mysql works with the
above apps except for logging.  Any ideas?






More information about the horde mailing list