Incase it helps the mysql log shows the following: (note - sending the bounce to
brenton@anotherdomain.com.au works fine....)
# This I'm guessing is looking for an alias setting on the domain - there is none.
# So as expected it returns nothing:
54 Connect postfixadmin@localhost on postfix
54 Query SELECT target_domain FROM alias_domain WHERE alias_domain='localdomain.com.au'
# This returns the domain as expected to set the transport as virtual:
55 Connect postfixadmin@localhost on postfix
55 Query SELECT domain FROM domain where domain='localdomain.com.au' AND backupmx = '0' and active = '1' and transport = 'virtual'
# These queries return nothing:
56 Connect postfixadmin@localhost on postfix
56 Query SELECT domain FROM domain WHERE domain='localdomain.com.au' and transport = 'relay' and backupmx = '1'
56 Query SELECT domain FROM domain WHERE domain='.com.au' and transport = 'relay' and backupmx = '1'
56 Query SELECT domain FROM domain WHERE domain='.au' and transport = 'relay' and backupmx = '1'
# Now for some reason we look directly at the mailbox table and not the virtual_alias tables:
57 Connect postfixadmin@localhost on postfix
57 Query SELECT maildir FROM mailbox WHERE username='brenton2@localdomain.com.au'
57 Query SELECT maildir FROM mailbox WHERE username='@localdomain.com.au'
# Here Postfix bounces the message just fine:
58 Connect postfixadmin@localhost on postfix
58 Query SELECT goto FROM alias WHERE address='brenton@anotherdomain.com.au'
58 Query SELECT goto FROM alias WHERE address='brenton'
58 Query SELECT goto FROM alias WHERE address='@anotherdomain.com.au'
54 Query SELECT target_domain FROM alias_domain WHERE alias_domain='anotherdomain.com.au'
55 Query SELECT domain FROM domain where domain='anotherdomain.com.au' AND backupmx = '0' and active = '1' and transport = 'virtual'
56 Query SELECT domain FROM domain WHERE domain='anotherdomain.com.au' and transport = 'relay' and backupmx = '1'
Any clues are greatly appreciated.