old-www/LDP/intro-linux/html/sect_10_02.html

1093 lines
23 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML
><HEAD
><TITLE
>Network configuration and information</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.7"><LINK
REL="HOME"
TITLE="Introduction to Linux"
HREF="index.html"><LINK
REL="UP"
TITLE="Networking"
HREF="chap_10.html"><LINK
REL="PREVIOUS"
TITLE="Networking Overview"
HREF="sect_10_01.html"><LINK
REL="NEXT"
TITLE="Internet/Intranet applications"
HREF="sect_10_04.html"></HEAD
><BODY
CLASS="sect1"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><DIV
CLASS="NAVHEADER"
><TABLE
SUMMARY="Header navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TH
COLSPAN="3"
ALIGN="center"
>Introduction to Linux: </TH
></TR
><TR
><TD
WIDTH="10%"
ALIGN="left"
VALIGN="bottom"
><A
HREF="sect_10_01.html"
ACCESSKEY="P"
>Prev</A
></TD
><TD
WIDTH="80%"
ALIGN="center"
VALIGN="bottom"
>Chapter 10. Networking</TD
><TD
WIDTH="10%"
ALIGN="right"
VALIGN="bottom"
><A
HREF="sect_10_04.html"
ACCESSKEY="N"
>Next</A
></TD
></TR
></TABLE
><HR
ALIGN="LEFT"
WIDTH="100%"></DIV
><DIV
CLASS="sect1"
><H1
CLASS="sect1"
><A
NAME="sect_10_02"
></A
>10.2. Network configuration and information</H1
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="sect_10_02_01"
></A
>10.2.1. Configuration of network interfaces</H2
><P
>All the big, userfriendly Linux distributions come with various graphical tools, allowing for easy setup of the computer in a local network, for connecting it to an Internet Service Provider or for wireless access. These tools can be started up from the command line or from a menu:</P
><P
></P
><UL
><LI
><P
>Ubuntu configuration is done selecting <SPAN
CLASS="guimenu"
>System</SPAN
>-&gt;<SPAN
CLASS="guimenuitem"
>Administration</SPAN
>-&gt;<SPAN
CLASS="guisubmenu"
>Networking</SPAN
>.</P
></LI
><LI
><P
>RedHat Linux comes with <B
CLASS="command"
>redhat-config-network</B
>, which has both a graphical and a text mode interface.</P
></LI
><LI
><P
>Suse's YAST or YAST2 is an all-in-one configuration tool.</P
></LI
><LI
><P
>Mandrake/Mandriva comes with a Network and Internet Configuration Wizard, which is preferably started up from Mandrake's Control Center.</P
></LI
><LI
><P
>On Gnome systems: <B
CLASS="command"
>gnome-network-preferences</B
>.</P
></LI
><LI
><P
>On KDE systems: <B
CLASS="command"
>knetworkconf</B
>.</P
></LI
></UL
><P
>Your system documentation provides plenty of advice and information about availability and use of tools.</P
><P
>Information that you will need to provide:</P
><P
></P
><UL
><LI
><P
>For connecting to the local network, for instance with your home computers, or at work: hostname, domainname and IP address. If you want to set up your own network, best do some more reading first. At work, this information is likely to be given to your computer automatically when you boot it up. When in doubt, it is better not to specify any information than making it up.</P
></LI
><LI
><P
>For connecting to the Internet: username and password for your ISP, telephone number when using a modem. Your ISP usually automatically assigns you an IP address and all the other things necessary for your Internet applications to work.</P
></LI
></UL
></DIV
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="sect_10_02_02"
></A
>10.2.2. Network configuration files</H2
><P
>The graphical helper tools edit a specific set of network configuration files, using a couple of basic commands. The exact names of the configuration files and their location in the file system is largely dependent on your Linux distribution and version. However, a couple of network configuration files are common on all UNIX systems:</P
><DIV
CLASS="sect3"
><H3
CLASS="sect3"
><A
NAME="sect_10_02_02_01"
></A
>10.2.2.1. /etc/hosts</H3
><P
>The <TT
CLASS="filename"
>/etc/hosts</TT
> file always contains the <EM
>localhost</EM
> IP address, 127.0.0.1, which is used for interprocess communication. Never remove this line! Sometimes contains addresses of additional hosts, which can be contacted without using an external naming service such as DNS (the Domain Name Server).</P
><P
>A sample <TT
CLASS="filename"
>hosts</TT
> file for a small home network:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 localhost.localdomain localhost
192.168.52.10 tux.mylan.com tux
192.168.52.11 winxp.mylan.com winxp
</PRE
></FONT
></TD
></TR
></TABLE
><P
>Read more in <B
CLASS="command"
>man <TT
CLASS="filename"
>hosts</TT
></B
>.</P
></DIV
><DIV
CLASS="sect3"
><H3
CLASS="sect3"
><A
NAME="sect_10_02_02_02"
></A
>10.2.2.2. /etc/resolv.conf</H3
><P
>The <TT
CLASS="filename"
>/etc/resolv.conf</TT
> file configures access to a DNS server, see <A
HREF="sect_10_04.html#sect_10_04_07"
>Section 10.3.7</A
>. This file contains your domain name and the name server(s) to contact:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;search mylan.com
nameserver 193.134.20.4
</PRE
></FONT
></TD
></TR
></TABLE
><P
>Read more in the <TT
CLASS="filename"
>resolv.conf</TT
> man page.</P
></DIV
><DIV
CLASS="sect3"
><H3
CLASS="sect3"
><A
NAME="sect_10_02_02_03"
></A
>10.2.2.3. /etc/nsswitch.conf</H3
><P
>The <TT
CLASS="filename"
>/etc/nsswitch.conf</TT
> file defines the order in which to contact different name services. For Internet use, it is important that <EM
>dns</EM
> shows up in the <SPAN
CLASS="QUOTE"
>"hosts"</SPAN
> line:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;<TT
CLASS="prompt"
>[bob@tux ~]</TT
> <B
CLASS="command"
>grep hosts /etc/nsswitch.conf</B
>
hosts: files dns
</PRE
></FONT
></TD
></TR
></TABLE
><P
>This instructs your computer to look up hostnames and IP addresses first in the <TT
CLASS="filename"
>/etc/hosts</TT
> file, and to contact the DNS server if a given host does not occur in the local <TT
CLASS="filename"
>hosts</TT
> file. Other possible name services to contact are LDAP, NIS and NIS+.</P
><P
>More in <B
CLASS="command"
>man <TT
CLASS="filename"
>nsswitch.conf</TT
></B
>.</P
></DIV
></DIV
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="sect_10_02_03"
></A
>10.2.3. Network configuration commands</H2
><DIV
CLASS="sect3"
><H3
CLASS="sect3"
><A
NAME="sect_10_02_03_01"
></A
>10.2.3.1. The ip command</H3
><P
>The distribution-specific scripts and graphical tools are front-ends to <B
CLASS="command"
>ip</B
> (or <B
CLASS="command"
>ifconfig</B
> and <B
CLASS="command"
>route</B
> on older systems) to display and configure the kernel's networking configuration.</P
><P
>The <B
CLASS="command"
>ip</B
> command is used for assigning IP addresses to interfaces, for setting up routes to the Internet and to other networks, for displaying TCP/IP configurations etcetera.</P
><P
>The following commands show IP address and routing information:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;<TT
CLASS="prompt"
>benny@home benny&#62;</TT
> <B
CLASS="command"
>ip addr show</B
>
1: lo: &#60;LOOPBACK,UP&#62; mtu 16436 qdisc noqueue
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 brd 127.255.255.255 scope host lo
inet6 ::1/128 scope host
2: eth0: &#60;BROADCAST,MULTICAST,UP&#62; mtu 1500 qdisc pfifo_fast qlen 100
link/ether 00:50:bf:7e:54:9a brd ff:ff:ff:ff:ff:ff
inet 192.168.42.15/24 brd 192.168.42.255 scope global eth0
inet6 fe80::250:bfff:fe7e:549a/10 scope link
<TT
CLASS="prompt"
>benny@home benny&#62;</TT
> <B
CLASS="command"
>ip route show</B
>
192.168.42.0/24 dev eth0 scope link
127.0.0.0/8 dev lo scope link
default via 192.168.42.1 dev eth0
</PRE
></FONT
></TD
></TR
></TABLE
><P
>Things to note:</P
><P
></P
><UL
><LI
><P
>two network interfaces, even on a system that has only one network interface card: <SPAN
CLASS="QUOTE"
>"lo"</SPAN
> is the local loop, used for internal network communication; <SPAN
CLASS="QUOTE"
>"eth0"</SPAN
> is a common name for a <EM
>real</EM
> interface. Do not ever change the local loop configuration, or your machine will start mallfunctioning! Wireless interfaces are usually defined as <SPAN
CLASS="QUOTE"
>"wlan0"</SPAN
>; modem interfaces as <SPAN
CLASS="QUOTE"
>"ppp0"</SPAN
>, but there might be other names as well.</P
></LI
><LI
><P
>IP addresses, marked with <SPAN
CLASS="QUOTE"
>"inet"</SPAN
>: the local loop always has 127.0.0.1, the physical interface can have any other combination.</P
></LI
><LI
><P
>The hardware address of your interface, which might be required as part of the authentication procedure to connect to a network, is marked with <SPAN
CLASS="QUOTE"
>"ether"</SPAN
>. The local loop has 6 pairs of all zeros, the physical loop has 6 pairs of hexadecimal characters, of which the first 3 pairs are vendor-specific.</P
></LI
></UL
></DIV
><DIV
CLASS="sect3"
><H3
CLASS="sect3"
><A
NAME="sect_10_02_03_02"
></A
>10.2.3.2. The ifconfig command</H3
><P
>While <B
CLASS="command"
>ip</B
> is the most novel way to configure a Linux system, <B
CLASS="command"
>ifconfig</B
> is still very popular. Use it without option for displaying network interface information:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;<TT
CLASS="prompt"
>els@asus:~$</TT
> <B
CLASS="command"
>/sbin/ifconfig</B
>
eth0 Link encap:Ethernet HWaddr 00:50:70:31:2C:14
inet addr:60.138.67.31 Bcast:66.255.255.255 Mask:255.255.255.192
inet6 addr: fe80::250:70ff:fe31:2c14/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:31977764 errors:0 dropped:0 overruns:0 frame:0
TX packets:51896866 errors:0 dropped:0 overruns:0 carrier:0
collisions:802207 txqueuelen:1000
RX bytes:2806974916 (2.6 GiB) TX bytes:2874632613 (2.6 GiB)
Interrupt:11 Base address:0xec00
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:765762 errors:0 dropped:0 overruns:0 frame:0
TX packets:765762 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:624214573 (595.2 MiB) TX bytes:624214573 (595.2 MiB)
</PRE
></FONT
></TD
></TR
></TABLE
><P
>Here, too, we note the most important aspects of the interface configuration:</P
><P
></P
><UL
><LI
><P
>The IP address is marked with <SPAN
CLASS="QUOTE"
>"inet addr"</SPAN
>.</P
></LI
><LI
><P
>The hardware address follows the <SPAN
CLASS="QUOTE"
>"HWaddr"</SPAN
> tag.</P
></LI
></UL
><P
>Both <B
CLASS="command"
>ifconfig</B
> and <B
CLASS="command"
>ip</B
> display more detailed configuration information and a number of statistics about each interface and, maybe most important, whether it is <SPAN
CLASS="QUOTE"
>"UP"</SPAN
> and <SPAN
CLASS="QUOTE"
>"RUNNING"</SPAN
>.</P
></DIV
><DIV
CLASS="sect3"
><H3
CLASS="sect3"
><A
NAME="sect_10_02_03_03"
></A
>10.2.3.3. PCMCIA commands</H3
><P
>On your laptop which you usually connect to the company network using the onboard Ethernet connection, but which you are now to configure for dial-in at home or in a hotel, you might need to activate the PCMCIA card. This is done using the <B
CLASS="command"
>cardctl</B
> control utility, or the <B
CLASS="command"
>pccardctl</B
> on newer distributions.</P
><P
>A usage example:</P
><P
><B
CLASS="command"
>cardctl <TT
CLASS="parameter"
><I
>insert</I
></TT
></B
> </P
><P
>Now the card can be configured, either using the graphical or the command line interface. Prior to taking the card out, use this command:</P
><P
><B
CLASS="command"
>cardctl <TT
CLASS="parameter"
><I
>eject</I
></TT
></B
> </P
><P
>However, a good distribution should provide PCMCIA support in the network configuration tools, preventing users from having to execute PCMCIA commands manually.</P
></DIV
><DIV
CLASS="sect3"
><H3
CLASS="sect3"
><A
NAME="sect_10_02_03_04"
></A
>10.2.3.4. More information</H3
><P
>Further discussion of network configuration is out of the scope of this document. Your primary source for extra information is the man pages for the services you want to set up. Additional reading:</P
><P
></P
><UL
><LI
><P
><A
HREF="http://www.tldp.org/HOWTO/Modem-HOWTO.html"
TARGET="_top"
>The Modem-HOWTO</A
>: Help with selecting, connecting, configuring, trouble-shooting, and understanding analog modems for a PC.</P
></LI
><LI
><P
><A
HREF="http://www.tldp.org/HOWTO/HOWTO-INDEX/networking.html#NETGENERAL"
TARGET="_top"
>LDP HOWTO Index, section 4.4</A
>: categorized list of HOWTOs about general networking, protocols, dial-up, DNS, VPNs, bridging, routinfg, security and more.</P
></LI
><LI
><P
>Most systems have a version of the <TT
CLASS="filename"
>ip-cref</TT
> file (locate it using the <B
CLASS="command"
>locate</B
> command); the PS format of this file is viewable with for instance <B
CLASS="command"
>gv</B
>.</P
></LI
></UL
></DIV
></DIV
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="sect_10_02_04"
></A
>10.2.4. Network interface names</H2
><P
>On a Linux machine, the device name <EM
>lo</EM
> or the <EM
>local loop</EM
> is linked with the internal 127.0.0.1 address. The computer will have a hard time making your applications work if this device is not present; it is always there, even on computers which are not networked.</P
><P
>The first ethernet device, <EM
>eth0</EM
> in the case of a standard network interface card, points to your local LAN IP address. Normal client machines only have one network interface card. Routers, connecting networks together, have one network device for each network they serve.</P
><P
>If you use a modem to connect to the Internet, your network device will probably be named <EM
>ppp0</EM
>.</P
><P
>There are many more names, for instance for Virtual Private Network interfaces (VPNs), and multiple interfaces can be active simultaneously, so that the output of the <B
CLASS="command"
>ifconfig</B
> or <B
CLASS="command"
>ip</B
> commands might become quite extensive when no options are used. Even multiple interfaces of the same type can be active. In that case, they are numbered sequentially: the first will get the number 0, the second will get a suffix of 1, the third will get 2, and so on. This is the case on many application servers, on machines which have a failover configuration, on routers, firewalls and many more.</P
></DIV
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="sect_10_02_05"
></A
>10.2.5. Checking the host configuration with netstat</H2
><P
>Apart from the <B
CLASS="command"
>ip</B
> command for displaying the network configuration, there's the common <B
CLASS="command"
>netstat</B
> command which has a lot of options and is generally useful on any UNIX system.</P
><P
>Routing information can be displayed with the <TT
CLASS="option"
>-nr</TT
> option to the <B
CLASS="command"
>netstat</B
> command:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;<TT
CLASS="prompt"
>bob:~&#62;</TT
> <B
CLASS="command"
>netstat -nr</B
>
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
192.168.42.0 0.0.0.0 255.255.255.0 U 40 0 0 eth0
127.0.0.0 0.0.0.0 255.0.0.0 U 40 0 0 lo
0.0.0.0 192.168.42.1 0.0.0.0 UG 40 0 0 eth0
</PRE
></FONT
></TD
></TR
></TABLE
><P
>This is a typical client machine in an IP network. It only has one network device, <EM
>eth0</EM
>. The <EM
>lo</EM
> interface is the local loop.</P
><DIV
CLASS="note"
><P
></P
><TABLE
CLASS="note"
WIDTH="100%"
BORDER="0"
><TR
><TD
WIDTH="25"
ALIGN="CENTER"
VALIGN="TOP"
><IMG
SRC="../images/note.gif"
HSPACE="5"
ALT="Note"></TD
><TH
ALIGN="LEFT"
VALIGN="CENTER"
><B
>The modern way</B
></TH
></TR
><TR
><TD
>&nbsp;</TD
><TD
ALIGN="LEFT"
VALIGN="TOP"
><P
>The novel way to get this info from your system is by using the <B
CLASS="command"
>ip</B
> command:</P
><P
><B
CLASS="command"
>ip <TT
CLASS="parameter"
><I
>route show</I
></TT
></B
> </P
></TD
></TR
></TABLE
></DIV
><P
>When this machine tries to contact a host that is on another network than its own, indicated by the line starting with 0.0.0.0, it will send the connection requests to the machine (router) with IP address 192.168.42.1, and it will use its primary interface, eth0, to do this.</P
><P
>Hosts that are on the same network, the line starting with 192.168.42.0, will also be contacted through the primary network interface, but no router is necessary, the data are just put on the network.</P
><P
>Machines can have much more complicated routing tables than this one, with lots of different <SPAN
CLASS="QUOTE"
>"Destination-Gateway"</SPAN
> pairs to connect to different networks. If you have the occasion to connect to an application server, for instance at work, it is most educating to check the routing information.</P
></DIV
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="sect_10_02_06"
></A
>10.2.6. Other hosts</H2
><P
>An impressive amount of tools is focused on network management and remote administration of Linux machines. Your local Linux software mirror will offer plenty of those. It would lead us too far to discuss them in this document, so please refer to the program-specific documentation.</P
><P
>We will only discuss some common UNIX/Linux text tools in this section.</P
><DIV
CLASS="sect3"
><H3
CLASS="sect3"
><A
NAME="sect_10_02_06_01"
></A
>10.2.6.1. The host command</H3
><P
>To display information on hosts or domains, use the <B
CLASS="command"
>host</B
> command:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;<TT
CLASS="prompt"
>[emmy@pc10 emmy]$</TT
> <B
CLASS="command"
>host www.eunet.be</B
>
www.eunet.be. has address 193.74.208.177
<TT
CLASS="prompt"
>[emmy@pc10 emmy]$</TT
> <B
CLASS="command"
>host -t any eunet.be</B
>
eunet.be. SOA dns.eunet.be. hostmaster.Belgium.EU.net.
2002021300 28800 7200 604800 86400
eunet.be. mail is handled by 50 pophost.eunet.be.
eunet.be. name server ns.EU.net.
eunet.be. name server dns.eunet.be.
</PRE
></FONT
></TD
></TR
></TABLE
><P
>Similar information can be displayed using the <B
CLASS="command"
>dig</B
> command, which gives additional information about how records are stored in the name server.</P
></DIV
><DIV
CLASS="sect3"
><H3
CLASS="sect3"
><A
NAME="sect_10_02_06_02"
></A
>10.2.6.2. The ping command</H3
><P
>To check if a host is alive, use <B
CLASS="command"
>ping</B
>. If your system is configured to send more than one packet, interrupt <B
CLASS="command"
>ping</B
> with the <B
CLASS="keycap"
>Ctrl</B
>+<B
CLASS="keycap"
>C</B
> key combination:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;<TT
CLASS="prompt"
>[emmy@pc10 emmy]$</TT
> <B
CLASS="command"
>ping a.host.be </B
>
PING a.host.be (1.2.8.3) from 80.20.84.26: 56(84) bytes of data.
64 bytes from a.host.be(1.2.8.3):icmp_seq=0 ttl=244 time=99.977msec
--- a.host.be ping statistics ---
1 packets transmitted, 1 packets received, 0% packet loss
round-trip min/avg/max/mdev = 99.977/99.977/99.977/0.000 ms
</PRE
></FONT
></TD
></TR
></TABLE
></DIV
><DIV
CLASS="sect3"
><H3
CLASS="sect3"
><A
NAME="sect_10_02_06_03"
></A
>10.2.6.3. The traceroute command</H3
><P
>To check the route that packets follow to a network host, use the <B
CLASS="command"
>traceroute</B
> command:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;<TT
CLASS="prompt"
>[emmy@pc10 emmy]$</TT
> <B
CLASS="command"
>/usr/sbin/traceroute www.eunet.be</B
>
traceroute to www.eunet.be(193.74.208.177),30 hops max,38b packets
1 blob (10.0.0.1)
0.297ms 0.257ms 0.174ms
2 adsl-65.myprovider.be (217.136.111.1)
12.120ms 13.058ms 13.009ms
3 194.78.255.177 (194.78.255.177)
13.845ms 14.308ms 12.756ms
4 gigabitethernet2-2.intl2.gam.brussels.skynet.be (195.238.2.226)
13.123ms 13.164ms 12.527ms
5 pecbru2.car.belbone.be (194.78.255.118)
16.336ms 13.889ms 13.028ms
6 ser-2-1-110-ias-be-vil-ar01.kpnbelgium.be (194.119.224.9)
14.602ms 15.546ms 15.959ms
7 unknown-195-207-939.eunet.be (195.207.93.49)
16.514ms 17.661ms 18.889ms
8 S0-1-0.Leuven.Belgium.EU.net (195.207.129.1)
22.714ms 19.193ms 18.432ms
9 dukat.Belgium.EU.net (193.74.208.178) 22.758ms * 25.263ms
</PRE
></FONT
></TD
></TR
></TABLE
><P
>On some systems, <B
CLASS="command"
>traceroute</B
> has been renamed to <B
CLASS="command"
>tracepath</B
>.</P
></DIV
><DIV
CLASS="sect3"
><H3
CLASS="sect3"
><A
NAME="sect_10_02_06_04"
></A
>10.2.6.4. The whois command</H3
><P
>Specific domain name information can be queried using the <B
CLASS="command"
>whois</B
> command, as is explained by many <B
CLASS="command"
>whois</B
> servers, like the one below:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;<TT
CLASS="prompt"
>[emmy@pc10 emmy]$</TT
> <B
CLASS="command"
>whois cnn.com</B
>
[whois.crsnic.net]
Whois Server Version 1.3
$&#60;--snap server message--&#62;
Domain Name: CNN.COM
Registrar: NETWORK SOLUTIONS, INC.
Whois Server: whois.networksolutions.com
Referral URL: http://www.networksolutions.com
Name Server: TWDNS-01.NS.AOL.COM
Name Server: TWDNS-02.NS.AOL.COM
Name Server: TWDNS-03.NS.AOL.COM
Name Server: TWDNS-04.NS.AOL.COM
Updated Date: 12-mar-2002
&#62;&#62;&#62; Last update of whois database: Fri, 5 Apr 2002 05:04:55 EST &#60;&#60;&#60;
The Registry database contains ONLY .COM, .NET, .ORG, .EDU domains
and Registrars.
[whois.networksolutions.com]
$&#60;--snap server message--&#62;
Registrant:
Turner Broadcasting (CNN-DOM)
1 CNN Center
Atlanta, GA 30303
Domain Name: CNN.COM
Administrative Contact:
$&#60;--snap contactinfo--&#62;
Technical Contact:
$&#60;--snap contactinfo--&#62;
Billing Contact:
$&#60;--snap contactinfo--&#62;
Record last updated on 12-Mar-2002.
Record expires on 23-Sep-2009.
Record created on 22-Sep-1993.
Database last updated on 4-Apr-2002 20:10:00 EST.
Domain servers in listed order:
TWDNS-01.NS.AOL.COM 149.174.213.151
TWDNS-02.NS.AOL.COM 152.163.239.216
TWDNS-03.NS.AOL.COM 205.188.146.88
TWDNS-04.NS.AOL.COM 64.12.147.120
</PRE
></FONT
></TD
></TR
></TABLE
><P
>For other domain names than .com, .net, .org and .edu, you might need to specify the whois server, such as this one for .be domains:</P
><P
><B
CLASS="command"
>whois <TT
CLASS="parameter"
><I
>domain.be@whois.dns.be</I
></TT
></B
> </P
></DIV
></DIV
></DIV
><DIV
CLASS="NAVFOOTER"
><HR
ALIGN="LEFT"
WIDTH="100%"><TABLE
SUMMARY="Footer navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><A
HREF="sect_10_01.html"
ACCESSKEY="P"
>Prev</A
></TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="index.html"
ACCESSKEY="H"
>Home</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
HREF="sect_10_04.html"
ACCESSKEY="N"
>Next</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
>Networking Overview</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="chap_10.html"
ACCESSKEY="U"
>Up</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
>Internet/Intranet applications</TD
></TR
></TABLE
></DIV
></BODY
></HTML
>