By Kato Mivule
In this article we take a look at some of the Memory Management Strategies discussed by Silberschatz et al and how they could be beneficial to memory management in Web Servers.
Concrete definitions of ‘Web Server’ is hard to come by but PC Magazine states that a web server is a computer that runs a website using http protocol.  Web Servers are special computer programs that allow simultaneous access of data across the internet. Therefore a web server would require robust memory and storage resources.
This means that you could have thousands of entities that include programs and people requesting access to the web server, thus consuming a number of resources. At the same time, thousands of entities could be requesting storage access on the web server and retrieval of stored items. A web server administrator would do well to consider the following Management Strategies:
Swapping: As articulated by Silberschatz et al, a process must be in memory to be executed. The same process can be swapped in and out temporarily out of memory to a backing store then resumed for execution.  In the case of web servers, some processes can be swapped so as to give room for real time or critical processes that don’t take long to execute. In such circumstances, large backing store capacities would be required to temporarily store swapped processes.
Contiguous Memory Allocation: Memory is divided in two partitions, for the resident operating system and one for the user processes as described by Silberschatz et al. The operating system is then placed in either the lower or higher memory. This would be beneficial for web servers as the web server operating system is given its won allocation to run efficiently while user processes can then be allocated the remaining part of memory. Since web servers have to process thousands of transactions, a Swapping – Contiguous memory allocation hybrid would be employed so as to further optimize user processes.
Paging: According to Silberschatz et al, in this memory management strategy, the physical address space of a process is allowed to be non contagious, avoiding fragmentation, and also using the backing store. However, backing stores are vulnerable to fragmentation and thus making swapping and memory allocation slower.  With paging memory is broken into blocks called frames and pages. When a process is going to be executed, its pages are preloaded into any available frames from their storage.   Therefore paging would be a very good optimization memory management strategy to implement with web servers by bypassing fragmentation and avoiding dependence on backing store.
Segmentation: Segmentation divides a program or process into smaller blocks called segments. Silberschatz et al describes segmentation as a memory management scheme that supports the user view of memory that sees memory as a collection of variable sized segments.  According to Dhotre, segmentation eliminates fragmentation, provides virtual memory, makes memory visible, and allows dynamic segment growth, though setbacks include restricted segment size by main memory.  Therefore the advantages of segmentation would still be beneficial for optimizing memory utilization in web servers as virtual memory would be readily available. The overheads of restricted memory size by main memory can be over come as the price of main memory has decreased while the amount of memory size has increased.
Therefore I would suggest a hybrid approach in management of memory when it comes to web servers. The hybrid approach would include Swapping, Contiguous Memory Allocation, Paging, and Segmentation strategies. The definite ‘game changer’ in this hybrid strategy is the economics involved. The price of memory continues to decrease while the size of memory is increasing significantly. Therefore more studies are needed to show the impact of large and available memory in regards to this hybrid approach.
Sources and References
 “Web server Definition from PC Magazine Encyclopedia.” [Online]. Available: http://www.pcmag.com/encyclopedia_term/0,2542,t=Web+server&i=54342,00.asp. [Accessed: 12-Oct-2010].
 Abraham Silberschatz, Peter B. Galvin, Greg Gagne, Operating system concepts, Edition 9, illustrated, J. Wiley & Sons, 2009, ISBN 978-0-470-12872-5, Page 315-350.
 Daniel Pierre Bovet, Marco Cesatí, Understanding the Linux Kernel, O’Reilly Series, Edition 3 illustrated, O’Reilly Media, Inc., 2005, ISBN 0596005652, 9780596005658, Page 46.
 I.A.Dhotre, Operating Systems, Technical Publications, 2009, ISBN 8184311699, 9788184311693, Page 28