我正在尝试弄清楚需要什么样的硬件才能为一个相当大的社区运行 phpBB 3 服务器。当我说硬件时,我指的是 CPU、RAM 和 IO 规格。当我说相当大的社区时,我指的是一个大约有 30,000 人的社区,平均每天发布 1,000 篇帖子,每天大约有 100 名活跃用户。
我曾看到有人讨论为 5,000 名用户的 phpBB 2 社区配备 1 GB RAM,但这当然有点过时了。有什么想法吗?
答案1
100 个活跃用户并不意味着...游戏结束...如果您想要稳定的性能,那就花点预算,买最大的,然后慢慢适应。(这通常是坏建议,但我认为它在这里适用...)。
通常,在指定服务器硬件时,人们会进行基准测试,找到所需的硬件,然后以最便宜的他们能找到的价格。如果你没有这个能力……那么最好的办法可能是在硬件上投入大笔资金,如果这还不够的话,再进行缓存等优化。
无法直接回答您的问题,因为:
You say 100 active users/day
I take this to mean that during the day 100 users come and go and maybe do some things
That is no big deal... Let's assume that for 12 hours in the day.. your users sleep
(if they don't and access is spread around the clock it works in your favor -- distributed load)
So 100 users make ~30 requests that are either reads/posts/uploads/or something else...
These loads very... so we'll pretend they have a nice clean average.
100 x 30 = 3,000 requests / day.
If we pretend that your server takes 10/sec to process one request
then we have a total processing time of:
100 x 30 = 3,0000 requests * 10 seconds = 30,000 seconds / day spent processing requests
There are some 86400 or so seconds in a day.
If we cut off half of those because users are sleeping
Then we still have 43,200 seconds left
30,000 < 43,000 seconds so the server might handle the load...
If everything is spread out..
重要的是:
1)你的用户习惯
2)这些习惯对服务器负载/容量/等的影响(例如:从缓存中读取页面比上传 50MB 更容易)。