Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 56162 - Correction to virt-mail-howto
Summary: Correction to virt-mail-howto
Status: RESOLVED FIXED
Alias: None
Product: [OLD] Docs-user
Classification: Unclassified
Component: Virtual-mail HOWTO (show other bugs)
Hardware: All All
: High normal (vote)
Assignee: Camille Huot (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-07-05 12:11 UTC by Sven Vermeulen (RETIRED)
Modified: 2004-07-28 01:40 UTC (History)
1 user (show)

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 Sven Vermeulen (RETIRED) gentoo-dev 2004-07-05 12:11:22 UTC
E-mail sent to www@gentoo.org by  Glen Hosking (glen(a)honeysplash-org):

"""
Hi,

in the last couple of weeks I have followed the guide located at
http://www.gentoo.org/doc/en/virt-mail-howto.xml  - "Virtual Mailhosting
System with Postfix".

I found that from the emerge/ebuild that I did, that sasl2 looks in
/usr/lib/sasl2/smtpd.conf  for its settings and NOT in
/etc/sasl2/smtpd.conf. The solution was to copy the smtpd.conf to the
correct directory. This was extremely difficult for me to troubleshoot
as there were no obvious errors, and sasl was just starting with its
default (whatever that is). I eventually found an indirect reference to
the location from a google search, made the change, and everything
started working.

The change/advice needs to be included in Section 4 - "4. Cyrus-sasl".
Hope this helps for anyone else having similar problems.

My version of sasl is:
*  dev-libs/cyrus-sasl
     Latest version available: 2.1.14
     Latest version installed: 2.1.14
     Size of downloaded files: 1,343 kB
     Homepage:    http://asg.web.cmu.edu/sasl/
     Description: The Cyrus SASL (Simple Authentication and Security Lay
     License:     as-is

Regards.

"""
Comment 1 Camille Huot (RETIRED) gentoo-dev 2004-07-28 01:40:48 UTC
An additionnal message from the initial reporter:

"""
Here is the output of running saslauthd (cyrus-sasl 2.1.14) in debug 
mode, attached to the terminal.
--- start ---
ocean init.d # /usr/sbin/saslauthd -a pam -d
saslauthd[32348] :main            : num_procs  : 5
saslauthd[32348] :main            : mech_option: NULL
saslauthd[32348] :main            : run_path   : /var/lib/sasl2
saslauthd[32348] :main            : auth_mech  : pam
saslauthd[32348] :ipc_init        : using accept lock file: 
/var/lib/sasl2/mux.accept
saslauthd[32348] :detach_tty      : master pid is: 0
saslauthd[32348] :ipc_init        : listening on socket: /var/lib/sasl2/mux
saslauthd[32348] :main            : using process model
saslauthd[32349] :get_accept_lock : acquired accept lock
saslauthd[32348] :have_baby       : forked child: 32349
saslauthd[32348] :have_baby       : forked child: 32350
saslauthd[32348] :have_baby       : forked child: 32351
saslauthd[32348] :have_baby       : forked child: 32352
--- end ---

The "run_path" is where it looks for  the smtpd.conf file, which is in 
/var/lib/sasl2.

Now, when I installed cyrus-sasl it didn't create a /var/lib/sasl2 
directory. I noticed there was a /usr/lib/sasl2 directory so I created a 
link to it. See following.

--- start ---
ocean init.d # cd /var/lib
ocean lib # ls -ld sasl2
lrwxrwxrwx  1 root root 14 Jun 20 22:25 sasl2 -> /usr/lib/sasl2
 --- end ---

There were also some changes I had to make to the /etc/conf.d/saslauthd 
file in order for "/etc/init.d/saslauthd start" to work

I just emerged cyrus-sasl 2.1.18-r2 and it has a fix for the 
/etc/conf.d/saslauthd file. I also found that in order for my email 
configuration to authenticate I had to include the "pam-mysql" parameter 
in the USE variable. When I did this it worked. The /etc/sasl2 did not 
exist with the 1.1.14 ebuild, but it exists now and has a copy of the 
smtpd.conf that I had in /usr/lib/sasl2. I renamed 
/usr/lib/sasl2/smtpd.conf to another name, restarted saslauthd and all 
is well. So my workaround of placing smtpd.conf in /usr/lib/sasl2 is no 
longer required.

So perhaps it was a bad e-build for cyrus-sasl 2.1.14 that was the 
problem. A very bad ebuild. Anyone following the instructions with the 
latest ebuild now just needs "pam-mysql" set.
"""

So everything is fixed. I Add "pam-mysql" in the USE flags list of the virt-mail-howto.xml doc.