Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 9th February 2010, 05:04
CarbonCopy CarbonCopy is offline
Member
 
Join Date: Apr 2009
Posts: 52
Thanks: 1
Thanked 2 Times in 2 Posts
Default Postfix and Courier not sending/recieving but logging in?

I made some changes to my server today, changing directory permissions and deleting some directories and old files. No I didn't keep any record of what changes I did.

However, now Postfix and Courier Imap allow me to login, and send/check for emails. However, Postfix won't sent to external or internal emails, and Courier won't receive internal emails or external emails. I'm at a loss. I have tried everything I can think of, and more.

Recompiling Courier or Postfix would be a last resort as it isn't guarenteed to fix it, and it is very difficult to setup properly (I am using Virtual users with MySQL).

I haven't changed any of my configuration for these two programs. Here is some of the contents of /var/log/maillog

Code:
Feb  8 20:03:33 cl-t112-271cl master[633]: fatal: master_spawn: exec /usr/libexec/postfix/smtps: No such file or directory
Feb  8 20:03:33 cl-t112-271cl postfix/qmgr[632]: 8B1CA850098: from=<brandon.wamboldt@northernlightstechnology.ca>, size=1006, nrcpt=1 (queue active)
Feb  8 20:03:33 cl-t112-271cl postfix/qmgr[632]: 0004E85008F: from=<brandon.wamboldt@northernlightstechnology.ca>, size=973, nrcpt=1 (queue active)
Feb  8 20:04:34 cl-t112-271cl master[686]: fatal: master_spawn: exec /usr/libexec/postfix/smtps: No such file or directory
Feb  8 20:04:35 cl-t112-271cl postfix/master[630]: warning: process /usr/libexec/postfix/smtps pid 686 exit status 1
Feb  8 20:04:35 cl-t112-271cl postfix/master[630]: warning: /usr/libexec/postfix/smtps: bad command startup -- throttling
The rest looks like ordinary log files, nothing that is important. Any other configuration can be posted. Here is my main.cf and master.cf files

main.cf
Code:
#virtual_minimum_uid
#debugger_command =
#         /usr/bin/strace -s1024 -o /tmp/trace -p $process_id &


# Some server info
myhostname = smtp.northernlightstech.com
mydestination = smtp.northernlightstech.com, localhost, localhost.localdomain
mynetworks = 127.0.0.0/8
message_size_limit = 30720000

# This is to setup virtual domains and users
virtual_alias_domains =
virtual_alias_maps = proxy:mysql:/etc/postfix/mysql-virtual_forwardings.cf, mysql:/etc/postfix/mysql-virtual_email2email.cf
virtual_mailbox_domains = proxy:mysql:/etc/postfix/mysql-virtual_domains.cf
virtual_mailbox_maps = proxy:mysql:/etc/postfix/mysql-virtual_mailboxes.cf
virtual_mailbox_base = /home/vmail
virtual_uid_maps = static:5000
virtual_gid_maps = static:5000

# This is authentication related
smtpd_sasl_auth_enable = yes
broken_sasl_auth_clients = yes
smtpd_sasl_authenticated_header = yes
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination

# Use TLS
smtpd_use_tls = yes
smtpd_tls_cert_file = /etc/postfix/smtpd.pem
smtpd_tls_key_file = /etc/postfix/smtpd.pem
smtpd_tls_CAfile = /etc/postfix/smtpd.pem


# Some more virtual user stuff
transport_maps = proxy:mysql:/etc/postfix/mysql-virtual_transports.cf
virtual_transport = maildrop
maildrop_destination_recipient_limit = 1

virtual_create_maildirsize = yes
virtual_maildir_extended = yes
virtual_mailbox_limit_maps = proxy:mysql:/etc/postfix/mysql-virtual_mailbox_limit_maps.cf
virtual_mailbox_limit_override = yes
virtual_maildir_limit_message = "The user you are trying to reach is over quota."
virtual_overquota_bounce = yes
#proxy_read_maps = $mydestination $virtual_alias_maps $virtual_alias_domains $virtual_mailbox_maps $virtual_mailbox_domains $relay_recipient_maps $relay_domains $canonical_maps $sender_$
proxy_read_maps = $local_recipient_maps $mydestination $virtual_alias_maps $virtual_alias_domains $virtual_mailbox_maps $virtual_mailbox_domains $relay_recipient_maps $relay_domains $canonical_maps $sender_$

####### ANTI SPAM/VIRUS/WORM SETTINGS #######
smtpd_delay_reject = yes
#smtpd_helo_required = yes
#smtpd_helo_restrictions = permit_mynetworks, reject_non_fqdn_hostname, reject_invalid_hostname, permit
#smtpd_sender_restrictions = permit_sasl_authenticated, permit_mynetworks, reject_non_fqdn_sender, reject_unknown_sender_domain, permit


smtpd_recipient_restrictions =
  reject_unauth_pipelining,
#  reject_non_fqdn_recipient,
  reject_unknown_recipient_domain,
  permit_mynetworks,
  permit_sasl_authenticated,
  reject_unauth_destination,
  permit
