View Single Post
  #8  
Old 20th April 2013, 19:48
markc markc is offline
Member
 
Join Date: Dec 2012
Posts: 57
Thanks: 6
Thanked 9 Times in 9 Posts
Default

The next thing to check is this...

check_recipient_access mysql:/etc/postfix/mysql-virtual_recipient.cf

so add this to your /etc/mysql/my.cnf files under the [mysqld] sections...

general_log = 1
general_log_file = /var/log/mysql/mysql.log


and tail -f /var/log/mysql/mysql.log while a message comes in/ What you are looking for is the EXACT mysql query which is defined in the mysql-virtual_recipient.cf file (cat the file to see it).

Once you see the log entry for, say, postmaster then ctrl-c out of tailing the log file and at the prompt type...

mysql -e "PASTE THE ENTIRE QUERY FROM THE MYSQL LOG FILE HERE;"

and that will either successfuly return a correct lookup... or give you an error as to why it failed, which could be as simple as the server_id field being wrong.
Reply With Quote