Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
howto setup webmail for 10000 and more users?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
sepp
Guru
Guru


Joined: 11 Jul 2002
Posts: 330

PostPosted: Wed Aug 06, 2003 11:50 am    Post subject: howto setup webmail for 10000 and more users? Reply with quote

Hi,

I was just wondering how websites like lycos, hotmail, gmx and co work. As with 2.4 kernel you can only have 2^16 UIDs it's impossible that they setup up real accounts. But on the otherhand side, if you want to offer webmail with pop3 users need to have a system account, don't they?
How (and with which OSS) would you setup a webmail and pop3 service? I saw nice wemailers like horde imp but I don't know if this is the right way to go.
I'm wainting for your opinions.
Back to top
View user's profile Send private message
fleed
l33t
l33t


Joined: 28 Aug 2002
Posts: 756
Location: London

PostPosted: Wed Aug 06, 2003 12:18 pm    Post subject: Reply with quote

I think they use databases for users and their settings/messages, etc. So the maximum number of UIDs is not really relevant. Also, they use loads of computers so it's a bit more complex than what you'd have on a single PC.
Back to top
View user's profile Send private message
Hmzaniac
n00b
n00b


Joined: 18 Jun 2003
Posts: 3
Location: In a serverrack

PostPosted: Thu Aug 07, 2003 12:21 am    Post subject: Reply with quote