content_filter = amavis:[127.0.0.1]:10024
receive_override_options = no_address_mappings
readme_directory = /usr/share/doc/postfix-2.3.3/README_FILES
sample_directory = /usr/share/doc/postfix-2.3.3/samples
sendmail_path = /usr/sbin/sendmail
html_directory = no
setgid_group = postdrop
command_directory = /usr/sbin
manpage_directory = /usr/share/man
daemon_directory = /usr/libexec/postfix
newaliases_path = /usr/bin/newaliases
mailq_path = /usr/bin/mailq
queue_directory = /var/spool/postfix
mail_owner = postfix
unknown_local_recipient_reject_code = 450
smtpd_sasl_path = smtpd
smtpd_sasl_type = cyrus
smtpd_sasl_security_options = noanonymous

data_directory = /var/lib/postfix
master.cf
Code:
#
# Postfix master process configuration file.  For details on the format
# of the file, see the master(5) manual page (command: "man 5 master").
#
# ==========================================================================
# service type  private unpriv  chroot  wakeup  maxproc command + args
#               (yes)   (yes)   (yes)   (never) (100)
# ==========================================================================
#smtp      inet  n       -       n       -       -       smtpd
smtp       inet  n       -       n       -       -       smtpd
smtps      inet  n       -       n       -       -       smtpd -o smtpd_tls_wrappermode=yes -o smtpd_sasl_auth_enable=yes
26         inet  n       -       n       -       -       smtpd

#submission inet n       -       n       -       -       smtpd
#  -o smtpd_enforce_tls=yes
#  -o smtpd_sasl_auth_enable=yes
#  -o smtpd_client_restrictions=permit_sasl_authenticated,reject
#smtps     inet  n       -       n       -       -       smtpd
#  -o smtpd_tls_wrappermode=yes
#  -o smtpd_sasl_auth_enable=yes
#  -o smtpd_client_restrictions=permit_sasl_authenticated,reject
#628      inet  n       -       n       -       -       qmqpd
pickup    fifo  n       -       n       60      1       pickup
cleanup   unix  n       -       n       -       0       cleanup
qmgr      fifo  n       -       n       300     1       qmgr
#qmgr     fifo  n       -       n       300     1       oqmgr
tlsmgr    unix  -       -       n       1000?   1       tlsmgr
rewrite   unix  -       -       n       -       -       trivial-rewrite
bounce    unix  -       -       n       -       0       bounce
defer     unix  -       -       n       -       0       bounce
trace     unix  -       -       n       -       0       bounce
verify    unix  -       -       n       -       1       verify
flush     unix  n       -       n       1000?   0       flush
proxymap  unix  -       -       n       -       -       proxymap
smtp      unix  -       -       n       -       -       smtp
# When relaying mail as backup MX, disable fallback_relay to avoid MX loops
relay     unix  -       -       n       -       -       smtp
        -o fallback_relay=
#       -o smtp_helo_timeout=5 -o smtp_connect_timeout=5
showq     unix  n       -       n       -       -       showq
error     unix  -       -       n       -       -       error
discard   unix  -       -       n       -       -       discard
local     unix  -       n       n       -       -       local
virtual   unix  -       n       n       -       -       virtual
lmtp      unix  -       -       n       -       -       lmtp
anvil     unix  -       -       n       -       1       anvil
scache    unix  -       -       n       -       1       scache
#
# ====================================================================
# Interfaces to non-Postfix software. Be sure to examine the manual
# pages of the non-Postfix software to find out what options it wants.
#
# Many of the following services use the Postfix pipe(8) delivery
# agent.  See the pipe(8) man page for information about ${recipient}
# and other message envelope options.
# ====================================================================
#
# maildrop. See the Postfix MAILDROP_README file for details.
# Also specify in main.cf: maildrop_destination_recipient_limit=1
#
#maildrop  unix  -       n       n       -       -       pipe
#  flags=ODRhu user=vmail argv=/usr/local/bin/maildrop -d ${recipient}


maildrop unix - n n - - pipe
  flags=DRhu user=vmail argv=/usr/local/bin/maildrop /etc/maildroprc -d ${user}@${nexthop} ${extension} ${recipient} ${user} ${nexthop} ${sender}




#
# The Cyrus deliver program has changed incompatibly, multiple times.
#
old-cyrus unix  -       n       n       -       -       pipe
  flags=R user=cyrus argv=/usr/lib/cyrus-imapd/deliver -e -m ${extension} ${user}
# Cyrus 2.1.5 (Amos Gouaux)
# Also specify in main.cf: cyrus_destination_recipient_limit=1
cyrus     unix  -       n       n       -       -       pipe
  user=cyrus argv=/usr/lib/cyrus-imapd/deliver -e -r ${sender} -m ${extension} ${user}
#
# See the Postfix UUCP_README file for configuration details.
#
uucp      unix  -       n       n       -       -       pipe
  flags=Fqhu user=uucp argv=uux -r -n -z -a$sender - $nexthop!rmail ($recipient)
#
# Other external delivery methods.
#
ifmail    unix  -       n       n       -       -       pipe
  flags=F user=ftn argv=/usr/lib/ifmail/ifmail -r $nexthop ($recipient)
