this is a very specific thing, I do not need general tutorials to set up postfix. That out of the way, here’s the issue.
- I have postfix set up and working on several domains
- I have a new domain where I forgot to set up catch-all account
- I tested with a new "abc" email account, that was rejected with 550 error, as it should have been
- I noticed my mistake and created a catch-all account
- Any new / unknown email addresses are now being received, as they should be, due to catch-all
- Exception: that initial "abc" address is still being rejected with 450 4.1.1 "unknown user", after postfix restart and even server reboot.
Now, my thinking was, maybe postfix has permanently stored "abc" as "illegal address" (my words) somewhere in its "look-up tables" (my term). And that’s the issue, I have no clue where those are and how to manipulate them, but am pretty confident that if that look-up storage could be reset somehow, it will solve the problem. I cannot seem to find any relevant information on the Internets in that regard.
Thank you for your time reading, and possibly replying here, cheers!
PS. Maybe I’m totally wrong, any new insights are welcome. Btw, this is on CentOS 7.
2
Answers
Looks like this was just temporary, ie. after a couple of hours, postfix started accepting the "abc" account again, without any changes to the server / settings. Some sort of time-out / reload, probably. So I guess the "answer" would be to wait it out when in a similar situation. I would still be interested to know if there is a way to do it instantly, but ultimately, waiting is the answer here.
As I just figured out after having a similar issue, the verify daemon (
man 8 verify
or http://www.postfix.org/verify.8.html) is responsible for the issue. It can be configured to keep rejects stored for some specific time (3h per default as per https://www.postfix.org/ADDRESS_VERIFICATION_README.html) but that time can be changed. However, one immediate solution can be to just remove the verify cache and then reload postfix:So, for me the workflow to change the aliases db now is to run this command:
However, obviously, you loose all cached results this way, so the server will have some higher load reverifying everthing. So on a bigger server, you might also win by temporarily configuring to cache reject results only for a short time (e.g., 5 minutes), reload postfix, wait that 5 minutes, reload again and then change config back and reload postfix a last time. I didn’t test this approach because I didn’t have to, but I don’t know the size of your setup.
Or of couse, just wait out that time.