with a user database like openLDAP for user storage, postfix (with LDAP support, courier-imap or cyrus (both with LDAP support) you'd come a long way.

The only thing you'd most likely need to build yourself would be the webmail service, since most webmail services i've seen (imp/horde, squirrelmail and some others) don't really integrate very well with ldap. Ofcourse they can authenticate against nss_ldap or pam_ldap, but preferrably you'd want to store more info on these users in ldap (for example, quota, permissions, rights, subscriptions, wether the user has paid, etc.)
_________________
Users are the evil of all roots.
Back to top
View user's profile Send private message
kashani
Advocate
Advocate


Joined: 02 Sep 2002
Posts: 2032
Location: San Francisco

PostPosted: Thu Aug 07, 2003 12:29 am    Post subject: Reply with quote

Having done it for 10mil, no you don't give them real accounts. Parsing an /etc/password, shadow, etc over 3-5k lines is going to tank your machine. It's all virtual accounts, in a database, uder one uid/gid.

Look at the Gentoo Virtual Mailhost guide. It's the same idea, just larger. The nice thing is you can use the db table to split your users over mutiple storage arrays and other cool tricks.

kashani
_________________
Will personally fix your server in exchange for motorcycle related shop tools in good shape.
Back to top
View user's profile Send private message
sepp
Guru
Guru


Joined: 11 Jul 2002
Posts: 330

PostPosted: Thu Aug 07, 2003 9:22 am    Post subject: Reply with quote

kashani wrote:
Having done it for 10mil, no you don't give them real accounts. Parsing an /etc/password, shadow, etc over 3-5k lines is going to tank your machine. It's all virtual accounts, in a database, uder one uid/gid.
kashani


that's probably true for webmail ONLY accounts. but what happens if you want to offer people to have pop3 and smtp access aswell? if you want to check your email via pop3 you'll need to have a real account on the machine. how do they do this?
Back to top
View user's profile Send private message
mst
n00b
n00b


Joined: 21 Jul 2003
Posts: 7
Location: Israel

PostPosted: Thu Aug 07, 2003 9:37 am    Post subject: Reply with quote

I run and maintain systems which are built entirely on MySQL, postfix, courier-imap and squirrelmail. They provide SMTP, IMAP, POP3 and webmail services. All email users are purely virtual. Easy to set up and configure, there's a lot of referrence material at the Postfix website
Back to top
View user's profile Send private message
Qball
Apprentice
Apprentice


Joined: 25 Nov 2002
Posts: 196

PostPosted: Thu Aug 07, 2003 10:46 am    Post subject: Reply with quote

one of the most biggest providers here use squirrelmail for there webmail (more providers do that) and it works great..
Back to top
View user's profile Send private message
sepp
Guru
Guru


Joined: 11 Jul 2002
Posts: 330

PostPosted: Thu Aug 07, 2003 10:55 am    Post subject: Reply with quote

mst wrote:
I run and maintain systems which are built entirely on MySQL, postfix, courier-imap and squirrelmail. They provide SMTP, IMAP, POP3 and webmail services.

do you run squirrelmail connected to a mysql database aswell? maybe even with spamassassin configured?
Back to top
View user's profile Send private message
kashani
Advocate
Advocate


Joined: 02 Sep 2002
Posts: 2032
Location: San Francisco

PostPosted: Fri Aug 08, 2003 12:50 am    Post subject: Reply with quote

sepp wrote:


that's probably true for webmail ONLY accounts. but what happens if you want to offer people to have pop3 and smtp access aswell? if you want to check your email via pop3 you'll need to have a real account on the machine. how do they do this?


For someone who is asking a number of basic questions about a topic they have little knowledge you're awfully opinionated.

Here's the quide I mentioned that will answer the majority of your questions, as well as telling you how to build such a system on a smaller scale. Figuring out how to deal with multiple I/O paths, db replication, clustering, and load balancing to support 10k users is left as an excersize for the reader.

http://www.gentoo.org/doc/en/virt-mail-howto.xml

kashani
_________________
Will personally fix your server in exchange for motorcycle related shop tools in good shape.
Back to top
View user's profile Send private message
sepp
Guru
Guru


Joined: 11 Jul 2002
Posts: 330

PostPosted: Mon Aug 11, 2003 10:12 am    Post subject: Reply with quote

kashani wrote:

Here's the quide I mentioned that will answer the majority of your questions, as well as telling you how to build such a system on a smaller scale. Figuring out how to deal with multiple I/O paths, db replication, clustering, and load balancing to support 10k users is left as an excersize for the reader.

http://www.gentoo.org/doc/en/virt-mail-howto.xml

kashani


read this one. it seems to be what i was looking for except that all email accounts are in one database. it would be much nicer to have a seperate table for each domain.
Back to top
View user's profile Send private message
patan
n00b
n00b


Joined: 19 Feb 2003
Posts: 66

PostPosted: Mon Aug 11, 2003 11:22 am    Post subject: Reply with quote

sepp wrote:

read this one. it seems to be what i was looking for except that all email accounts are in one database. it would be much nicer to have a seperate table for each domain.


This might not suit you since I don't know why you want this, but take a look at VIEWS

http://www.postgresql.org/docs/view.php?version=7.0&idoc=1&file=rules19478.htm

MySQL doesn't support VIEWS yet so you'd have to use Postgres or another database that does.
Back to top
View user's profile Send private message
sepp
Guru
Guru


Joined: 11 Jul 2002
Posts: 330

PostPosted: Mon Aug 11, 2003 11:48 am    Post subject: Reply with quote

patan wrote:
sepp wrote:

read this one. it seems to be what i was looking for except that all email accounts are in one database. it would be much nicer to have a seperate table for each domain.


This might not suit you since I don't know why you want this, but take a look at VIEWS


I want this so I can give each domain owner the right to setup and maintain his email accounts.
Back to top
View user's profile Send private message
patan
n00b
n00b


Joined: 19 Feb 2003
Posts: 66

PostPosted: Mon Aug 11, 2003 12:00 pm    Post subject: Reply with quote

sepp wrote:

I want this so I can give each domain owner the right to setup and maintain his email accounts.


What kind of interface are you going to use to do this? You can just add a field called "domainid" to the tables and let each domain owner edit users which has their id.
Back to top
View user's profile Send private message
sepp
Guru
Guru


Joined: 11 Jul 2002
Posts: 330

PostPosted: Mon Aug 11, 2003 12:42 pm    Post subject: Reply with quote

patan wrote:

What kind of interface are you going to use to do this? You can just add a field called "domainid" to the tables and let each domain owner edit users which has their id.

I'm going to setup a php interface.
the domainid thing would be ok for changing user settings and creating new ones. but each domain admin will see all the other accounts on the other domains. that's not good.
Back to top
View user's profile Send private message
patan
n00b
n00b


Joined: 19 Feb 2003
Posts: 66

PostPosted: Mon Aug 11, 2003 12:48 pm    Post subject: Reply with quote

sepp wrote:

I'm going to setup a php interface.
the domainid thing would be ok for changing user settings and creating new ones. but each domain admin will see all the other accounts on the other domains. that's not good.


But you'd have to filter the other ones out. For example if domain_id 1 = example.org and domain_id =2 is example.com. When the administrator for example.com is editing his users the system should issue a "select * from users where domain_id = 2" then he will only see his own users.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum