From: Advo on
Hi there. I've been following a book to set up postfix, spamassassin
and amavis, but am having issues where im getting the error messages:

warning: connect to transport spamassassin: Connection refused and

fatal: parameter "smtpd_recipient_restrictions": specify at least one
working instance of: check_relay_domains, reject_unauth_destination,
reject, defer or defer_if_permit


I've included my config information, does anyone have any ideas please?


#############
master.cf
#############

smtp inet n - n - - smtpd
pickup fifo n - n 60 1 pickup
cleanup unix n - n - 0 cleanup
qmgr fifo n - n 300 1 qmgr
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
relay unix - - n - - smtp
showq unix n - n - - showq
error unix - - n - - error
local unix - n n - - local
virtual unix - n n - - virtual
lmtp unix - - n - - lmtp
anvil unix - - n - 1 anvil

maildrop unix - n n - - pipe
flags=DRhu user=daemon:mail argv=/usr/bin/maildrop -d ${recipient}
old-cyrus unix - n n - - pipe
flags=R user=cyrus argv=/cyrus/bin/deliver -e -m ${extension} ${user}
cyrus unix - n n - - pipe
user=cyrus argv=/cyrus/bin/deliver -e -r ${sender} -m ${extension}
${user}
uucp unix - n n - - pipe
flags=Fqhu user=uucp argv=uux -r -n -z -a$sender -
$nexthop!rmail.postfix ($recipient)
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

smtp-amavis unix - - y - 2 smtp
-o smtp_data_done_timeout=1200
-o disable_dns_lookups=yes

127.0.0.1:10025 inet n - y - - 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


################
main.cf
################

queue_directory = /var/spool/postfix

command_directory = /usr/sbin

daemon_directory = /usr/libexec/postfix

mail_owner = postfix


mydestination = $myhostname, localhost.$mydomain

unknown_local_recipient_reject_code = 450

mynetworks_style = host

alias_maps = hash:/etc/postfix/aliases

debug_peer_level = 2

debugger_command =
PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
ddd $daemon_directory/$process_name $process_id & sleep 5

sendmail_path = /usr/sbin/sendmail.postfix

newaliases_path = /usr/bin/newaliases.postfix

mailq_path = /usr/bin/mailq.postfix

setgid_group = postdrop

manpage_directory = /usr/share/man

sample_directory = /usr/share/doc/postfix-2.0.18/samples

readme_directory = /usr/share/doc/postfix-2.0.18/README_FILES
alias_database = hash:/etc/postfix/aliases

virtual_maps = hash:/etc/postfix/virtual
transport_maps = hash:/etc/postfix/transport
virtual_mailbox_domains = $transport_maps
local_destination_concurrency_limit=1
maildrop_destination_concurrency_limit=1
maildrop_destination_recipient_limit=1
relay_domains=$mydestination
smtpd_recipient_restrictions=permit_mynetworks,
permit_sasl_authenticated, reject_unauth_destination
smtpd_sasl_auth_enable=yes
smtpd_sasl_security_options=noanonymous

content_filter = smtp-amavis:[127.0.0.1]:10024


######################
postconf -n
######################


[root(a)localhost postfix]# postconf -n

alias_database = hash:/etc/postfix/aliases
alias_maps = hash:/etc/postfix/aliases
command_directory = /usr/sbin
config_directory = /etc/postfix
content_filter = smtp-amavis:[127.0.0.1]:10024
daemon_directory = /usr/libexec/postfix
debug_peer_level = 2
local_destination_concurrency_limit = 1
mail_owner = postfix
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
mydestination = $myhostname, localhost.$mydomain
mynetworks_style = host
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.0.18/README_FILES
relay_domains = $mydestination
sample_directory = /usr/share/doc/postfix-2.0.18/samples
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtpd_recipient_restrictions = permit_mynetworks,
permit_sasl_authenticated, reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
transport_maps = hash:/etc/postfix/transport
unknown_local_recipient_reject_code = 450
virtual_mailbox_domains = $transport_maps

From: Greg Hackney on
Advo wrote:

> fatal: parameter "smtpd_recipient_restrictions": specify at least one
> working instance of: check_relay_domains, reject_unauth_destination,
> reject, defer or defer_if_permit


In the master.cf file, you can't use whitespace between options
like you can in the main.cf file:

-o smtpd_recipient_restrictions=permit_mynetworks, reject
^
|

--
Greg
From: Advo on

Greg Hackney wrote:
> Advo wrote:
>
> > fatal: parameter "smtpd_recipient_restrictions": specify at least one
> > working instance of: check_relay_domains, reject_unauth_destination,
> > reject, defer or defer_if_permit
>
>
> In the master.cf file, you can't use whitespace between options
> like you can in the main.cf file:
>
> -o smtpd_recipient_restrictions=permit_mynetworks, reject
> ^
> |
>
> --
> Greg

i get what you mean, but i dont see what i should change.. if this is
my line of code:
-o smtpd_recipient_restrictions=permit_mynetworks, reject

what should it be?

-o smtpd_recipient_restrictions=permit_mynetworks,reject Removed the
space before reject?

From: Greg Hackney on
Advo wrote:

> i get what you mean, but i dont see what i should change.. if this is
> my line of code:
> -o smtpd_recipient_restrictions=permit_mynetworks, reject
>
> what should it be?
>
> -o smtpd_recipient_restrictions=permit_mynetworks,reject Removed the
> space before reject?

Yes

--
Greg

From: Advo on

Greg Hackney wrote:
> Advo wrote:
>
> > i get what you mean, but i dont see what i should change.. if this is
> > my line of code:
> > -o smtpd_recipient_restrictions=permit_mynetworks, reject
> >
> > what should it be?
> >
> > -o smtpd_recipient_restrictions=permit_mynetworks,reject Removed the
> > space before reject?
>
> Yes
>
> --
> Greg

done that, and am now getting messages like:

Oct 4 15:46:48 localhost postfix/smtp[21847]: warning: connect #1 to
subsystem private/scache: No such file or directory

delivery temporarily suspended: unknown mail transport error