Tải bản đầy đủ
[Chapter 13] 13.3 Finding Files

[Chapter 13] 13.3 Finding Files

Tải bản đầy đủ

[Chapter 13] 13.3 Finding Files

There are many interactive archie commands, but the basic function of locating a program that is
accessible via anonymous FTP can be reduced to two commands.
prog pattern
Display all files in the database with names that match the specified pattern.
mail address
Mail the output of the last command to address, which is normally your own email address.
The following example uses both of these commands to interactively search for gated-R3_5_5.tar,
and then mail the results of the search to craig@peanut.nuts.com.
% telnet archie.internic.net
Connected to archie.ds.internic.net.
Escape character is ']'.
UNIX(r) System V Release 4.0 (ds0)
login: archie
# Bunyip Information Systems, Inc., 1993, 1994, 1995
archie> prog gated-R3_5_5.tar
# Search type: sub.
# Your queue position: 1
# Estimated time for completion: 5 seconds.
working... O
Host ftp.zcu.cz
Last updated 11:32 27 Jun 1997
Location: /pub/security/merit/gated
FILE -r--r--r-- 1460773 bytes Jan 1997 gated-R3_5_5.tar.gz
archie> mail craig@peanut.nuts.com
archie> quit
The archie output provides all of the information you need to initiate an anonymous FTP transfer:

The name of the server (ftp.zcu.cz in our example)
The directory on the server that contains the file (/pub/security/merit/gated in our example)
The full name of the file (gated-R3_5_5.tar.gz in our example)

You can also use archie by sending email to archie at any one of the archie servers; for example,
archie@archie.internic.net. The text of the mail message must contain a valid archie email command.
file:///C|/mynapster/Downloads/warez/tcpip/ch13_03.htm (2 of 5) [2001-10-15 09:19:04]

[Chapter 13] 13.3 Finding Files

To get a complete list of archie email commands, send mail containing the help command to one of
the servers. In the example below, the email help file is requested from archie.internic.net.
% mail archie@archie.internic.net
While these two methods of accessing archie work fine, the best way to use archie is through a Web
browser. Many Web servers provide an archie interface.
http://pubweb.nexor.co/uk/public/archie/servers.html lists several of these gateways. The server used
in Figure 13.4 is http://archie.bunyip.com/archie.html.
Figure 13.4: Archie Web interface

file:///C|/mynapster/Downloads/warez/tcpip/ch13_03.htm (3 of 5) [2001-10-15 09:19:04]

[Chapter 13] 13.3 Finding Files

Enter the name of the program you want to locate in the Search for: box and press the Search
button. Your browser displays the search results with links directly to the file you're seeking. For
example, assume we rerun the search for gated-R3_5_5.tar.gz using the
http://archie.bunyip.com/archie.html Web page. The server returns a list of eight matches, the first of
which is the anonymous FTP server at ftp.zcu.cz. The filename gated-R3_5_5.tar.gz that is displayed
next to the FTP server is a link. Clicking on the link transfers the file from ftp.zcu.cz to your system.
Search and retrieval all in one interface!
While the Web browser provides the easiest interface to archie, some people prefer to run an archie
client on their local system. Using an archie client reduces the load on the servers and improves
responsiveness for the user. If you believe you'll access archie very frequently, it might be worth
setting up an archie client. archie client software
archie client software is available via anonymous FTP from the ftp.bunyip.com server. The software
is stored in the pub/archie/clients directory. The README file in this directory provides a short
description of each type of client. There are at least three different client software packages for UNIX:
an X windows client and two command-line clients, one written in C and the other written in Perl.
Check the archie servers for the latest developments in client software.
This section uses the command-line archie client written in C as an example. The C code and the
instruction to make the client are all contained in the c-archie-1.4.1.tar.gz file from ftp.bunyip.com.
Once the client has been made and installed, it is invoked using the command:
% archie [options] string
The string is the name of the file that you are asking archie to find. It can be the exact filename, a
substring of the name, or a regular expression.
The options control how the string is interpreted. The -e option searches for a filename that exactly
matches the string; the -s option matches on any record that contains the string as any part of the
filename; and the -r option interprets the string as a UNIX regular expression when looking for
The following example uses the archie client to search for sites from which the ppp software can be
retrieved. The search uses a regular expression that will match any compressed tar file with a name
that starts with ppp.
file:///C|/mynapster/Downloads/warez/tcpip/ch13_03.htm (4 of 5) [2001-10-15 09:19:04]

[Chapter 13] 13.3 Finding Files

% archie -r '^ppp.*\.tar\.Z' > ppp.locations
Our example stores archie's output in the file ppp.locations. You can then examine ppp.locations to
find the closest FTP server that has the latest version of the ppp tar file. Redirecting the output to a
file is usually a good idea because archie often produces a lot of output. By default, the archie client
will return as many as 95 matches to the search. To limit the number of matches returned, use the
option -mn, where n is the maximum number of matches archie should return. For example, -m5
limits the search to five matches.
The archie database is frequently out-of-date or dominated by obscure FTP servers that have poor
connectivity. This limits its utility. But sometimes archie is the only place you have to start your
search for a file.

Previous: 13.2 Anonymous
13.2 Anonymous FTP

TCP/IP Network
Book Index

Next: 13.4 Retrieving RFCs
13.4 Retrieving RFCs

[ Library Home | DNS & BIND | TCP/IP | sendmail | sendmail Reference | Firewalls | Practical Security ]

file:///C|/mynapster/Downloads/warez/tcpip/ch13_03.htm (5 of 5) [2001-10-15 09:19:04]

[Chapter 13] 13.4 Retrieving RFCs

Previous: 13.3 Finding Files

Chapter 13
Internet Information

Next: 13.5 Mailing Lists

13.4 Retrieving RFCs
Throughout this book, we have referred to many RFCs. These are the Internet documents used for
everything from general information to the definitions of the TCP/IP protocols standards. As a
network administrator, there are several important RFCs that you'll want to read. In this section we
describe how you can obtain them.
RFCs are available via the World Wide Web at http://www.internic.net. Follow the links from that
home page through the directory services to the IETF RFC page. The page allows you to search the
RFCs for keywords or to load the RFC index. The index is particularly useful if you know the number
of the RFC you want. Figure 13.5 shows a network administrator scrolling through the index looking
for RFC 1122.
Figure 13.5: The RFC index

file:///C|/mynapster/Downloads/warez/tcpip/ch13_04.htm (1 of 4) [2001-10-15 09:19:05]

[Chapter 13] 13.4 Retrieving RFCs

In another example the network administrator does not know which RFCs contain the information she
is looking for, but she knows what she wants. The administrator is trying to find out more about the
SMTP service extensions that have been proposed for Extended SMTP. Figure 13.6 shows the four
RFCs displayed as a result of her query.
Figure 13.6: An RFC Web search

file:///C|/mynapster/Downloads/warez/tcpip/ch13_04.htm (2 of 4) [2001-10-15 09:19:05]