How to add a new domain to a Zimbra install and then a new account to the domain

May 24th, 2014 | By | Category: Internet, Linux / Freebsd

Ok, so you’ve got your zimbra server pretty much up and running and seeing as you’re just like me and had to take a production email server offline and retrofit it like this you have a dozen or two busy email accounts that have been rejecting emails for the past 12 hours and that needs to be fixed 🙂

So before you address the other issues you want to get those email addresses back online but before you can do that you have to be able to add their domains to the Zimbra server and this is where the literature because bloody elusive.  Everyone on the forums is talking about adding a domain in a different sense but all you want to do is add a domain so it can start receiving emails, not so people can access their webmail from mail.domain2.com

So how do we go about doing this with the CLI and not the web interface as that’s broken right now?

su zimbra

cd /opt/zimbra/bin

./zmprov

cd domain2.com

Now there are a bunch of options you can do here for attributes and what not but for now I’m keeping it pretty simple

After this(still in zmprov) you’re going to want to add an account to this domain and then set it’s password.  I can’t remember why it’s important but I’ve read it is better to create the account with a blank password(hence the ”) and then set it manually afterwards

ca email@domain2.com

setPassword email@domain2.com password

That should do it though, you should be able to receive emails just fine and dandy now, assuming that your MX records are setup properly.

 

Here’s a great page with a bunch of examples: http://wiki.zimbra.com/wiki/Zmprov_Examples

All of zmprov commands here: http://www.zimbra.com/docs/ne/6.0.8/administration_guide/A_app-command-line.20.04.html#1293179

 

Tags: , , , , ,

One Comment to “How to add a new domain to a Zimbra install and then a new account to the domain”

  1. Tom Jones says:

    Jesus what a head wreck – I was adding a domain alias instead of adding domains. I was doing it initially via the web interface.

    When I was trying to add distribution lists I was getting the error.

    ERROR: service.FAILURE (system failure: unable to create distribution list: info@fqdn2.com)

    I thought it was something to do with changing the ssh port, and then DNS. Then I found this article cleared it right up.

    Thanks for posting.

Leave a Comment