This chapter examines the subsystems of your server, and provides recommendations for optimal performance. The chapter includes the following topics:
On Solaris and Windows, Sun Java System Web Server transparently takes advantage of multiple CPUs. In general, the effectiveness of multiple CPUs varies with the operating system and the workload. Dynamic content performance improves as more processors are added to the system. Because static content involves mostly IO, and more primary memory means more caching of the content (assuming the server is tuned to take advantage of the memory) more time is spent in IO rather than any busy CPU activity.
As a baseline, Sun Java System Web Server requires 64 MB RAM. Multiple CPUs require at least 64 MB per CPU. For example, if you have four CPUs, you should install at least 256 MB RAM for optimal performance. For high numbers of peak concurrent users, also allow extra RAM for the additional threads. After the first 50 concurrent users, add an extra 512 KB per peak concurrent user.
You need to have enough drive space for your OS, document tree, and log files. In most cases 2 GB total is sufficient.
Put the OS, swap/paging file, Sun Java System Web Server logs, and document tree each on separate hard drives. Thus, if your log files fill up the log drive, your OS will not suffer. Also, you’ll be able to tell whether, for example, the OS paging file is causing drive activity.
Your OS vendor may have specific recommendations for how much swap or paging space you should allocate. Based on our testing, Sun Java System Web Server performs best with swap space equal to RAM, plus enough to map the document tree.
For an Internet site, decide how many peak concurrent users you need the server to handle, and multiply that number of users by the average request size on your site. Your average request may include multiple documents. If you are not sure, try using your home page and all of its associated subframes and graphics.
Next decide how long the average user will be willing to wait for a document, at peak utilization. Divide by that number of seconds. That’s the WAN bandwidth your server needs.
For example, to support a peak of 50 users with an average document size of 24 KB, and transferring each document in an average of 5 seconds, we need 240 KBs (1920 Kbit/s). So our site needs two T1 lines (each 1544 Kbit/s). This also allows some overhead for growth.
Your server’s network interface card should support more than the WAN it’s connected to. For example, if you have up to three T1 lines, you can get by with a 10BaseT interface. Up to a T3 line (45 Mbit/s), you can use 100BaseT. But if you have more than 50 Mbit/s of WAN bandwidth, consider configuring multiple 100BaseT interfaces, or look at Gigabit Ethernet technology.
For an intranet site, your network is unlikely to be a bottleneck. However, you can use the same calculations as above to decide.