Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > HOWTO-Related Questions

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 12th May 2007, 14:24
nablaodel nablaodel is offline
Junior Member
 
Join Date: May 2007
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Ubuntu 7.04 + SASL Auth + MySQL

My problem is that I cannot authenticate through SASL against a MySQL database via Postfix to send mail SMTP(S). I have been trying to figure this out for over a week and have read many of the other posts without finding a solution. A couple days ago I started over with a fresh install.

I have installed Feisty Fawn server i386. I used Falko's "The Perfect Setup - Ubuntu Feisty Fawn" guide @ http://www.howtoforge.com/perfect_setup_ubuntu704 up until the point where the SSH server is installed.

Then I switched over to Falko's "Virtual Users And Domains With Postfix, Courier And MySQL (Ubuntu 6.10 Edgy Eft)" and I believed I followed everything in that guide to the 'T'. I have tested every part of the server and the only issue I have is that I cannot send mail (unless I use the command line).

The issue I have is most related to section http://www.howtoforge.com/virtual_po...ubuntu_edgy_p3

/etc/default/saslauthd, /etc/pam.d/smtp, /etc/postfix/sasl/smtpd.conf all seem to be correct (exact copies except my server info). I've tried numerous little changes and restarts/reloads. But nothing seems to work. Before I started changing things I made a backup of each file. I have reverted to those backups and done a system restart.

This is what /var/log/mail.log looks like after I try to send something via Thunderbird:
Code:
May 12 07:56:09 MY_SERVER postfix/master[5678]: reload configuration /etc/postfix
May 12 07:56:16 MY_SERVER postfix/smtpd[7776]: connect from REMOTE_COMPUTER_NAME[IPADDRESS]
May 12 07:56:19 MY_SERVER postfix/smtpd[7776]: warning: SASL authentication failure: cannot connect to saslauthd server: No such fi
le or directory
May 12 07:56:19 MY_SERVER postfix/smtpd[7776]: warning: SASL authentication failure: Password verification failed
May 12 07:56:19 MY_SERVER postfix/smtpd[7776]: warning: REMOTE_COMPUTER_NAME[IPADDRESS]: SASL PLAIN authentication f
ailed: generic failure
May 12 07:56:20 MY_SERVER postfix/smtpd[7776]: warning: SASL authentication failure: cannot connect to saslauthd server: No such fi
le or directory
May 12 07:56:20 MY_SERVER postfix/smtpd[7776]: warning: REMOTE_COMPUTER_NAME[IPADDRESS]: SASL LOGIN authentication f
ailed: generic failure
May 12 07:56:21 MY_SERVER postfix/smtpd[7776]: disconnect from REMOTE_COMPUTER_NAME[IPADDRESS]
I did look at the log after turning on verbose logging. Since that didn't seem to shed any light on my issue I won't bother posting that unless someone would like me to.

ps aux | grep saslauthd outputs:
Code:
root      7666  0.0  0.1   6464   748 ?        Ss   07:05   0:00 /usr/sbin/saslauthd -a pam
root      7667  0.0  0.0   6464   480 ?        S    07:05   0:00 /usr/sbin/saslauthd -a pam
root      7668  0.0  0.0   6464   464 ?        S    07:05   0:00 /usr/sbin/saslauthd -a pam
root      7671  0.0  0.0   6464   464 ?        S    07:05   0:00 /usr/sbin/saslauthd -a pam
root      7672  0.0  0.0   6464   464 ?        S    07:05   0:00 /usr/sbin/saslauthd -a pam
ewg       7795  0.0  0.1   2880   748 pts/0    R+   08:19   0:00 grep saslauthd
Since this has turned into a long post I will not display main.cf or master.cf unless someone thinks that would be helpful.

Let me know if you have any ideas. Thanks you very much!
Reply With Quote
Sponsored Links
  #2  
Old 12th May 2007, 14:36
nablaodel nablaodel is offline
Junior Member
 
Join Date: May 2007
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Solved

WOW!!! I feel so stupid yet happy!

After posting howtoforge listed similar threads and I had not read this one:
http://www.howtoforge.com/forums/showthread.php?t=12608

In /etc/default/saslauthd, commenting out
Code:
PARAMS="-m /var/spool/postfix/var/run/saslauthd -r"
and adding
Code:
OPTIONS="-c -m /var/spool/postfix/var/run/saslauthd -r"
Solved everything!
Reply With Quote
  #3  
Old 19th June 2007, 19:55
Aurora Aurora is offline
Junior Member
 
Join Date: Jun 2007
Location: U.S.A.
Posts: 2
Thanks: 0
Thanked 1 Time in 1 Post
 
Default

I had the same problem with saslauthd being unable to login for sending emails. I resolved it by editing the /etc/postfix/sasl/smtpd.conf file:

Change:
Quote:
sql_select: select password from users where email = '%u'
To:
Quote:
sql_select: SELECT password FROM users WHERE email = '%u'
Seems inconsequential, but it worked.
Reply With Quote
The Following User Says Thank You to Aurora For This Useful Post:
falko (20th June 2007)
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Perfect Setup Ubuntu 7.04: MySQL host password problem cheros HOWTO-Related Questions 6 10th January 2008 16:30
Virtual Users And Domains With Postfix (Ubuntu 6.10 Edgy Eft) - SASL errors zram21 HOWTO-Related Questions 1 10th May 2007 08:25
MySql on Ubuntu 6.06 LTS Server Bubo Server Operation 7 5th January 2007 16:23
postfix smtp sasl auth problem hammer Installation/Configuration 1 13th July 2006 18:19
Mandriva 10.2 Perfect Setup Install Problems... ctroyp Installation/Configuration 12 30th December 2005 16:04


All times are GMT +2. The time now is 19:56.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.