You are on page 1of 27

This section aims to provide you with a clear understanding of exactly what a web server is, and what

functions related to its hardware and software combination it must perform.

the hardware requirements of the server software the operating system that is used with the server, and how it affects security of the server some key features of the web server the options available for configuration, remote or local security features performance issues, including monitoring the need to upgrade, and various options available when a decision has been taken to upgrade.

SAN

A disk drive is a mass storage device. It does not need to be connected to a system that allows its contents to be displayed, i.e. no need to have a monitor, or a graphical user interface (operating system).

Web Server

Similarly, a web server does not need a windows system, a video card, a monitor or even a keyboard. The windows system occupies a great deal of RAM and CPU time, so it is a drain on server performance. You don't have any choice if you're using a Windows or Mac web server, but on Unix systems you can simply turnoff X Windows.

Unix has an additional reason not to use a windowing system: the currently active window has a higher execution priority than other processes.

Web Servers without monitors are known as headless servers

What is required?
Good i/o Multiple Buses Fast disks Memory Scalability

Good i/o

The key distinguishing feature of server hardware is high-performance input output (I/O). Standard PC hardware is limited by its legacy I/O subsystem, while server hardware is designed around I/O and can easily have ten times the I/O performance of the best PCs.

Buses
A bus is a set of parallel wires (usually 32, 64, 128 or 256 wires, plus error and protocol handling wires) embedded in a board forming the backbone of the computer. Other components, including CPU, disk, memory and network cards, are connected to each other by their shared bus.

Buses
There may be more than one bus in a computer. PCs may have only one bus connecting everything. Server hardware, however, typically has at least two separate buses: a high-speed bus for connecting memory to the CPU. and a slower bus for connecting I/O to the CPU.

System buses lag CPU speed by a large margin, meaning that CPUs spend a great many cycles simply sitting and waiting for the bus to catch up. Buses are usually faster than network connections but Fast Ethernet 100Mbps and this is faster than EISA or ISA buses!

Multiple Buses

Servers usually have separate buses for L2 cache, I/O, RAM and peripherals. This reduces contention and allows the use of appropriate hardware for each bus. Server buses may be packet switched, in the sense that a request is made over the bus and the bus is released until the response is ready, allowing requests to be interleaved with responses and improving throughput. Bus throughput is critical for servers because a great deal of what a server does is simply copy data between network devices and storage devices.

Gigabit Ethernet runs at 1000Mbps At gigabit rates, the server bus and CPU generally become the bottleneck, especially if the CPU is trying to do database access or run CGI applications at the same time.

Fast Disks
Servers should have separate highspeed SCSI disks for content and logging. IDE disks are not acceptable. Striping data over disk arrays is highly recommended to allow seeks to proceed in parallel. i.e. RAID

More about disks


IDE not suitable EIDE Getting better 4 16MBps SCSI Better

5 40MBps Can use more disks Can use multiple controllers (cache) and

interleave requests across disks Easier to use RAID

Multiple disks
Use on disk for content and another for logging Consider putting the O/S on one and the content on another If one disk was faster than another what would you put on it.

Disk performance The Need for Speed


7,200 rpm = approx 100 random accesses per second or 500 sequential read ops. 5,400rpm = approx 75 random accesses p/s 10,000rpm = approx 140

(assuming access time of 10ms)

Microsoft vs Unix
Disks on PC systems are capable of a sustained 816 Mbit/second throughput, while the same disks on Unix systems can achieve 3240 Mbit/second because of Unix optimisations for disk access. Unix is a popular solution

RAID
Redundant arrays of inexpensive disks (RAID) are an example of how you can achieve high performance from a collection of relatively low-performance components. The idea behind RAID is to set up a collection of disks in which every bit of information is on at least two disks, so that even if any one disk fails there will be no interruption in service. Because of the number of disks, you can use cheaper disks that have a lower reliability. As a bonus, the performance of RAID systems is very good because the system can run multiple requests in parallel, and because smaller disks may have lower seek times as a result of their physically smaller platters. For example, four 20 GB drives will usually have better performance than one 80 GB drive.

Fragmentation
As a disk fills up, it becomes progressively harder to find enough contiguous space to write new files, so new files are written in fragments at multiple places on disk. Reads and writes of fragmented files require multiple movements of the disk arm, slowing access. Unix is not as prone to fragmentation as MS or MAC o/s

Dealing with Fragmentation


Leave 10% of disk free to minimise the effects Defragging a drive takes a long time and this equates to down time. Using UNIX - Back up to magnetic tape and restore having reinitialised the file system with the mkfs command

Solid State Disks


Use flash or battery backed RAM Appear as normal disks to machine 1000s of times faster than rotating disks Unlikely to break as there's no moving parts No really cost effective money better spent elsewhere

Scalability

The network interface card (NIC) provides the connection between the network cable and the server's bus. NICs take an incoming serial stream of bits and output a parallel stream onto the bus, and vice versa. Until recently, it could be assumed that the network connection would be far slower than the CPU and bus, but LAN network speeds have been increasing faster than CPU and bus speeds, so it is no longer a safe bet that your network card can be handled by your machine (as previously mentioned)

Still, at the interface to the Internet, you can be fairly sure that your server will be more constrained by Internet access than by any other component.

NIC
NICs have on-board buffers, and a bigger buffer always gives you more flexibility Lost TCP/IP data is simply retransmitted, adding to overhead.

Memory
It is difficult to exaggerate the time difference between accessing memory and accessing disk. Although in human terms there is little perceptible difference between a single 100 nanosecond access of RAM and a single 100 millisecond access of hard disk, there is literally a factor of one million between them. The real noticeable difference comes in repeated access, when the value of having enough memory quickly becomes clear.

You might also like