Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I setup Postfix and Dovecot on a new Ubuntu box following these directions.

From a client machine, I validate that POP3 seems to be working

telnet 110
+OK Dovecot ready.
PASS mypassword
+OK Logged in.
+OK Logging out.

However, when trying to configure Gmail on the same client to retrieve email via POP3, I get the error

Server denied POP3 access for the given username and password.
Server returned error: "Login failed."

I carefully confirmed that Gmail is configured to use the same POP Server, Port, Username and Password I used when checking the connection with telnet.

What could be causing Gmail to get a "Login failed" message?

share|improve this question
up vote 2 down vote accepted

It turns out that, while DNS changes to point to the new server had propagated to my local box when I did the testing, they had probably not yet propagated to Google.

Retrying the procedure the following day worked just fine.

share|improve this answer

While I can't help you solve the problem like this, I can help you debug the problem. First thing you need to do is increase the log level of Dovecot:

  • auth_debug_passwords=yes
  • mail_debug=yes

Restart dovecot and try to log in with your Gmail account. You can now see if Gmail tried to log in or not into your dovecot in the log you defined for dovecot (by default this will be /var/log/mail.log I think).

share|improve this answer
+1 for the tip, but it turned out to be something else in my particular case. – Eric J. Nov 12 '12 at 16:41

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.