📄 395-399.html
字号:
<HTML>
<HEAD>
<TITLE>Linux Configuration and Installation:Linux Networking</TITLE>
<META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">
<SCRIPT>
<!--
function displayWindow(url, width, height) {
var Win = window.open(url,"displayWindow",'width=' + width +
',height=' + height + ',resizable=1,scrollbars=yes');
}
//-->
</SCRIPT>
</HEAD>
-->
<!--ISBN=1558285660//-->
<!--TITLE=Linux Configuration and Installation//-->
<!--AUTHOR=Patrick Volkerding//-->
<!--AUTHOR=Kevin Reichard//-->
<!--AUTHOR=Eric Foster//-->
<!--PUBLISHER=IDG Books Worldwide, Inc.//-->
<!--IMPRINT=M & T Books//-->
<!--CHAPTER=8//-->
<!--PAGES=395-399//-->
<!--UNASSIGNED1//-->
<!--UNASSIGNED2//-->
<CENTER>
<TABLE BORDER>
<TR>
<TD><A HREF="../ch07/392-394.html">Previous</A></TD>
<TD><A HREF="../ewtoc.html">Table of Contents</A></TD>
<TD><A HREF="399-400.html">Next</A></TD>
</TR>
</TABLE>
</CENTER>
<P><BR></P>
<H2><A NAME="Heading1"></A><FONT COLOR="#000077">Chapter 8<BR>Linux Networking
</FONT></H2>
<P>This chapter covers:
</P>
<DL>
<DD><B>•</B> TCP/IP
<DD><B>•</B> System administration and networking
<DD><B>•</B> The <B>fwhois</B> command
</DL>
<H3><A NAME="Heading2"></A><FONT COLOR="#000077">Networking and Linux</FONT></H3>
<P>One of the great appeals of the Linux operating system is its built-in networking connectivity. Instead of trying to make an operating system like DOS, Microsoft Windows, or MacOS deal with a network, you can work with Linux, where the network exists at the core of the operating system.
</P>
<P>This is accomplished through TCP/IP (Transmission Control Protocol/Internet Protocol), which has become the <I>lingua franca</I> for networking in the UNIX world. Because UNIX-based systems were instrumental in forming the Internet and its predecessors, TCP/IP became the dominant protocol for communication on the Internet. TCP/IP is the major tool for networking UNIX-based computer systems, as most UNIX implementations contain support for TCP/IP. Other operating systems, such as DOS and OS/2, can also connect to TCP/IP networks, although this requires special add-on software.</P>
<P>Linux comes with full support for TCP/IP (provided you installed it when you installed Linux; if not, you’ll need to look at reinstalling Linux or recompiling your kernel). This support comes in the form of the NET-3 set of protocols and programs. On your end, connecting to a UNIX network via TCP/IP is merely a matter of making sure your PC is correctly hooked up to the network via Ethernet card and cabling.</P>
<BLOCKQUOTE>
<P><FONT SIZE="-1"><HR><B>NOTE: </B>Much of what’s involved with Linux networking is best performed at the sysadm level. If you’re a system administrator, you should follow your own configuration routines at the network level; after all, Linux installs and configures pretty much like any other PC UNIX on the network level. If you’re not a system administrator, we suggest you check out Olaf Kirch’s <I>Linux Network Administrator’s Guide</I>, which can be found on the accompanying CD-ROM or in print at your local bookstore.<HR></FONT>
</BLOCKQUOTE>
<P>In Chapter 1 we covered supported Ethernet cards. If you need more information about setting up your Ethernet card, check out the <B>ETHERNET-HOWTO</B> on the accompanying program CD-ROM, in the <B>docs</B> directory.</P>
<P>Linux also allows you to make a TCP/IP connection via telephone line, using the SLIP or PPP protocol. If you want to connect to the Internet via a dialup connection, you’ll need to use these tools. (We cover this in more depth in Chapter 9.)</P>
<P>Before you try using any of these tools, you should have some background in TCP/IP. We advise checking out Olaf Kirch’s <I>Linux Network Administrator’s Guide</I>, which has been printed by various sources (including the Linux Documentation Project and SSC).</P>
<P>In addition, the CD-ROM contains a very useful, detailed guide to TCP/IP networking and NET-3 in the form of <B>NET-2-HOWTO</B>, in the <B>docs</B> directory.</P>
<P>These guides should form the basis of your networking expertise. However, we’ll provide a short overview of TCP/IP networking here.</P>
<H3><A NAME="Heading3"></A><FONT COLOR="#000077">TCP/IP Basics</FONT></H3>
<P>Under a TCP/IP network, every computer on the network is assigned an IP address, including your computer. If your Linux workstation is permanently connected to a TCP/IP network, this address will remain constant. (If you’re using a dialup connection to the Internet through a service provider, your IP address will be dynamically assigned when you login the service.) This address comes in four fields, such as <I>255.255.0.0</I>. This breaks down to:</P>
<DL>
<DD><I>subdomain.subdomain.domain.domain</I>
</DL>
<P>You will find detailed information on IP addresses, how they’re structured, and how you can acquire them on the second accompanying CD-ROM. We’re not going to spend a lot of time on the intricacies of IP addresses; it’s an involved subject beyond the reach of this book.
</P>
<P>From your end, IP addresses are important for connecting to another computer on the network. (By this, we mean the <I>entire network</I>, which can include the rest of the world if you’re connected to the Internet.) However, in many situations you don’t need to know the specific IP address to make a connection, as you probably discovered when you see lists of Internet addresses (such as those found in Appendix A) without any IP addresses listed. Why’s that? Because early in the Internet’s development the decision was made to allow a Domain Name Server (DNS) to handle these dirty details. Your TCP/IP network (or your service provider) has a named DNS somewhere on the network. When you enter an Internet address like <A HREF="ftp.x.org">ftp.x.org</A> or a mail address like <B>reichard@mr.net</B>, a lookup is performed on the DNS, which then makes sure that the mail or request is routed to the proper machine. If you’ve installed TCP/IP on your system, you’ll be running a daemon named <B>named</B> that handles the connections to the DNS.</P>
<P>The <B>fwhois</B> command connects to the DNS and returns information about a specific user or a domain name:</P>
<!-- CODE //-->
<PRE>
gilbert:~$ fwhois mr.net
Minnesota Regional Network (MR-DOM)
511 11th Avenue South, Box 212
Minneapolis, MN 55415
Domain Name: MR.NET
....
Record last updated on 16-Nov-93
Domain servers in listed order:
NS.MR.NET 137.192.240.5
RS0.INTERNIC.NET 198.41.0.5
RIVERSIDE.MR.NET 137.192.2.5
SPRUCE.CIC.NET 35.42.1.100
gilbert:~$ fwhois dfazio@mr.net
Fazio, Dennis (DF202) dfazio@mr.net
Minnesota Regional Network (MR-DOM)
511 11th Avenue South, Box 212
Minneapolis, MN 55415
Record last updated on 16-Dec-91
</PRE>
<!-- END CODE //-->
<P>The <B>fwhois</B> command also lists users on your Linux system, even if you’re not connected to the Internet.</P><P><BR></P>
<CENTER>
<TABLE BORDER>
<TR>
<TD><A HREF="../ch07/392-394.html">Previous</A></TD>
<TD><A HREF="../ewtoc.html">Table of Contents</A></TD>
<TD><A HREF="399-400.html">Next</A></TD>
</TR>
</TABLE>
</CENTER>
</td>
</tr>
</table>
<!-- begin footer information -->
</body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -