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 26th April 2008, 05:55
migm migm is offline
Junior Member
 
Join Date: Apr 2008
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default Cannot connect to saslauthd server: Permission denied

Hi all,

I saw the other thread on this (chmod 777 .... and so on) and that did not work. I am still getting this error. Here's my postfix configuration (main.cfg). Please let me know what other information I can provide: there's obviously a permissions problems here but I thought saslauthd ran as root.

Code:
# See /usr/share/postfix/main.cf.dist for a commented, more complete version

# Debian specific:  Specifying a file name will cause the first
# line of that file to be used as the name.  The Debian default
# is /etc/mailname.
#myorigin = /etc/mailname

smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no

# appending .domain is the MUA's job.
append_dot_mydomain = no

# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h

# TLS parameters
smtpd_tls_cert_file = /etc/postfix/ssl/smtpd.crt
smtpd_tls_key_file = /etc/postfix/ssl/smtpd.key
smtpd_use_tls = yes
smtpd_tls_session_cache_database = btree:${queue_directory}/smtpd_scache
smtp_tls_session_cache_database = btree:${queue_directory}/smtp_scache

# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
# information on enabling SSL in the smtp client.

myhostname = tcc1.ath.cx
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
myorigin = /etc/mailname
mydestination = tcc1.ath.cx, ubuntu, localhost.localdomain, localhost
relayhost = [smtp.att.yahoo.com]:587
mynetworks = 0.0.0.0/0
mailbox_size_limit = 0
recipient_delimiter = +
home_mailbox = Maildir/
mailbox_command = procmail -a "$EXTENSION"

smtpd_sasl_local_domain =
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions = permit_sasl_authenticated,permit_mynetworks,reject_unauth_destination
inet_interfaces = all
smtpd_tls_auth_only = no
smtp_use_tls = yes
smtp_tls_note_starttls_offer = yes
smtpd_tls_CAfile = /etc/postfix/ssl/cacert.pem
smtpd_tls_loglevel = 1
smtpd_tls_received_header = yes
smtpd_tls_session_cache_timeout = 3600s
tls_random_source = dev:/dev/urandom
Thanks in advance for any and all help!
Cheers,
Migm
Reply With Quote
Sponsored Links
  #2  
Old 26th April 2008, 15:14
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,751 Times in 2,581 Posts
Default

Please run
Code:
adduser postfix sasl
/etc/init.d/postfix restart
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 26th April 2008, 18:58
migm migm is offline
Junior Member
 
Join Date: Apr 2008
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by falko
Please run
Code:
adduser postfix sasl
/etc/init.d/postfix restart

Thanks for your help. I had already tried this still getting the following
Code:
Apr 26 10:55:19 tcc1 postfix/smtpd[21126]: warning: SASL authentication failure: cannot connect to saslauthd server: Permission denied
Apr 26 10:55:19 tcc1 postfix/smtpd[21126]: warning: SASL authentication failure: Password verification failed
Apr 26 10:55:19 tcc1 postfix/smtpd[21126]: warning: maxlaptop.local[192.168.1.2]: SASL PLAIN authentication failed: generic failure
passwd file
Code:
postfix:x:110:120::/var/spool/postfix:/bin/false
groups file
Code:
sasl:x:1001:postfix
Reply With Quote
  #4  
Old 27th April 2008, 01:38
migm migm is offline
Junior Member
 
Join Date: Apr 2008
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Well, i got it to work, but I am not confident that my methodology was very secure.

I ran smtpd with strace debugging turned on and saw the reason that things weren't working was that postfix was searching for my saslauthd file in /var/run/saslauthd. The only mention of the /var/run directory i saw was in the saslauthd init.d file, which i changed to reflect the /var/spool/postfix/var/run/saslauthd directory. That didn't work, so I ended up copying and linking all the files necessary from the /spool directory into the /var/run/saslauthd directory. I can't imagine this is terribly secure?

Where is postfix pulling this /var/run directory from, anyway? If i can change that, I'd rather delete what I've done and do it the correct way.

Thanks!

migm
Reply With Quote
  #5  
Old 27th April 2008, 20:36
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,751 Times in 2,581 Posts
Default

Postfix is running chrooted, so /var/run translates to /var/spool/postfix/var/run.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #6  
Old 27th April 2008, 22:13
migm migm is offline
Junior Member
 
Join Date: Apr 2008
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by falko
Postfix is running chrooted, so /var/run translates to /var/spool/postfix/var/run.
My postfix was actually not chrooted in the master.cfg
Reply With Quote
  #7  
Old 13th June 2009, 16:03
bvidinli bvidinli is offline
Junior Member
 
Join Date: Sep 2005
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

i found a basic solution described here: http://www.ehcp.net/?q=node/149#comment-668
Reply With Quote
  #8  
Old 22nd July 2009, 17:39
anony anony is offline
Junior Member
 
Join Date: Jul 2009
Posts: 2
Thanks: 0
Thanked 2 Times in 1 Post
Default

"Cannot connect to saslauthd server: Permission denied" was caused by permission errors for me. Changed /var/run/saslauthd permissions, chmod a+rx and things worked.

Postfix was not chroot'd and there was no group for saslauthd to add Postfix.
Reply With Quote
  #9  
Old 4th October 2009, 14:12
zzattack zzattack is offline
Junior Member
 
Join Date: Feb 2009
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by falko View Post
Please run
Code:
adduser postfix sasl
/etc/init.d/postfix restart
Thanks, this worked for me
Reply With Quote
  #10  
Old 20th February 2011, 04:18
adig adig is offline
Junior Member
 
Join Date: Feb 2011
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
 
Default password

For those that all of the above doesn't solve the problem... check your password!

If it has a '#' sign all that is after the # gets ignored in "/etc/pam.d
/smtp" and therefore you will have these nice errors in /var/log/auth.log :

pam_mysql - required option "db" is not set
DEBUG: auth_pam: pam_authenticate failed: Error in service module

Source: here.
Reply With Quote
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
Getting e-mail working hansoffate Installation/Configuration 29 13th August 2008 17:33
debian etch courier pop3 issue docean Installation/Configuration 6 20th March 2008 16:38
Problems with Postfix Mysql Courier PatrickAdrichem Installation/Configuration 3 13th April 2007 16:44
mail log nvn Installation/Configuration 17 9th November 2006 10:50
Primary & secondary DNS-Server Problems: permission denied Pasco Installation/Configuration 10 21st July 2006 13:46


All times are GMT +2. The time now is 18:11.


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