<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">On 29. Nov 2020, at 16.10, Ralf Becker <<a href="mailto:rb@egroupware.org" class="">rb@egroupware.org</a>> wrote:<br class=""><div><blockquote type="cite" class=""><br class="Apple-interchange-newline"><div class=""><div class="">To answer my question I was able to identify the director code on Github and the hashes are the first 4 byte of the binary md5 written as a 32 bit integer.<br class=""><br class="">With that I was able to write a script that runs doveadm director map, queries all domains from our internal management, calculates the hashes and displays a joined list:<br class=""><br class="">doveadm-director map | grep rbz<br class=""><a href="http://rbz-xxxxxxxxx.de" class="">rbz-xxxxxxxxx.de</a>                             3766880388 10.44.88.5   nfs      2020-11-29 15:06:53<br class=""><a href="http://rbz-yyyyyyyyyyyy.de" class="">rbz-yyyyyyyyyyyy.de</a>                          3088689059 10.44.88.1   extern   2020-11-29 15:07:11<br class=""></div></div></blockquote><div><br class=""></div><div>Are you doing this to lots of domains or just a few? I think you could have also individually looked up the backends with "doveadm director status <a href="mailto:anything@domain.de" class="">anything@domain.de</a> tag". Of course, requires knowing also the tag for the domain already in this lookup.</div><div><br class=""></div><blockquote type="cite" class=""><div class=""><div class="">When I move a domain between backends / tags, I see for some time the moved domain is listed for both tags, thought doveadm who on the backends show users are only connected to the new backend. No idea why that ist. Trying doveadm director move does NOT change that situation.<br class=""></div></div></blockquote><div><br class=""></div><div>There's not really a concept of "moving user between tags". The intention was that you could have "user1@domain" in tag1 and "user1@domain" in tag2 and they would be different users. So when you're returning a new tag from passdb then director just treats it as a different user. The old user is remembered until director_user_expire has passed without the user being accessed.</div><br class=""><blockquote type="cite" class=""><div class=""><div class="">I currently disable the domain in our dict used for userdb and passdb, clear the auth cache of all directors and flush them, before (final) rsync of the mailboxes of the domain to the new backend. When our dicts answer again with the new director tag, connections are going to the correct backend-pair. But it takes some hours for the old mapping to disappear.<br class=""><br class="">Is that the expected behavior?<br class=""></div></div></blockquote><div><br class=""></div><div>Yes. And as long as the user isn't accessed via the old tag it doesn't matter.</div><br class=""><blockquote type="cite" class=""><div class=""><div class="">Is doveadm director move supposted to work with director_username_hash = %d?<br class=""></div></div></blockquote><div><br class=""></div><div>It should work if you do:</div><div><div><br class=""></div><div>doveadm director move <a href="mailto:anything@domain.de" class="">anything@domain.de</a> backend2</div><div><br class=""></div><div>It updates the director internal mapping, and it also sends a KICK-DIRECTOR-HASH to each login process in each director. This in turn should match every user with that same domain and kick them out.</div><div><br class=""></div><div>But maybe the issue is that you're again trying to move the user between tags? That's not what is really happening. It's moving <a href="mailto:anything@domain.de" class="">anything@domain.de</a> in backend2's tag from its currently assigned backend to backend2. If <a href="http://domain.de" class="">domain.de</a>'s backend was already backend2 then nothing is done. You could maybe kludge this by moving it to backend1 and then quickly to backend2 so at least one of them does the kicking.</div><div><br class=""></div></div></div></body></html>