We are sometimes asked how many users the system can support, and this kind of like asking how many balls of string are needed to reach the moon, the answer depends on the size of the ball of string 🙂
If you have a running system, then you can estimate some useful figures, e.g. concurrent sessions per user and disk storage per user, then you have some real figures to work with :-)... If you don't yet have a running system you can make up numbers for these two factors, and your estimate will be correspondingly meaningless 🙂
Next find the limiting factor for each resource, and the lowest one is your estimate, e.g.
- CPU usage
- Memory usage
- Thread limit
- Disk usage
- Disk IO
So lets say you have 20,000 users currently on your system, and your current usage figures are:
Resource Name | Current Usage | Cur Users | User limit for resource |
CPU | 10% | 20,000x100/10 | 200,000 |
Disk Space | 25% (250gig/1000gig) | 20,000x100/25 | 80,000 |
Disk IO/Second | 10% (100/sec of 1000/sec) | 20,000x100/10 | 200,000 |
Memory | 20% (500mb of 4gig) | 20,000x100/20 | 100,000 |
Concurrent threads | 5% (100 of 2000) | 20,000x100/5 | 400,000 |
So in this hypothetical example the limiting factor is disk space and the max possible users is 80,000.
However things to keep in mind:
- CPU's are generally cheap so be sure to get one with sufficient cores 🙂
- SSD /M.2 drives are massively faster in disk io/second, always use SSD not HDD
- The thread limit can be tricky, it can be pushed up to 4000, but I would suggest 2000 is a safer limit, it also is dependent on memory so be sure to install more RAM & CPU if you want to push it 🙂
- It's usually simpler and cheaper to upgrade the hardware than to use multiple systems to spread load (but always use a mirror)
- Disk IO is 'usually' the limiting factor or used to be in HDD days :-).
- The way the users 'work' massively affects the load they create, having good policies to limit users total 'message count' in inbox is essential for good performance. On a large system allowing users to abuse the system with bad email clients can negatively affect the entire system.
- Also voicemail users have a completely different usage profile to regular 'email' users, and pop users are completely different from imap users.
- Active business users, who login all day long, are completely different from casual users who login once a week or a few minutes a day. 1 business user = 20 casual users... (roughly).
- Inactive users cause no load, you can have lots of those! 🙂
Where do I get those figures?
tellmail status will report some figures:
VMSize: 455 Sending 1: Threads 26/76, Peak Links 111, smtp=2, ... (thread limit)
The operating system will report the other figures:
- Disk IO/sec (Total disk IO you may have to estimate by testing your system)
- Total disk space
- Total Memory available
- CPU usage