Introduction to Creating a File ServerBy Eric RinkerThe following is a general guide to building a file server, for the inexperienced system administrator. While the principles are applicable to any system, the specifics are targeted towards a UNIX operating system. Both hardware and software concerns are addressed. This article focuses on system design, leaving the exact implementation up to the reader. The PhysicalWhen building a file server, the number one concern for that file server is to always have the data available. Data capacity, network connections, access methods, and so on, are all important factors in building a file server -- but not if that server is down. It doesn't matter how well a server can perform if that server is not performing at all. A server's availability is often referenced in terms of percentage of uptime. Typically, management sets this percentage based on the needs of the organization and a cost-to-benefit analysis. For example, a company may wish its web server to have a 99.5% uptime, which means in any one-year period, the server is to be unavailable for no more than 43 hours. But that same company might not want to spend the "x" amount of money it would cost to achieve that uptime, and instead opt for less availability, at the price range that fits the company's budget. A system's uptime is a function of its fault-tolerance. Redundant parts are used to prevent any one piece from failing and bringing the system to an unusable state. Hardware RAID devices are an example, allowing one drive in the array to fail without any impact on the performance or access to the data on that array. While a completely redundant system is possible in most cases, it is also cost prohibitive. It is best to focus on making redundant those pieces that are more likely to fail -- or that are the most critical -- and purchasing stand-by replacements for everything else. The primary concerns when dealing with a file server are its data storage devices. There are two aspects of storage to consider: the boot device, and the data store. Both can be physically located on the same device, but it is not recommended. Each device has different requirements for its protection, and this would complicate matters if the two shared hardware. The boot device contains your operating system and any applications required to make your system a viable file server. Hard drives are big enough today to allow for this data to typically fit entirely on one drive. The loss of this drive, while inconvenient and detrimental to productivity, would not be a complete disaster. A reinstall of the OS and tools would bring you back to the same place you were before the fault occurred. As such, redundancy is not a requirement but a convenience. A mirror of the boot device will suffice in protecting the time invested in the system configuration without adding much addition cost. After the boot drive fails and the system goes down, a reconfiguration of the server will have it booting the mirrored drive and running as if nothing has happen. Hardware solutions are best for providing this ability, since some products can avoid the system going down and automatically switch the boot drive. Software solutions typically create extra system overhead, but also come at a lower cost. The data drive has the files the system will be serving. These files are the unique, irreplaceable work of the company's employees. They require as much protection as can be afforded, and so this drive should have as much redundancy as possible. This logical drive should be physically located on multiple hard drives, using RAID 5. RAID 5 keeps copies of the data of one drive scattered across the other drives in the array. This allows one hard drive to die without any loss of data. The array should have at least one hard drive in standby mode to immediately replace a failure without any human interaction. After the first drive fails and is switched to the standby, the RAID will not become a single point of failure because it can handle a second drive malfunction before any physical intervention is required. Finally, another RAID array can be set up as a mirror of the first, to ensure that the array itself is redundant. The other pieces of the system do not require online replacement for the average file server role. The cheapest method of protection is just to have an extra part handy in case the first one fails. The motherboard, power supply, network card, keyboard, and so on, can normally be replaced in less than an hour from time of shutdown to time of boot up. Unless you have strict uptime requirements (95%+), you can probably get away with this downtime without impact on your performance metrics.
The LogicalThere is no final answer on how to configure your operating system. The following are some of the most common topics that you should be aware of when designing and implementing your system. File System Layout Reasons still exist for creating more partitions than just If you want a Performance concerns would have you scatter partitions across multiple hard drives to increase access time. While the SWAP Applications/Services The method of file access determines the service you should be running. For UNIX clients, NFS will need to be configured. Samba or an equivalent application is required to service Windows machines. A web server like Apache will be needed for HTTP traffic. A secure FTP server such as ProFTPD should be used to serve FTP clients. Other ways to access files are available, but these are the common ones.
What Comes NextYou should now have a fair understanding of the common dilemmas faced when designing a file server. Specific implementations can vary from vendor to vendor, but should fit with the framework detailed in this article. To further your knowledge, here are some other resources that might come in handy:
Unless otherwise licensed, code in all technical manuals herein (including articles, FAQs, samples) is provided under this License. |
|