![]() |
postfix trying to use root to log onto mysql
I've been trying to set up a mail server on a rackspace CentOS 6 cloud server for the past couple days. I've followed your tutorial to a tee with the exception that I didn't compile a new postfix with quota as I don't need a quota system.
Everything seemed to install perfectly, I did have to install some extra packages that weren't listed. But everything seemed to go well. The issue I'm having is that I'm not able to send any mail (I haven't even tried receiving yet..). After looking at the maillog I can see that postfix gives me the error: postfix/cleanup[31896]: warning: connect to mysql server 127.0.0.1: Access denied for user 'root'@'localhost' (using password: YES) So, I'm guessing that postfix isn't using the .cf files I created with the proper user and password. I've triple checked all the files. The permissions are set properly, the vmail user is correct, mysql lets me log in with the mailadmin user and password, the aliases are set as you've listed, I can telnet to the smtp post and the pop3 port... Any ideas? |
Are you sure you use the correct username in your mysql*.cf files?
|
Yes.
I've created a user called mailadmin and granted the proper privileges to the mail database. Just did a full check on the users privileges and logged in as that user and performed some basic SELECT queries and was successful. |
The MySQL errors that you get in your mail log - are these current errors or old ones?
|
These are new ones. I've emptied the file and started fresh. The error is reported after I initiate a call to mailx. The log then is appended with these errors:
Code:
Mar 14 20:50:21 mgcloud postfix/pickup[24159]: 320547EA2C: uid=0 from=<root> |
Did you disable SELinux?
|
I don't think so, I'm not even sure this was enabled. Is there a way to check?
|
try one of these
Code:
getenforce |
Ya, just tried that out and it says that it's disabled. Do I need to enable Selinux to use postfix, courier-imap with mysql?
|
ok, I just enabled Selinux and rebooted. I tried the mailx command again and this time postfix tried to log on as a different user (postfix)
Here is the new error: Code:
postfix/cleanup[1848]: warning: connect to mysql server 127.0.0.1: Access denied for user 'postfix'@'localhost' (using password: YES) |
| All times are GMT +2. The time now is 07:23. |
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2013, vBulletin Solutions, Inc.