Setting up a mail server with Dovecot and/or Postfix with virtual domains
I installed Postfix, and later realized Dovecot was already installed. I believe they are both running.. simultaneously.. yet I haven't had any problems. Odd.
You may have already noticed that this is the first time I've set up a mail server. It's actually the first time I've had to set up a dedicated server on my own from scratch (it's a web server + mail server + nameserver + FTP server). Anyway, so far so good. I have it set up in such a way that my Linux users are e-mail accounts, i.e. to create a new e-mail address, all I have to do is set up a new Linux user. However, that only pertains to my main domain name. I also have a few other domain names hosted as virtual domains on this server. How can I create e-mail accounts that are "at" (@) the other domains? I have the nameserver section already complete (MX records are good), I just need to know how to create the e-mail addresses for these other domains. |
Quote:
Start by reading http://www.postfix.org/VIRTUAL_README.html and decide how fancy you want to get (key thinking points will be number of domains, number of users in each, etc.) |
Quote:
Link isn't working at the moment; I'll have to check it later. But essentially, I have about three domains that need e-mail addresses, and I'll only need about.. five or less addresses on each. |
I took a look at that link and set up Postfix so that it recognizes my virtual domains (i.e. it will no longer reject e-mails sent to those domains).
But how do I now create e-mail addresses under those virtual domains? |
See the example given in the link titled "Postfix virtual MAILBOX example: separate domains, non-UNIX accounts"
Code:
10 /etc/postfix/vmailbox: Note you can have virtual aliases and whatnot as well (they show an alias example on lines 17/18 Important note - you would create this file (vmailbox) with a text editor, but you must execute "postmap /etc/postfix/vmailbox" for postfix to be able to use it as specified. Ditto for the virtual alias file (anything you see referred to with has: in main.cfexcept the main alias file which requires you run newaliases). |
I have now added the following code to the files indicated (without the numbers to the left and filenames, of course). I am trying to create the e-mail addresses EMAILREMOVED and EMAILREMOVED for the joshforde.com virtual domain, hosted on my server whose main domain name is seedsoftime.net
Code:
1 /etc/postfix/main.cf: Of course.. I am not yet able to log in with my e-mail client, which isn't surprising as I haven't yet seen any place in configuration files to enter passwords for the two e-mail addresses I tried to create. What else am I missing / Where do I enter passwords? |
First, I'd take those emails out of your post in cash they get harvested.
Nothing I don't think (you probably needed to do the postmapping prior to the reload). Send a message to one of those accounts and see if anything gets created in the relevant mailbox (are you wanting Maildir format?) |
Thanks for the heads-up, I forgot about e-mail harvesting for a minute.
Quote:
EDIT: I tried sending a test e-mail to the address, and it didn't work. Here's the message shown in Mozilla Thunderbird: http://i35.tinypic.com/20fpbtz.png |
Maildir is basically where each message is a file in itself, whereas mbox is one big file with all the messages one after the other. I think most people prefer maildir, since it's less open to corruption, faster to perform certain actions on (such as delting a message) etc.
Doesn't really matter. The "/" at the end of the location is the giveaway. One thing though, maildir uses 3 directories for each account (cur, new and tmp). The delivery probably creates these for a new account on first delivery, but it's possible you will get an error and need to create these manually. Did you get any mail delivered? If not, "tail /var/log/maillog" |
...
This is all going over my head. >_< Server configuration is definitely not my thing. |
Doesn't really matter - leave it as is.
How's it going otherwise? |
Nothing really changed since my last couple of replies.. I can't figure out how to create an e-mail address for the virtual domain. :/ Most of the information in the above link is beyond my comprehension. I'm surprised I was able to set up a everything I did so far (nameserver, FTP, virtual domain hosting, etc.) on this machine.
|
Can you be specific? The example given seems pretty clear to me.
Rgds BM |
All times are GMT -5. The time now is 09:16 PM. |