Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 30642 - vpopmail does not recognize /etc/vpopmail.conf file
Summary: vpopmail does not recognize /etc/vpopmail.conf file
Status: VERIFIED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: All Linux
: High major (vote)
Assignee: Net-Mail Packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-10-08 01:57 UTC by Adam Bregenzer
Modified: 2003-10-08 15:42 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Adam Bregenzer 2003-10-08 01:57:57 UTC
I installed qmail, courier-imap, and vpopmail for virtual e-mail hosting. 
vpopmail-5.2.1-r5 worked fine, however when I upgraded to vpopmail-5.2.1-r7
e-mail stopped being delivered.  I looked at /var/log/qmail/qmail-send/current
and noticed the following error:

delivery 1: deferral:
could_not_connect_to_mysql_update_server_Access_denied_for_user:_'root@localhost'_(Using_password:_YES)_with_database/could_not_connect_to_mysql_update_server_Access_denied_for_user:_'root@localhost'_(Using_password:_YES)/

I was still able to add users and domains and see them being updated in the
MySQL database.  Also, I noticed that the username it mentioned in the error is
root, however the user in /etc/vpopmail.conf is vpopmail.  It seems the
vdelivermail application is not successfully using the mysql config file patch
for vpopmail.  I downloaded vpopmail-5.2.1, applied all patches but that patch,
manually set the database info in vmysql.h, used the following config options
(copied from the config used in the ebuild for vpopmail-5.32.1-r7):

./configure  --prefix=/usr --host=i686-pc-linux-gnu --mandir=/usr/share/man
--infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc
--localstatedir=/var/lib --enable-ip-alias-domains=n --enable-mysql=y
--enable-libs=/usr/include/mysql --enable-sqllibdir=/usr/lib/mysql
--enable-mysql-logging=y --enable-auth-logging=y --enable-valias=y
--enable-mysql-replication=n --enable-clear-passwd=y --sbindir=/usr/sbin
--bindir=/usr/bin --sysconfdir=/var/vpopmail/etc --enable-qmaildir=/var/qmail
--enable-qmail-newu=/var/qmail/bin/qmail-newu
--enable-qmail-inject=/var/qmail/bin/qmail-inject
--enable-qmail-newmrh=/var/qmail/bin/qmail-newmrh --enable-vpopuser=vpopmail
--enable-many-domains=y --enable-vpopgroup=vpopmail --enable-file-locking=y
--enable-file-sync=y --enable-md5-passwords=y
--enable-defaultquota=30000000,1000C --enable-roaming-users=y
--enable-relay-clear-minutes=60 --enable-tcprules-prog=/usr/bin/tcprules
--enable-tcpserver-file=/etc/tcp.smtp --enable-logging=y --enable-log-name=vpopmail

then did a make, make install-strip and manually setup the cron job.  After
doing that everything is working fine.  To the best of my knowledge the problem
is isolated down to the /usr/portage/distfiles/vpopmail-5.2.1-mysql.diff patch
not working for vdelivermail.
Here are my use flags and I do not have unstable enabled or anything in
/usr/local/portage

USE="apache2 berkdb clearpasswd crypt curl doc flash gd gdbm gpm imap ldap
maildir mcal memlimit mysql ncurses pam perl postgres python readline samba snmp
ssl tcltk tiff usb xml xml2 zlib -alsa -cups -gnome -gtk -kde -motif -X"

This was all done after doing an emerge sync and emerge -u world and was done on
the evening of Oct 7th.

Reproducible: Always
Steps to Reproduce:
1. install qmail (emerge qmail)
2. install vpopmail (emerge vpopmail)
3. install courier-imap (emerge courier-imap)
4. add a domain (vadddomain test.com)
5. add an account (adduser test@test.com)
6. send mail to the new user

Actual Results:  
The mail was not delivered and the above error was in
/var/log/qmail/qmail-send/current

Expected Results:  
delivered the mail to the user

I had apache2 and bind running as well.  I did have a proper /etc/tcp.smtp file
setup.  I can repeatedly uninstall qmail, vpopmail, courier-imap, delete
/var/qmail, /var/vpopmail, /var/log/qmail, /etc/vpopmail.conf, and
/etc/courier-imap and re-install everything from scratch and I have the same
exact error.
Comment 1 Adam Bregenzer 2003-10-08 01:58:35 UTC
I forgot my emerge info:
Portage 2.0.49-r3 (default-x86-1.4, gcc-3.2.3, glibc-2.3.2-r1, 2.4.22)
=================================================================
System uname: 2.4.22 i686 Pentium III (Coppermine)
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-mcpu=pentium3 -O3 -pipe"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /var/qmail/control /usr/share/config /usr/kde/2/share/config
/usr/kde/3/share/config /var/bind /usr/X11R6/lib/X11/xkb"
CONFIG_PROTECT_MASK="/etc/gconf /etc/afs/C /etc/afs/afsws /etc/env.d"
CXXFLAGS="-mcpu=pentium3 -O3 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="sandbox ccache autoaddcvs"
GENTOO_MIRRORS="ftp://ftp.gtlib.cc.gatech.edu/pub/gentoo ftp://ftp.ussg.iu.edu/pub/linux/gentoo
ftp://mirror.iawnet.sandia.gov/pub/gentoo/ ftp://sunsite.ualberta.ca/pub/unix/Linux/gentoo/
http://cs.ubishops.ca/pub/gentoo http://csociety-ftp.ecn.purdue.edu/pub/gentoo/
http://sunsite.ualberta.ca/pub/unix/Linux/gentoo/ http://www.ibiblio.org/gentoo
"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.us.gentoo.org/gentoo-portage"
USE="x86 oss apm arts avi encode foomaticdb gif imlib jpeg libg++ mad mikmod
mmx mpeg nls oggvorbis pdflib png quicktime sdl spell svga truetype xmms
xv slang java tcpd libwww qt opengl afs apache2 berkdb clearpasswd crypt
curl doc flash gd gdbm gpm imap ldap maildir mcal memlimit mysql ncurses
pam perl postgres python readline samba snmp ssl tcltk tiff usb xml xml2
zlib -alsa -cups -gnome -gtk -kde -motif -X"
Comment 2 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-10-08 13:18:23 UTC
what permissions and owner/group is on your /etc/vpopmail.conf and what user
does your qmail-send start vpopmail as?
Comment 3 Adam Bregenzer 2003-10-08 15:02:23 UTC
the file is owned by root.root and its permissions are 600

This was the problem. ;)
By chowning /etc/vpopmail.conf to vpopmail.vpopmail after emerging vpopmail
everything is working fine again.

Even though that should have been obvious to me it would be helpful if the
ebuild could do that when it creates the file.
Comment 4 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-10-08 15:27:31 UTC
fixed in CVS now.
proper permissions are asserted on the file in the new ebuild.
Comment 5 Adam Bregenzer 2003-10-08 15:42:09 UTC
Thank you, I'm sure others will be silently happy when vpopmail continues
to work "out of the box."