Koozali.org: home of the SME Server

is it possible to host emails for multi domains ?

Lallemant sebastien

is it possible to host emails for multi domains ?
« on: June 19, 2003, 04:54:32 PM »
is it possible to host emails for multi domains ?
ex : bob@site1.com , bob@site2.com

or does virtualhosts works only for the webserver ?

Peter Garbæk

Re: is it possible to host emails for multi domains ?
« Reply #1 on: June 19, 2003, 05:28:23 PM »
Yes its possible..

Login to the server via putty (ssh shell)
goto the user´s dir
/home/e-smith/files/users/*userdir*/
then type.
vi .qmail-default
enter the username ie.bob
exit and save with :wq

then type
chmod 644 .qmail-default
chrown bob:bob .qmail-default

goto /etc/e-smith/templates-custom/var/qmail/control/virtualdomains/
open 90aliases with vi
Enter
bob@site1.com:bob
bob@site2.com:bob
exit and save with :wq

(if you want a * alias just type "@site1.com:bob")

the :bob is to what account the email addresse is linked with.

Type
/sbin/e-smith/signal-event console-save
( It saves the settings you just made )

Type
killall -HUP qmail-send
(reloads the qmail deamon)

Hope this helps..
Peter Garbæk

Lallemant sebastien

Re: is it possible to host emails for multi domains ?
« Reply #2 on: June 19, 2003, 05:50:08 PM »
thanks a lot !!

Jens Kruuse

Re: is it possible to host emails for multi domains ?
« Reply #3 on: June 19, 2003, 07:32:08 PM »
Erm, I don't understand this?

I host two domains on my server and by default all accounts are active under both domains. And if I want to use a * alias, I can let the admin receive all unknown mail and have procmail forward the non-admin mail to the proper user. So what's the idea behind all of the manual editing?

Please explain why this process is necessary.

Cheers,
Jens

dave

Re: is it possible to host emails for multi domains ?
« Reply #4 on: June 20, 2003, 03:25:31 AM »
Peter,

This looks like it may be something that I could modify to allow a name to be referenced to only one domain:

Would it be possible to change the following:

bob@site1.com:bob
bob@site2.com:bob

to

bob@site1.com:bob
bob@site2.com:ralph

to let ralph get email from alias bob@site2.com?

Or would

bob@site1.com:bob

keep email addressed to bob@site2.com from getting to :bob at all?

Dave

Peter Garbæk

Re: is it possible to host emails for multi domains ?
« Reply #5 on: June 20, 2003, 11:52:10 AM »
dave wrote:
> Would it be possible to change the following:
>
> bob@site1.com:bob
> bob@site2.com:bob
>
> to
>
> bob@site1.com:bob
> bob@site2.com:ralph
>
> to let ralph get email from alias bob@site2.com?
>
> Or would
>
> bob@site1.com:bob
>
> keep email addressed to bob@site2.com from getting to :bob at
> all?
>
> Dave

Yeah both things are usable, you could also do
@site1.com:bob

Then bob get´s all mails for site1.com, unless there are other users, they override the rule.. ie

@site1.com:bob
peter@site1.com:peter

Then bob gets all mails send to site1 except mails sendt to peter@site1.com

:)

Kind Regards
Peter Garbæk

Mike Hansen

Re: is it possible to host emails for multi domains ?
« Reply #6 on: June 20, 2003, 02:34:01 PM »
Has anyone considered making a server panel for this? It gets rather annoying doing it the old fashion way.

Oh yeah is it possible to make an alias so that bob-1 gets mail from the alias admin@site2.com when we do have admin@site1.com as a real account?

Mike

Peter Garbæk

Re: is it possible to host emails for multi domains ?
« Reply #7 on: June 20, 2003, 02:42:17 PM »
Sign me up for that Panel too... that would be great.. heh i add 2 - 4 users each day..

You could make a group called adminforsite2
then add the
admin@site2.com:adminforsite2

and make bob-1 a user for the group adminforsite2

I did the same thing on our server..
Made a group called infoforeveryone
added info@oursite.dk

the added the 4 users so we all get the mails send to info@oursite.dk

:)

Kind Regards
Peter Garbæk

Michiel

Re: is it possible to host emails for multi domains ?
« Reply #8 on: June 20, 2003, 03:22:25 PM »
Have a look at http://dungog.net/sme/products/vdomain.php. This seems to do what you're asking for. It's not free though, but US$33 seems a fair price to me.

Michiel

dave

Re: is it possible to host emails for multi domains ?
« Reply #9 on: June 20, 2003, 09:42:55 PM »
Peter!  Thanks!!!

I know this issue has been discussed here before but for some reason this is the first time I've seen reference to it that makes sence.  Maybe I'm just getting more familiar with how Linux works.

I'm going to play around with this over the weekend.  

The next thing to do will be to implement a spam filter.  My admin account gets over 100 emails a day - all spam, about 90% is adult content.  And one of my kids some how got listed somewhere and she gets about 40 emails a day - again, all spam.  

Thanks again!
Dave