Setting up postfix to use with virtualmin


I’m using webmin/virtualmin, but when I launch virtualmin, I have the following error:

"No virtual domains file was found in your Postfix configuration. Maybe no virtual domain map has been defined."

So, what exactly should I configure, and how? If someone can explain me how to configure it from inside webmin, that would be better. If not, I can still configure it via ssh, but I would prefer configuring it from inside webmin.


Hey Julien,

Browse to the Virtual Domains page in the Postfix module.

In the field labeled "Domain mapping lookup tables", switch the radio button from None to the text field, and in the text field, enter:


Don’t leave off the “hash:” portion. I’m not sure why, but despite all of the docs including it, we get a lot of folks leaving it off.

Save it, and then re-check your config.

Thanks a lot, it is as easy as just saying "hi" ^^
Virtualmin seems to be a really good software ^^

btw does it mean we need to create tables in mysql to handle those mails, or is it done automatically?

I wonder, because I tried to send an email from a working email to a virtual domain email I just created, and the email never reached its destination…

Correction, mail sending works fine, that is usermin which has a problem, as it is impossible in usermin to see the mails sent to a virtual server…

But if I do inside webmin read user mail, it works fine…

btw does it mean we need to create tables in mysql to handle those mails, or is it done automatically?

I see that you’ve got this one figured out already, but I will mention for the clarity of anyone else reading this thread:

MySQL has nothing to do with mail unless you make it have something to do with mail. And I’d recommend against making it have something to do with mail. If you want database-backed users, go with LDAP. (But the vast majority of deployments of Virtualmin don’t need LDAP, either.)

Hey Julien,

You just need to configure the Usermin Read Mail module to know how to find your mail. I dunno whether you set it up for Maildir (recommended) or mbox–you can also choose to have Usermin use IMAP, and it won’t need to know how mail is stored. The options are found under Webmin:Usermin Configuration:Usermin Module Configuration:Read Mail.

First of all allow me to thank Joe and the Virtual Team of Virtualmin for such a superb hosting solution.

I am very new to Virtualmin. I had bought professional version. Joe had installed it on my server.

Now I am trying to configure it.
As an admin I created a "Reseller Account". Then I logged into the machine as a reseller and tried to create a Virtual Domain. I got the same error as above:

I did go in to see if I can change the value as prescribed. However I noticed the following was already set:

So I am not sure why am I getting this error for Postfix…


I guess all I had to do was to press the "Save" button. I did that. Thereafter I logged back again as reseller. I tried to re-create the new virtual domain. This time the things worked.

So - problem resolved.