The Home Linux Server and Gateway
Of course, it would be wonderful to live completely free of a Microsoft product, but such is often impractical in this day and age. Fortunately, Linux is able to accommodate the needs of popular PC operating systems quite easily. Two such Linux products that will work wonderfully with your home network are Samba and IP Masquerading. You can use each in your home network, and this assumes, by the way, that you have already connected your computers with ethernet and with Network Interface Cards (NICs), and that you configured your network properly. (See the Ethernet HOWTO for further instructions.)
Samba
Samba servers, or Session Management Block servers, are quite popular among Linux and Unix networks. Samba enables devices on your Linux server, such as disks and printers, to be shared with Windows 95, NT, or Warp or other PC clients as though they were other Microsoft NetBIOS clients. Samba emulates the LANManager software from Microsoft, so whatever client can interface with LANManager can talk with Samba.
The home power user probably has multiple computers at home in his or her office. That's ideal for experimentation with different platforms and for learning about networks. The authoritative resource for learning Samba details is the Linux SMB HOWTO by David Wood. Configuring for Windows 95 is relatively simple, and the result is that resources on your Linux server appear as icons in your Network Neighborhood folder on your Windows 95 desktop. This is very handy, because you can simply click on your home directory, for example, and drag an object from your linux box and drop it on your Windows desktop, and the file is instantly copied. This saves you from having to ftp it between the two boxes. Very convenient. You may also have write permission to your Linux home directory, but I would recommend not turning that permission on if you are at all security conscious.
If you're running Red Hat Linux or a similar distribution, you probably already have installed Samba. You can check by typing the following command:
ps -ax | grep smbd
You'll see the grep command listed, at least, and you'll also a smbd process running if you have it installed. If it isn't running, then you just need to install it as you normally install software with your distribution (ie, with RPM, pkg, tgz, deb, or what have you), and configure the appropriate files. If the smbd daemon is already running, then you just need to configure your /etc/smb.conf file. The HOWTO tells you how to compile, install, and configure Samba.
Once you have configured and tested Samba, you will be able to share disk drives, folders, printers, databases, and nearly whatever you want between Windows, Warp, and Linux. Since there are some applications that we know and love from Windows (such as Quicken and InternetPhone), sharing resources cooperatively is the best way toward maximum productivity.
IP Masquerading
With all your computers at home networked together, it scarcely makes sense to put each machine on a modem and its own separate phone line. A better solution is to designate one computer as a gateway to the Internet for your network. This way, each of your computers may access the Internet through a dedicated connection to your gateway computer. The gateway computer may connect as needed when your other computers need to access the Internet. Your gateway computer may have a dynamically assigned IP number or a static IP number. This computer will actually have two IP numbers, one for the Internet, and one for your local network.
It makes even more sense to protect your internal network computers with some sort of firewall, especially if your network will be connected for extended periods of time.
Later Linux kernels all are capable of doing IP Masquerading. They all possess the code, so all you have to do is compile your kernel with those modules. The details of configuring your kernel for IP Masquerading are in the Linux IP Masquerading mini-HOWTO by Ambrose Au.
Once you've compiled your kernel correctly, you have to modify your /etc/rc.d/rc.local file with the ipfwadm commands that tell your kernel how to route packets to and from your network client computers. When you've accomplished this and rebooted your new kernel, your client computers are ready to browse, chat, InternetPhone, telnet, and ftp through your gateway computer to the Internet.
Of course, this assumes you've already constructed a valid network and configured your hardware and software according to the Linux Ethernet HOWTO and the Linux Net2 HOWTO and the Linux Network Administrator's Guide. Basically, you'll probably have a class C network with IP numbers assigned ranging from 192.168.1.1 to 192.168.254.254. If you need more IP numbers than this, then you're building a bigger network than I intended to discuss in this article!
Now you just have to set up your Windows box(es) so that your Linux computer is your gateway. (Click on your network icon in your Control Panel, select your Gateway tab, and type in the local IP number of your gateway computer. Also, set up the same DNS servers in Windows that you have in your /etc/resolv.conf file.) Once you reboot your Windows computer, you can click on your Internet icon and start up your web browser, and, if your Linux gateway is already connected to your ISP, your Windows web browser will behave just as if it's directly connected to the Internet. So will nearly all your other Windows clients: IRC, ftp, telnet, InternetPhone, realaudio, CU-Seeme etc. There are a few exceptions with older kernels, however. Sometimes you must obtain additional modules that are added to /lib/modules/2.0.XX/ipv4/, where XX is the number of the production kernel that you are running.
One note for your Windows boxes is to not define a proxy server. Even though IP Masquerading behaves a little like a proxy server/firewall, you don't need to set up your Internet clients for a proxy server. However, if you wish to use anti-spam proxies like Junkbuster (see http://www.junkbuster.com) for your web browser, you can do so. IP Masquerading will accommodate it. You should realize that your IP Masquerading Linux gateway gives you perhaps even better firewall protection than a proxy server, if you've configured everything properly. (You should run a single Linux box as a gateway, however, with only bare essentials on it, and no user accounts, no telnetd, etc. Read a book on security and firewalls, such as Building Internet Firewalls and The Practial Guide to Unix and Internet Security, both from O'Reilly.)
If you can't put together a dedicated gateway box yet, then don't stay connected to your ISP all the time, and try and keep a console in front of you that pipes all system messages to your xconsole. You could add the following line to your /etc/syslog.conf:
# Warn users of everything! (For the paranoid only...) *.* /dev/consoleNow when you run xconsole, you'll see that it's quite chatty. Hopefully this will not annoy you, and it will keep you informed of what is going on with your system. When someone tries to log in, you see it!
Another caution would be to first test-browse an Internet host by its IP number rather than its domain name. This way, if you have a problem with your DNS configuration, you will be able to test just your IP Masquerading configuration first. Try pointing your browser to http://198.95.249.78 and see if you get Netscape's homepage. If you get Netscape's homepage, then your IP Masquerading works properly.
If you don't see the page, then you should check and see whether you've compiled the kernel properly and whether you're loading the correct IP Masquerading modules. Then you should check and see whether your ipfwadm commands are correct in /etc/rc.d/rc.local, or whatever startup script you've decided to put them in. You can even issue the ipfwadm commands by hand and see whether you're getting errors. Read the HOWTO for more details on troubleshooting IP Masquerading.
Diald
A final addition to your network should be the ``diald'' daemon. This daemon listens for incoming packets from your network clients, and when it detects a computer on your network trying to connect with the Internet, it will dial your ISP and bring up your Internet connection.
On my home network, my wife's computer is in a bedroom, and my gateway computer is in my office in the basement. All my wife has to do is click on her ``Internet'' icon from her Windows 95 desktop, and my gateway computer dials our ISP and brings up the connection. It looks to her as though we have a dedicated Internet connection.
Diald can also be configured to let you dial into your home gateway computer and let you connect to your ISP from a remote location. You would need two modems to do this, but you probably have a few extras lying around anyway.
Conclusion
Linux gives you enormous flexibility. Being a full-blown network operating system, you'll be amazed at how productive you can become when you use it as your main gateway and server in your home network. If you're coming from a Windows/DOS or Warp background, and if you've acquired a graveyard of computers over the years, you'll be happy to see how Linux can breathe new life into those computers, since all of the tasks I've mentioned above require very few computer resources and can run very comfortably on a 486 with 16MB of RAM. When you run Linux, you'll soon feel like wearing a t-shirt that says, ``Born to Network!''