• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 324
  • Last Modified:

Virtual email domains with one static ip using sendmail and vpop3d

Hi,
I have installed redhat 6.1 and am having trouble making virtual email work, for exaple abc.com and xyz.com and get emails at amit@abc.com and amit@xyz.com
I am trying to do this using sendmail. vpop3d, I am using linuxconf for all this.

1. IS it possiable to set up email domains using one qualified IP (using ppp i have one static ip from isp) and use ip aliases that are local area (192.168.1.100-200)?
I think this is and the reason i am asking this is because sendmail help says that it is and then it starts talking about dns and ip reverse mapping, this is where i am confused, does it mean that i have to setup a dns that compliments the dns servers used by these domains (DNS for virtual domains)
The DNS servers for abc.com and xyz.com are isp's

2.if u can pleasegive me pointers to further reading on setting this up, (I have already ordered the BAT book)

3. Are there any howto's for virtual email hosting?
thanks for the help
-Amit

PS if there  is any other email system that u have used and u think it is better than sendmail pls give ur recomendations.
0
amitunix
Asked:
amitunix
  • 5
  • 4
  • 3
  • +2
1 Solution
 
trentpackCommented:
Internet email relies on DNS for routing.  You would first need to own those domains to receive mail on them.
0
 
amitunixAuthor Commented:
I have that already setup, the MX points to the static ip i have from my isp.
0
 
trentpackCommented:
You are trying to setup your own mail server aren't you?
0
The new generation of project management tools

With monday.com’s project management tool, you can see what everyone on your team is working in a single glance. Its intuitive dashboards are customizable, so you can create systems that work for you.

 
trentpackCommented:
Are you just trying to retreive mail from these email servers that already exist?  Or are you trying to make you're own email account on a domain that you don't own (which is illeagal)?
0
 
amitunixAuthor Commented:
U got it trendpack, I am trying to setup my own email servers and  Thanks for the pointers :)

Well .. I am trying to recieve and retrieve emails from these domains (not servers) which i leagally own, i have just one linux box that has a static ip, I have two domains hosted on it , now i want email id's that are two different accounts one name (amit@abc.com and amit@xyz.com) this i know is possiable by using setting up virtual email domains.
0
 
tknayakCommented:
As you already own those domains then u have to do these little configuration in the name servers..i.e.,
Add MX records for these domains. Means u have to add a line in the zone file of ur domain as
IN      MX      5 ur.mailserver.ip
this u have do do with each of ur domain zone files .and reload the nameserver database..

Then come to ur mail server and add the domains in /etc/sendmail.cw
file looks like this
#sendmail.cw include all aliases for ur #machine
abc.com
xyz.com
mnp.com

And restart sendmail service and ahh..u will get all ur mails for the domains here only..:) .. U can have multiple mailservers also in case ur first one fails .. thats a different story...:)
0
 
maxchowCommented:
The way setting up a vmail in Redhat 6.1 using Linuxconf is as belows:

1. amend /etc/inetd.conf
change
pop3 ...... ipop3d
to
pop3 ....... /usr/bin/vpop3d ipop3d

2. if you are using 1 ip for all mail server, you should in the pop user name, put in

vhost_name/vusername

e.g. abc.com/richard

Try.  I learn it from the author of Linuxconf

Max
0
 
amitunixAuthor Commented:
Hey Max
I am using just one IP

I have tried #1 before it works for abc.com and not for xyz.com ie. if i do
telnet abc.com pop-3 it says virtual ready but for the other it does not say virtual..

I will try your suggestion #2, is this to be specified in a file or is it in virtual pop accounts definition so all i need to do is to
mail delivery system(sendmail) ->
  define email dimains
abc.com
xyx.com


then in user accounts ->special accounts -> virtual pop accounts
define the users like u said
vhost_name/vusername


please confirm if this is all i need to do.
-Amit

0
 
amitunixAuthor Commented:
tknayak:
In the answer u proposed, these will not be virtual domains.
ie
user1@abc.com will get the same mail as user1@xyz.com

user1 in abc is different than user1  in xyz in virtual domains

0
 
marko020397Commented:
Hi!

tknayak has answered the question. Maybe he has forgotten
obvious subject, that you have to have properly configured
mailboxes. In directory /etc/mail/ you have some files.
You have to fill in access and virtusertable.
In file access you have to write in the IPs from where
relaying is allowed to your mail server.
In file virtusertable you have to write in the mailboxes.
For instance:
amit@yxz.com usernameatmymachine

After you have finished working with those files you should
run make which makes *.db files which are used by sendmail.

You have some information here but RedHat uses sometimes
different directories. For understanding it should be sufficient.

http://www.sendmail.org/virtual-hosting.html

Regards
Marko
0
 
maxchowCommented:
Amit,

Firstly, you should have all the domains only set in virtual domain for email only, if you have the domain abc.com and bcd.com, they should all being setup as virtual pop3 domain, you cannot set abc.com as primary and bcd.com as virtual.  It will not work.

Secondly, (1) and (2) should be done in same time.  moreover, you can just put vpop3d in the pop3 line and ignore the ipop3d.

Thridly, (2) is for setting in your mail program and checking mail.  Normally you should only use aaa@abc.com as usual.

Please also check in /etc/vmail to see whether you can see some files like shadow.<domain name> and passwd.<domain name>.  e.g. shadow.abc.com and passwd.abc.com  if you do not have them, you probably done the thing wrong, moreover, you shold also see /var/spool/vmail/<domain name>

Regards
0
 
amitunixAuthor Commented:
Sorry Marko, I think Maxchow deserves these points, his answer is the closest to the question.

-- Max please propose an answer (not a comment) so that i can award points to you.




0
 
marko020397Commented:
No problem. I agree.
0
 
maxchowCommented:
The way setting up a vmail in Redhat 6.1 using Linuxconf is as belows:

(1) amend /etc/inetd.conf
change
pop3 ...... ipop3d
to
pop3 ....... /usr/bin/vpop3d ipop3d

(2) if you are using 1 ip for all mail server, you should in the pop user name, put in

vhost_name/vusername

e.g. abc.com/richard



Firstly, you should have all the domains only set in virtual domain for email only, if you have the domain abc.com and bcd.com, they should all being setup as virtual pop3 domain, you cannot set abc.com as primary and bcd.com as virtual.  It will not work.

Secondly, (1) and (2) should be done in same time.  moreover, you can just put vpop3d in the pop3 line and ignore the ipop3d.

Thridly, (2) is for setting in your mail program and checking mail.  Normally you should only use aaa@abc.com as usual.

Please also check in /etc/vmail to see whether you can see some files like shadow.<domain name> and passwd.<domain name>.  e.g. shadow.abc.com and passwd.abc.com  if you do not have them, you probably done the thing wrong, moreover, you shold also see /var/spool/vmail/<domain name>

Regards

0

Featured Post

The new generation of project management tools

With monday.com’s project management tool, you can see what everyone on your team is working in a single glance. Its intuitive dashboards are customizable, so you can create systems that work for you.

  • 5
  • 4
  • 3
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now