I have just installed qpopper with the mysql patch on my CentOS 5.5 server and am having a problem querying the database. I've had this working on various other linux servers without any problem. If I query the default database it works but if I query one of the virtual database it fails.

When I telnet to the default database it works:
telnet localhost 110
popper[26256]: (v4.0.18-mysql-0.16) Servicing request from "server.domain.com" at 127.0.0.1+OK ready
User exampleuser
+OK Password required for exampleuser.
Pass examplepass
+OK exampleuser has 0 visible messages (0 hidden) in 0 octets

However, if I telnet to a virtual database it fails:
telnet localhost 110
popper[26256]: (v4.0.18-mysql-0.16) Servicing request from "server.domain.com" at 127.0.0.1+OK ready
User exampleu...@differentdomain.com
<21>Sep 14 13:59:54 popper[25647]: example...@differentdomain.com: ERROR: sql query fetch row failed () User may not exist+OK Password required forexampleuse.
NOTE:Missing letter "r" at the end of UserID.

The query seems to chop off the last letter of the UserId when I use @domain.com

**********************************************

Additional information regarding the set up.

-Mysql 5.1.50 tarball
./configure \
--prefix=/usr/local/mysql \
--disable-maintainer-mode \
--with-mysqld-user=mysql \
--with-unix-socket-path=/tmp/mysql.sock \
--without-comment \
--without-debug \
--without-bench

This is the same database that I've been using for years and earlier versions of qpopper have always worked.

I inserted a test user/domain.

[QUOTE]mysql> INSERT INTO radcheck (id, UserName, attribute, value, uid, gid,domain, alias, is_alias, net_id) VALUES ('999', 'exampleuser', '', 'test','500', '12', 'differentdomain.com', '', 'no', 'exampleuser');
Query OK, 1 row affected (0.03 sec)[/QUOTE]

When I log on to the database all looks fine:
mysql> select * from radcheck where net_id = 'exampleuser';
+-----+----------+-----------+-------+-----+-----+-------------+-------+----------+---------+
| id | UserName | attribute | value | uid | gid | domain | alias | is_alias | net_id |
+-----+----------+-----------+-------+-----+-----+-------------+-------+----------+---------+
| 999 | exampleuser | | test | 500 | 12 | differentdomain.com | | no | exampleuser |
+-----+----------+-----------+-------+-----+-----+-------------+-------+----------+---------+
1 row in set (0.00 sec)

I granted mailadmin full permission.

[QUOTE]> grant all privileges on radius.* to 'mailadmin'@'localhost' identified by 'secret';

>flush privileges;[/QUOTE]



I download Qpopper qpopper4.0.19.tar.gz (this is the version mysql patch was written for) and the patch qpopper3.1.2-mysql-0.1.patch. I patched it (no errors) and compiled/made it (no errors).

./configure  \
--with-mysqlconfig=/etc/mysql-popper.conf  \
--enable-mysql  \
--with-mysqllibpath=/usr/local/mysql/lib/mysql  \
--with-mysqlincludepath=/usr/local/mysql/include/mysql  \
--enable-standalone  \
--enable-shy  \
--enable-servermode

This is a copy of mysql-popper.conf
[QUOTE]MysqlAuthHost localhost
MyslAuthPort 3306
MysqlAuthDb radius
MysqlAuthTable radcheck
MysqlAuthUsername mailadmin
MysqlAuthPassword secret
MysqlAuthUsernameField username
MysqlAuthPasswordField value
MysqlAuthDomainField domain
MysqlAuthAliasField alias
AliasField is_alias
MysqlAuthAliasNo no
MysqlAuthPasswordMethod both
MysqlAuthDefaultDomain domain.com
MysqlAuthUIDField uid
MysqlAuthGIDField gid
MysqlAuthUID mail
MysqlAuthGID mail
POP_MAILDIR /var/spool/virtual_mail[/QUOTE]

This set up has always worked for me in the past but it isn't working with the new qpopper/patch. As I mentioned, it is chopping the last letter off the UserID. I've dug through the logs but couldn't find anything that would point me in the right direction. Any advice on how to solve this would be greatly appreciated.

All the best
Fred

--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

Reply via email to