|
About Linux
Hardware
Network
Installation
Partitions
Packages
Display Adapter
Server Settings
Client Settings
Bindings
Apache
Samba
Connecting to the Internet
More Information
|
Recently, I was called to be the Stake Computer Specialist. The official calling, I am told, is actually the Assistant Stake Clerk. Whatever it is, it requires me to manage the Family History Center computers in our Stake building, along with several other machines used for various purposes. I was very excited about the calling since I am currently the System Administrator at KSL Radio and Television here in Salt Lake City. In addition to managing all the servers that run the KSL website and handle the streaming audio, I also take care of the all the Internet connectivity for the DMC (Deseret Management Corporation) companies, including Beneficial Life, Deseret Book, LDS Business College, DMBA and Zions Securities.
One of the first things I did when I was informed that I needed to get the Family History Center functional again was to see about migrating some of the machines to Linux. Nearly all the servers at KSL run on Red Hat Linux. Linux is not only cost-efficient, but extremely stable. Both are required when you get as many visits and host as much bandwidth as we do here and can do so with only limited funds. Using Linux means you do NOT have to pay any licensing fees or additional costs for extra features. Nor do you have to pay every year or so when you upgrade to the next version. You cna simply download the latest Red Hat Linux image from off the Internet and then burn it to CD. Not only that but Linux represents the next step in networking and multi-tasking computers. In other words, you can do more for less. Slower machines operate just as quickly
Why am I so adamant about Linux? For a few reasons. First of all, I, like many of you, have had my share of frustrations with Windows and have been frsutrated with sometimes incomprehensible errors and crashes. Linux does not completely do away with those problems, but they are noticeably less. Secondly, Linux makes computing fun again. There is so much more you can do with Linux than with Windows and you are not limited by what others think or dictate your computer should look or act like. Thirdly, I work every day with Linux. I feel most comfortable running Linux. True, I do have a Windows machine for various tasks, but on the whole I spend 95% of my time using Linux. And lastly, I have published a couple books on Linux. My first Linux book, titled "Red Hat Linux Administrator's Guide" was approximately 850 pages and was written in a few months. My 2nd Linux book is still at the printer's awaiting publication, which may never come. My publishers are of the opinion that the Linux market is depressed and that few books are moving. However, I have hopes that sometime soon it will be printed in hard copy. I do make portions of it available to those interested. If you would like to know more about migrating from Windows to Linux on both server and workstation platforms, please contact me.
I would like to acknowledge the work of Peter Yorke, whose original page on using Linux with the Family Search program gave me the confidence to move forward on implementing Linux at our Stake Center. His page, though two and a half years old, is still very instructional. The purpose of this documentation is to stay up-to-date on the advances made in Linux and to help instruct even beginners on how to install and use Linux. Linux can be a boon to users and Stake Centers alike with limited budgets. Better to spend any excess money on hardware than to squander it on expensive software.
I am always willing to help out where I can. Feel free to contact me anytime if you have a question regarding Linux. I am still not current with all the Church applications, yet, so please consult the FHCtech.org site first if you are having problems with these particular applications. However, I am willing to help out where I can on setting up Linux as a file server.
Kerry Cox
March 20, 2002
|
|
|
ABOUT
LINUX
|
Like Peter Yorke and many other, I picked Linux as the file serving software of choice because it is free and extremely stable. Like I said earlier, I use Linux every day at my job on both workstations and servers and thoroughly enjoy it. Though I believe it is not yet ready for "prime-time", meaning end-users may not be ready to replace their Windows machines with Linux and because many vendors have not yet ported over their applications to run under Linux, it does work very well in a server-centric environment.
I also have chosen Red Hat as my preferred distribution. There are many "flavors" of Linux around from which to choose. Each is essentially the same, except for the whistles and beels that come with the installation. Red Hat supports the enterprise server variety of install and since I have been using it since the 3.0.3 release, I decided to stay with it. The most current version of Red Hat is 7.2, which will be detailed here.
This version offers several advantages over previous releases, the number one in my mind being a jouirnalling file system. You don't have to understand exactly what this means, but with the ext3 file system (a file system is the manner in which the drive is formatted, similar to the NTFS format for Windows 2000, or the FAT32 format for Windows 98) you have accountability for all files. Should the box ever be rebooted without a graceful shutdown, i.e. in the event of a power failure, there should be no corruption of data. This is a real plus over other operating systems that may damage files in the event of a system crash.
Another big advantage Red Hat has over other operating systems is that it supports software RAID. This means that you can combine two physical hard drives into one meta-device or a RAID device. Rather than having to spread files across two different drives, you cna ccreate one larger device for storing ALL files. A portion of a 40 gigabyte drive can be combined with an entire 60 gigsbyte drive to create a 70+ gigabyte device that Linux then sees as one partition. This will be necessary when storing the entire collection of Family History data. How this can be accomplished will be expounded on later in this document.
I will not go into depth here on what packages should be installed or the purposes they serve just yet, but suffice it to say that you will nee to configure Linux as a Web Server and as a Windows Networking Server. This require the Apache and Samba packages to be installed. Like the rest of Linux, they are free and come included with the regular Linux distribution. Configuring them is an easy matter, which will be addressed later on in this documentation.
Finally, here are a few comments about what Linux is and how it operates that should make this document easier to understand.
Linux is the IBM PC-compatible version of a popular operating system called Unix. In some ways Linux is (or looks like) PC DOS and its descendants; Windows and OS/2. In other important ways it is very different.
One important difference is the disk directory. In Linux there is no concept of drive letters (the ubiquitous C:\ directory. Rather than addressing a disk partition by a letter, each partition is assigned a device name. For example, the primary hard drive is called hda, and each partition on that drive is given a number. Hence, a single physical hard drive can be broken into various partitions such as /dev/hda1, /dev/hda2, /dev/hda3 and so on. The type of formatting on each partition can also vary. These can be ext2, ext3, swap, RAID, or even FAT32. Each partition on a device is then "mounted" as a subdirectory of a larger directory "tree" that represents all available disk space.
For example, there is always a "root" directory, which is represented as "/" (notice we use a forward slash, not a backslash as in Windows). All of the Family Search material appears to be in the directory named "/pool". When it is translated via Samba to Windows it appears as if it is on the H:\, I:\, J:\, K:\, L:\, M:\ and N:\ "drives". How these drive are created and mounted will be explained later on in this document.
|
|
|
HARDWARE
|
Linux runs well on less machine than its Microsoft and Novell counterparts. For my purposes I used a donated Dell 350 MHz desktop with 128 megabytes of RAM and two hard drives, one 40 gigabytes in size and the other 30 gigabytes. A slower machine would also have worked well, but like any operating system, you can never have too fast a CPU , too little RAM and too small of hard drives.
Once Linux is installed, there is usually no need for a mouse, keyboard, monitor or even a CD-ROM drive. This are necessary when first booting up, but can be removed later if needed. If needs be, Linux can use other CD-ROM drives via networked workstations for later installation or accessibility. However, for the purposes of maintenance, I like to keep all peripheral devices attached, if only to periodically work on the machine directly. Linux is very comfortable with the command line via a telnet or ssh session. Any network-attached PC can connect to Linux using a telnet client. A simple telnet client comes with nearly every Windows version. I will talk more about maintenance later on and how to configure Linux from a comamnd line interface (CLI) via a Windows machine.
The basic requirements needed for a Linux file server are as follows:
- A relatively fast CPU and motherboard, 200 MHz or faster will suit the job just fine.
- Anything more than 64 megabytes of RAM is sufficient. Given the lost cost of RAM currently this can be easily obtained.
- One or more 40+ gigabyte hard drives. These can be used individually or can be combined to create a larger RAID array.
- A CD-ROM for installing Linux from off the distribution CD.
- A 10/100 network card. 10 Mb is usually enough. Be sure to verify that your particular card is supported before purchasing the card. Check the Red Hat Hardware Compatibility List before making a purchase.
- A good video card with at least 4 megabytes of video RAM.
- Various peripherals such as mouse, keyboard, monitor, etc.
That should about do it. Anything else may be considered superfluous, though a sound card and CD-burner or tape backup may be useful items later.
|
|
|
NETWORK
|
The standard method fo networking computers is to first place a network card in a PIC ir ISA slot within the computer. I personally recommend one of the more recent 3Com or Intel network cards. These are well supported by most every release and "flavor" of Linux. The computers can then be networked with 10Base-T Cat 5 Ethernet cable. I have a big box of the Cat 5 cable and just
terminate whatever length I need. Commercially manufactured
patch cables are probably an even better choice because the
strands of wire are actually lasered onto the terminators.
But they cost more.
I think 10 Mbps is probably more than adequate
for any family history center. The 'purist' in me demands
100 Mbps, but the four donated machines had 10 Mbps NICs in
them already, so I forwent my purism.
Linux does TCP/IP like a duck treads water,
and Samba (the networking software) does IPX (which is what
Windows 95 is looking for) without even having to set parameters.
Actually, no. I did set one parameter, the name of the workgroup.
Windows defaults to "Workgroup",
so to "Workgroup" so that it would
be consistent with Windows 95.
The draft document that Salt Lake sent to
me suggests creating a separate subdirectory for each application
(/ad = Addendum, /igi = IGI, etc.) and a different drive letter
for each subdirectory (h: = /ad, j: = /igi, etc.).
I created the subdirectories in my pool space
(/pool, which is where /dev/md0 is mounted) before copying
the CDs into their respective directories.
In the Samba control file (/etc/smb.conf)
I added a resource for each logical drive I needed (/pool/af
= [af], /pool/igi = [igi], etc.). I will talk more about Samba
parameters later.
|
|
|
INSTALLATION
|
I'm not going to give a blow-by-blow account
of the installation process, just the highlights. If people
are interested in more detail I will insert that detail into
this document.
Red Hat 6.1 provides three modes of installation
(Workstation, Server and Custom) and two desktop environments
(Gnome and KDE). Just by their names one would expect that
Server would be the best choice of installation mode, but
from what I gleaned from the installation materials this didn't
give me the flexibility I felt I needed in distributing my
disk space. So I used the Custom option.
The choise of a desktop environment
is purely a religious decision. I personally like the Gnome
look-and-feel better, but KDE has a strong following. KDE
seems to have tried harder to make itself look like Windows,
which I find offensive.
|
|
|
PARTITIONS
|
Red
Hat uses Disk Druid to partition the hard drives. If you have
no need of a RAID array, for instance if you are fitting everything
onto one physical drive, then you can ignore devices hdb and
hdc in the table and all the references to RAID. Here are the
settings I used:
| Device
| Amount
| Mount Point
| Type
| Comment
|
| hda
| 16MB
| /boot
| Linux Native
| Small partition that must be below cylinder
1024
|
| hda
| 128MB
|
| Linux Swap
| Swap Space
|
| hda
| 1536MB
| /
| Linux Native
| Root (all the rest of the installation)
|
| hda
| the rest
|
| Linux RAID
| Pool Space
|
| hdb
| all
|
| Linux RAID
| Pool Space
|
| hdc
| all
|
| Linux RAID
| Pool Space
|
Once the three RAID partitions are created
you can push the button marked "Make RAID device". The ensuing
dialog will let you choose all of your Linux RAID partitions.
Create a RAID 0 device as /dev/md0. I mount this device as /pool.
That, folks, is all it takes.
The installation system does everything else that's needed,
including creating the RAID configuration file and starting
the RAID process.
|
|
|
INSTALLATION
PACKAGES
|
I made it easy on myself. I took the choice
at the very end of the list that says "Install everything".
1.5GB is plenty of disk space for everything.
If I were inclined to not install some of
the packages I would probably pick all the ones that have
to do development, rebuilding the kernel, etc.
I would not leave out any packages that have
to do with the Internet because I have a special plan in mind
that I will talk about later.
|
|
|
DISPLAY
&
ADAPTER
|
On the one hand nobody in the Family History
Center is going to be logging on to your server, so there's
not much point in dedicating a lot of time and effort into
the display and the display adaptor.
On the other had, Linux has some GUI tools
that make maintenance very easy.
The installation program should be able to
pick out what type of display adapter you have and tell you
what it is.
I just choose "generic multisync" as my display
type and everything seems to run great.
The installation probe into your hardware
may come up with the correct display adapter but it may not
know how to use all its capabilities. So if you want to use
the GUI tools (I particularily like the GUI version of Linuxconf),
go through the display adaptor configuration once more after
the installation is complete. This is done by logging on to
root and running a program. called Xconfigurator.
One of the things I have to set after the
installation is the screen resolution. The installation program
sets it at 640x480 and I prefer 1024x168.
|
|
|
NETWORK
SETTINGS:
LINUX
|
Linux network settings (like most Linux settings)
are kept in disk files mostly in /etc. A very knowledgeable
person can just go right to the right file and make what changes
need to be made. For the rest of us there is Linuxconf.
Here are a set of settings that
work. Note that I am only giving the information that is needed
for this solution:
- Config
- Networking
- Client tasks
- Basic host information
- Host name
- Adaptor 1
- Enabled = true
- Config mode = Manual
- Primary name + domain =
server
- Aliases (opt) = server.fhc.net
- IP address = 192.168.0.101
- Netmask (opt) = 255.255.255.0
- Net device = eth0
- Kernel module = ne2k-pci
(Installation figured this out)
- Name server specification (DNS)
- DNS usage = DNS
is required
- nameserver 1 = 192.168.0.101
- search domain 1 (opt) = fhc.net
- Routing and gateways
- Host name search path
- Network Information System (NIS)
- IPX interface setup
- PPP/SLIP/PLIP
- Server tasks
- Exported file systems (NFS)
- IP aliases for virtual hosts
- Apache Web server (We won't go
here right now)
- Domain Name Server (DNS) (We won't
go here, either)
- Mail delivery system (sendmail)
- Samba file server
- Defaults
- Base config
- Synchronise SMB from
Linx passwords = true
- Synchronise Linux from
SMB passwords = false
- Server description
= Samba Server
- Work group = Workgroup
- Passwords
- Encrypted password
required = false
- Authentication mode
= Share
- Map to guest = Never
- Access
- Networking
- Auto-accounts
- Features
- Default setup for users's home
- Default setup for printers
- Netlogon setup
- Disk shares
-
| Share
| Comment
| Directory
|
| pool
| RAID
drive
| /pool
|
| af
| Ancestral
File
| /pool/af
|
| igi
| International
Genealogical Index
| /pool/igi
|
| ad
| International
Genealogical Index Addendum
| /pool/ad
|
| lc
| Family
History Library Catalog
| /pool/lc
|
| mi
| Military
Index
| /pool/mi
|
| scr
| Scottish
Church Records
| /pool/scr
|
| ss
| Social
Security Death Index
| /pool/ss
|
All these shares should be marked "enabled",
"Browsable", "Public
access" and "Writable".
- Ftp server (wu-ftp)
- Misc
- Information about other hosts
-
| IP number
| name & aliases
|
| 127.0.0.1
| localhost
localhost.localdomain
|
| 192.168.0.101
| server server.fhc.net
|
- Information about other networks
- Linuxconf network access
- Users accounts
- Normal
- User accounts (Add this new user)
- The account is enbaled = true
- Login name = smbuser
- Full name = Samba
User
- group = smb
- Supplementary groups
- Home directory(opt) = /home/public
- Command interpreter(opt) =
/bin/bash
- User ID(opt) = Let
Linuxconf pick it
- Group definitions
- Change root password
- Special Accounts
- Email aliases
- Policies
- File systems
- Miscellaneous services
- boot mode
- Control
|
|
|
NETWORK
SETTINGS:
WINDOWS
|
The
Windows (95) network settings can be found at Start-Settings-Control
Panel-Network, Or the "Properties" menu item when right mouse
clicking Network Neighborhood. Again, this is what works for
me:
- applications
- Installed network components
- Client for Microsoft Networks
- Log on to Windows NT domain
= false
- Windows NT Domain = leave
blank
- Logon and restore network connections
= true
- 3Com EtherLInk 10/100 PCI for Complete
PC Management - This depends on your Network Interface Card
- 3Com TCAATDI Diagnostic TDI - This
depends on your Network Interface Card
- IPX/SPX-compatible Protocol - No
changes here
- NetBEUI - No changes
here
- TCP/IP
- IP Address
- Specify an IP Address
- IP Address = 192.168.0.102
- Subnet Mask = 255.255.255.0
- WINS Configuration
- Gateway
- DNS Configuration
- Bindings
- Advanced
- NetBIOS
- File and printer sharing for Microsoft
Networks
- Primary Network Logon
- File and Print Sharing (The Big Button)
- I want to be able to give others
access to my files = true
- I want to be able to allow others
to print to my printer(s). = true
- Identification
- Computer Name = (just
pick a name)
- Workgroup = Workgroup
- Computer Description = whatever
you want
- Access Control
- Share-level access control = true
|
|
|
SECURITY
|
Okay, I'll admit it. I have built practically
no security at all into this system. Everyone logs onto the
Windows machines as guest and all the Samba shares are at
the share level.
And, to boot, my root password is....password.
Oh well.
|
|
|
BINDINGS
|
Based
on the partitioning scheme for the /pool area, I have created
the following drive bindings:
- J: = \\server\ad
- K: = \\server\af
- L: = \\server\igi
- M: = \\server\lc
- N: = \\server\mi
- O: = \\server\scr
- P: = \\server\ss
- W: = \\server\pool
Furthermore, when you install FamilySearch program
on W:, using the 'install network' method, be sure and put these
drives in. |
|
|
FOR
THE
FUTURE
|
Earlier in this document I said I would talk
about Apache. Apache is a full-featured web server that comes
free with Linux. In other words one of the computers on my
network could start their favorite browser and point it to
the Linux server and actually get something back.
I have started, and will be working on for
a while I'm afraid, an online training course that will be
available from all of the computers in the Family History
Center.
Not only will there be a tutorial
for everything a person needs to know in the Family History
Center, but there will also be "How do I ..." sections.
|
|
|
FOR
MORE
INFORMATION
|
Search
the FHC Tech email list for Linux information.
|
|
|