dockerized icon indicating copy to clipboard operation
dockerized copied to clipboard

Container restart breaks email sending

Open tpimh opened this issue 2 years ago • 10 comments

I have been testing this image for a while, and it seems to work just fine. However, if the container is stopped, then started again, it causes the outgoing mail to fail with error 451 4.3.0 Temporary lookup failure. I'm not really sure what exactly is causing this, so could anyone please try to reproduce it like this:

  1. Create new iRedMail container
  2. Send test email (should be fine)
  3. Restart the container
  4. Send test email (should fail with error 451)

If the container is removed, then a new container is created with the same persistent volumes, sending emails is possible again until next restart.

tpimh avatar Mar 17 '22 06:03 tpimh

I have noticed this too. You always have to delete/start the container. Restart never works.

tensor5g avatar Apr 04 '22 15:04 tensor5g

It looks like it's because of random password generation after each start of the container. I found that vmail db password is not updated in some (maybe all) postfix configuration.

rothadamcz avatar Aug 20 '22 19:08 rothadamcz

I defined all passwords in ENV vars and it works as long as you start amavis manually (#113).

rothadamcz avatar Aug 21 '22 21:08 rothadamcz

Could you please give me a detailed step-by-step instruction (with each shell commands you ran) to reproduce this issue? @tpimh @tensor5g

I don't know how to reproduce it, hence cannot "fix" it at all.

iredmail avatar Aug 27 '22 02:08 iredmail

It appears the same problem is happening to me too. Basically just use this guide https://hub.docker.com/r/iredmail/mariadb and restart the container using docker restart containerId and in the built in roundcube you should observe "failed to add recipient: temp look up failure" when sending the email

Kerushii avatar Oct 02 '22 17:10 Kerushii

Hi, I have the same problem. could you please help

fflrichard avatar Oct 20 '22 07:10 fflrichard

Does using fixed SQL passwords fix the issue?

iredmail avatar Oct 20 '22 07:10 iredmail

Does using fixed SQL passwords fix the issue?

i set the VMAIL_DB_PASSWORD and it's ok now

fflrichard avatar Oct 20 '22 11:10 fflrichard

Could you please give me a detailed step-by-step instruction (with each shell commands you ran) to reproduce this issue? @tpimh @tensor5g

I don't know how to reproduce it, hence cannot "fix" it at all.

I know this error, it should be caused by Postfix being unable to connect to the database. I filtered the logs once, but now I forget how to proceed https://serverfault.com/questions/506347/postfix-temporary-lookup-failure

homuraLan avatar Aug 24 '23 03:08 homuraLan

seems like #23 and #123 I have the exactly same problem. I want this fency feature to use new passwords after a container reboot. New passwords can be found here: /root/.my-cnf-* But all vmail passwords in /etc/postfix/mysql/* are NOT updated. Amavis password in file /etc/amavis/conf.d/50-user also not

So i have to do that manually :( I think thats an mistake in iredmail docker code??

tobiasfaust avatar Feb 18 '24 11:02 tobiasfaust