LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 02-10-2011, 01:40 AM   #1
sohailkmu
Member
 
Registered: Oct 2008
Posts: 82
Blog Entries: 1

Rep: Reputation: 15
problem with sending mail in postfix


Dear All,


I have configured postfix on centos 5.5. When I compose a mail through squirrel mail. Nothing happens and the browswer just shows that wating for ------/webmail/src/-----. No error message appears even.

My log file is a given below:

Feb 10 14:09:51 its postfix/smtpd[19334]: fatal: parameter "smtpd_recipient_restrictions": specify at least one working instance of: check_relay_domains, reject_unauth_destination, reject, defer or defer_if_permit



Kindly help me

Last edited by sohailkmu; 02-10-2011 at 03:09 AM.
 
Old 02-10-2011, 04:32 AM   #2
Noway2
Senior Member
 
Registered: Jul 2007
Distribution: Gentoo
Posts: 2,125

Rep: Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781
"smtpd_recipient_restrictions" is one of the configuration parameters in your /etc/postfix/main.cf file. It looks like you have a syntax error in this file. Most configurations I have seen put multiple restrictions on separate lines. The different restrictions are on a line by themselves with whitespace at the start of the line. For example:
Code:
smtpd_recipient_restrictions =
   permit_mynetworks
   permit_sasl_authenticated
   permit_mx_backup
   reject_unauth_destination
   reject_unknown_recipient_domain
   check_policy_service inet:127.0.0.1:60000
   permit
When you attempt to start/restart postfix as a service you should see error messages in syslog and or mail.log. An error message like this one should show up at that time and prevent postfix from even starting.
 
Old 02-12-2011, 01:36 AM   #3
sohailkmu
Member
 
Registered: Oct 2008
Posts: 82

Original Poster
Blog Entries: 1

Rep: Reputation: 15
Quote:
Originally Posted by Noway2 View Post
"smtpd_recipient_restrictions" is one of the configuration parameters in your /etc/postfix/main.cf file. It looks like you have a syntax error in this file. Most configurations I have seen put multiple restrictions on separate lines. The different restrictions are on a line by themselves with whitespace at the start of the line. For example:
Code:
smtpd_recipient_restrictions =
   permit_mynetworks
   permit_sasl_authenticated
   permit_mx_backup
   reject_unauth_destination
   reject_unknown_recipient_domain
   check_policy_service inet:127.0.0.1:60000
   permit
When you attempt to start/restart postfix as a service you should see error messages in syslog and or mail.log. An error message like this one should show up at that time and prevent postfix from even starting.

My error messages are now:

Feb 12 12:36:52 its postfix/qmgr[2900]: warning: connect to transport smtp-amavis: No such file or directory
Feb 12 12:36:59 its postfix/smtpd[7178]: fatal: /etc/postfix/main.cf, line 685: missing '=' after attribute name: "check_policy_service inet:127.0.0.1:60000"
Feb 12 12:37:00 its postfix/master[2882]: warning: process /usr/libexec/postfix/smtpd pid 7178 exit status 1
Feb 12 12:37:00 its postfix/master[2882]: warning: /usr/libexec/postfix/smtpd: bad command startup -- throttling
 
Old 02-13-2011, 07:33 AM   #4
Noway2
Senior Member
 
Registered: Jul 2007
Distribution: Gentoo
Posts: 2,125

Rep: Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781
You have at least two errors in your configuration file(s) and these are keeping postfix from starting. Note, the check_policy_service line is for postgrey and if you are not using that filtering application you don't need it. I am not sure why it is complaining about missing the = sign, though, which does sound like a syntax or hidden character error.

The amavis-transport error looks more critical. Do you have amavis installed? Is it running and listening on the appropriate port? With amavis, you configure your master.cf file such that mail is first delivered to amavis on one port, e.g. 10024, it is processed and then re-injected into the queue on another port, eg. 10025. The error "warning: connect to transport smtp-amavis: No such file or directory" suggests that you have something misconfigured in your master.cf.

Check these files really closely.

Did you follow a particular how to document for setting this up? If so, if you copy text from them you can get bad characters such as ` instead of ' which can cause A LOT of problems.
 
Old 03-04-2011, 05:55 AM   #5
rytec
Member
 
Registered: Mar 2009
Location: Belgium
Distribution: Ubuntu server 12.04 LTS / Raspbian Wheezy
Posts: 64

Rep: Reputation: 7
I have also a question about this Amavis.
This morning after I rebooted my server and after I have noticed that people asked me that they did not receive my mails I started looking into the logfiles of mail.
Then I saw that postfix/smtp could not connect to port 10024. I was not aware directly this was Amavis.
So after some googling I recognized things and yes Amavis was not running because of an error.
Now where can I activate some kind of notification when I send mails and this happens again, I directly get notified of mails that aren't sent? Is it in the main.cf I have to add something or is it else?

I already have this active :
bounce_notice_recipient = postmaster
2bounce_notice_recipient = postmaster
notify_classes = bounce, 2bounce, resource, software, protocol, delay

but still get no message to postmaster of amavis or content filter is not running.

NOTE! I realise now that if amavisd is not running it's not possible to send any mail beside if I could run a script which bypasses the 10024 port and goes strait to postfix

Last edited by rytec; 03-04-2011 at 06:36 AM. Reason: extra information
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Postfix Problem Sending SMTP Mail j.smith1981 Linux - Server 2 10-27-2010 09:51 PM
Sending mail with mail() and postfix when using namecheap's DNS and Email Hosting iLinx Linux - Server 2 07-19-2010 05:53 PM
Mail sending problem – Postfix Connection timed out (port 25) malesh Linux - Server 3 03-20-2009 05:39 PM
Postfix sending mail outside guy_ripper Linux - Server 1 05-17-2008 10:25 AM
Postfix mail transfer agent not sending mail locally or to other servers sketelsen Linux - Software 3 02-09-2006 11:16 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 02:29 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration