<div dir="ltr"><div>John, <br></div><div><br></div><div>I was having an issue with the tcp socketĀ @ 127.0.0.1. I'd tried various different modifications based on the logs and the issue had remained regardless.<br></div><div></div><div>I had built up the environment in a dockerfile and worked on it through the weekend so the problem was replicable across instances up until this morning.</div><div><br></div><div></div><div>I ended up switching over to using the socket yesterday and only checked out to the previous commit this morning to run a few additional tests on<br></div><div>the problematic part. For whatever reason, the issue is now completely gone.<br></div><div><br></div><div>At this point, I'm thinking this must be a docker issue. <br></div><div><br></div><div>The only notable (minor) differences between this past weekend and today are an AER/ASPM kernel error that was logging on the host.</div><div>The paste is here: <a href="https://pastebin.com/idBWKDq2">https://pastebin.com/idBWKDq2</a></div><div><br></div><div>The main difference between the weekend and today is the additional line included saying it can't find device of ID 0008. That wasn't showing up over the weekend.</div><div></div><div>I think given this experience I may have to revisit my testing methodology when working with docker.<br></div><div><br></div><div>Best Regards,</div><div>Lorek<br></div><div><div><div><br></div></div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Jul 2, 2019 at 12:38 PM John Fawcett via dovecot <<a href="mailto:dovecot@dovecot.org">dovecot@dovecot.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 01/07/2019 09:48, lorek via dovecot wrote:<br>
> Actually, it seems I may have been wrong in initial assumption that<br>
> the issue with the client was that it was being identified to mysql as<br>
> coming from localhost when connecting via tcp.<br>
> This is what syslog indicated as a reason for the failure but its not<br>
> the whole picture.<br>
><br>
> As John mentioned I am trying to have dovecot connect over TCP to<br>
> mysql (not using the socket), and the issue looked like the cause was<br>
> the identified by portion of mysql being read by either mysql<br>
> incorrectly or the domain portion being overwritten on dovecot's end<br>
> (I don't know about the internals enough to say for sure where).<br>
><br>
> Just as due dilligence, I added credentials for a mysql user<br>
> identified by localhost and removed the jail since the dovecot error<br>
> was stating that it failed for connection by user@'localhost' (where<br>
> there weren't credentials).<br>
> After adding the credentials, I performed all the usual mysql tests<br>
> before moving testing up to dovecot and still get an auth failure. The<br>
> log seems to be a bit of a red herring or at the minimum doesn't show<br>
> the whole picture.<br>
><br>
> Replacing the connection string host with the socket (host=localhost)<br>
> and everything works, and using an external IP that's not 127.0.0.1<br>
> works as expected as well. (confirmed by standing up two isolated<br>
> mysql and dovecot containers and setting auth up over the bridge).<br>
><br>
> If the issue was caused by user@'localhost' creating the credentials<br>
> should have resolved it, and it didn't. So something weird is going on.<br>
> I've got the environment built up in a dockerfile I can provide if<br>
> anyone wants to dig into what's causing it.<br>
><br>
> In the meantime due to time constraints, I'll just be working with the<br>
> socket file from now for hosts running most of the mail stack all in one.<br>
><br>
> Best Regards,<br>
> Lorek.<br>
<br>
Lorek<br>
<br>
If you have user@localhost as a user in mysql you will be able to<br>
connect with either of these options:<br>
<br>
- a tcp socket via an ip address that resolves to localhost<br>
<br>
- a unix socket via hostname localhost.<br>
<br>
If you have <a href="mailto:user@127.0.0.1" target="_blank">user@127.0.0.1</a> as a user in mysql you will be able to<br>
connect only via:<br>
<br>
- a tcp socket using ip address 127.0.0.1.<br>
<br>
John<br>
<br>
<br>
</blockquote></div>