Deactivating an ejabberd vhost is easy. In the simplest case, just remove the entry from the hosts section in /etc/ejabberd/ejabberd.yml.

I presume this does not delete any information about the users related to that host:

  • Username
  • Password (if not taken from LDAP or similar)
  • vcard
  • Roster
  • Offline Messages
  • MAM Archive

and probably a few things more still remain in the Mnesia database.

How can I get rid of this information for an entire vhost?


With a command like this:

$ ejabberdctl delete_old_users_vhost localhost 0
Deleted 2 users: [{<<"hag66">>,<<"localhost">>},
| improve this answer | |
  • One step in the right direction. But I would like it per-vhost. Without that limit, it also deletes all the TURN accounts. Maybe I can work around this with the protect_old_users configuration setting? – Marcel Waldvogel Sep 1 '18 at 8:47
  • It does not seem to affect users who are authenticated against an external authentication source; only local user accounts seem to be affected. – Marcel Waldvogel Sep 1 '18 at 9:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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