bsmtp     unix  -       n       n       -       -       pipe
  flags=Fq. user=foo argv=/usr/local/sbin/bsmtp -f $sender $nexthop $recipient

#amavis unix - - - - 2 smtp
#        -o smtp_data_done_timeout=1200
#        -o smtp_send_xforward_command=yes

amavis unix - - - - 2 smtps
       -o smtp_data_done_timeout=1200
       -o smtp_send_xforward_command=yes

127.0.0.1:10025 inet n - - - - smtpd
        -o content_filter=
        -o local_recipient_maps=
        -o relay_recipient_maps=
        -o smtpd_restriction_classes=
        -o smtpd_client_restrictions=
        -o smtpd_helo_restrictions=
        -o smtpd_sender_restrictions=
        -o smtpd_recipient_restrictions=permit_mynetworks,reject
        -o mynetworks=127.0.0.0/8
        -o strict_rfc821_envelopes=yes
        -o receive_override_options=no_unknown_recipient_checks,no_header_body_checks
        -o smtpd_bind_address=127.0.0.1

retry     unix  -       -       n       -       -       error
proxywrite unix -       -       n       -       1       proxymap
Reply With Quote
Sponsored Links
  #2  
Old 9th February 2010, 05:11
CarbonCopy CarbonCopy is offline
Member
 
Join Date: Apr 2009
Posts: 52
Thanks: 1
Thanked 2 Times in 2 Posts
Default

Looks like I was wrong, Postfix is receiving emails, I am just not getting them or something.

Code:
Feb  8 20:03:33 cl-t112-271cl postfix/qmgr[632]: 6B122850083: from=<info@designbygraduates.com>, size=21633, nrcpt=1 (queue active)
Reply With Quote
  #3  
Old 9th February 2010, 05:54
CarbonCopy CarbonCopy is offline
Member
 
Join Date: Apr 2009
Posts: 52
Thanks: 1
Thanked 2 Times in 2 Posts
Default

I just remembered while reading some similar posts that I deleted like a hosts.allow_orig and hosts.deny.old file. Are these important?
Reply With Quote
  #4  
Old 9th February 2010, 14:12
CarbonCopy CarbonCopy is offline
Member
 
Join Date: Apr 2009
Posts: 52
Thanks: 1
Thanked 2 Times in 2 Posts
Default

I've reinstalled Courier-Authlib, Courier-Imap, and Postfix. I can still connect fine, but still cannot send or receive email. I think it has to do with the line

Code:
Feb  9 05:37:35 cl-t112-271cl master[13121]: fatal: master_spawn: exec /usr/libexec/postfix/smtps: No such file or directory
Feb  9 06:45:29 cl-t112-271cl postfix/smtpd[20634]: sql_select option missing
Feb  9 06:45:29 cl-t112-271cl postfix/smtpd[20634]: auxpropfunc error no mechanism available
I get the smtps error even when SSL/TLS is disabled

Last edited by CarbonCopy; 9th February 2010 at 15:24.
Reply With Quote
  #5  
Old 9th February 2010, 15:36
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,749 Times in 2,579 Posts
Default

Which distribution do you use?
__________________
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 9th February 2010, 15:38
CarbonCopy CarbonCopy is offline
Member
 
Join Date: Apr 2009
Posts: 52
Thanks: 1
Thanked 2 Times in 2 Posts
Default

CentOs 5.3 i386, and steps from http://howtoforge.com/virtual-users-...ysql-centos5.1

And my mail queue gets mail in it, even after restarting it doesn't send

And could this have to do with file permissions? I changed a few of them. And I also disabled aquota, which I maybe shouldn't of since postfix has the quota patch

EDIT: Just reenabled aquota and still no luck

Last edited by CarbonCopy; 9th February 2010 at 15:50.
Reply With Quote
  #7  
Old 10th February 2010, 14:49
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,749 Times in 2,579 Posts
 
Default

I guess the following line in /etc/postfix/master.cf causes the problem:
Code:
smtps      inet  n       -       n       -       -       smtpd -o smtpd_tls_wrappermode=yes -o smtpd_sasl_auth_enable=yes
Please comment it out and restart Postfix. Do you still get errors then?
__________________
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
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
Virtual Users And Domains With Postfix, Courier, MySQL And SquirrelMail (Ubuntu 8.10) VTCop HOWTO-Related Questions 9 9th April 2009 17:17
Virtual Users With Postfix, PostfixAdmin, Courier, Mailscanner,Mailwatch CentOS 5.2 tecstream HOWTO-Related Questions 3 16th July 2008 23:10
Issues with Postfix using "Virtual Users And Domains With Postfix, Courier And MySQL" Kyse HOWTO-Related Questions 15 6th January 2007 16:35
Upgrade question for "Virtual Users And Domains With Postfix, Courier And MySQL" emresumengen HOWTO-Related Questions 3 1st December 2006 16:33
Virtual Users And Domains With Postfix, Courier And MySQL - "apt-get" and Courier burritonator HOWTO-Related Questions 3 15th March 2006 21:11


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


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