FTP mini-HOWTO <author>Matthew Borowski (mkb@yahoo.com)<newline> ( <htmlurl url="http://tarp.worldserve.net" name="http://tarp.worldserve.net/"> ) <date>v0.2, 9 January 2000 <trans>宮野浩史, (hmiyano@webjapan.com) <tdate>v0.1, 3 May 2000 <abstract> <!-- How to use ftp clients and servers --> FTP クライアントとサーバの使い方 </abstract> <toc> <!-- Begin of document --> <sect> <!-- Preamble --> 序章 <p> <!-- This document was written by Matthew Borowski for the Linux Documentation Project. I have not yet finished adding everything I want to add. There will be a section with information on operating an FTP server. --> この文章は Matthew Borowski によって Linux Documentation Project のた めに書かれました。わたしはこの文章に追加したい内容を全て追加しきってはいませ ん。将来、FTP サーバを動かすための情報を載せた章ができる予定です。 <sect1> <!-- Contacting Me --> 著者にコンタクトする <p> <!-- Please contact me if you have any additions or changes for this document. Please do not ask for technical support - you may purchase Unix consulting and support through my company, <bf/<htmlurl url="http://www.worldserve.net" name="WorldServe">/, or you can ask for help on newsgroups such as <bf/comp.os.linux.*/. Please also keep in mind that I can only understand English and Farsi. --> この文章に追加や変更したいことがあれば著者までコンタクトしてください。 お願いですから技術サポートを要求しないでください(UNIX の相談やサポー トは著者の会社 <bf/<url url="http://www.worldserve.net" name="WorldServe">/ から購入してもよいですし、<bf/comp.os.linux.*/ などのニュースグループで 助力を得ることもできます)。それと、著者は英語とペルシア語しか理解できません のでそれを心に止めておいてください。 (訳注: 日本語でのコンタクトは翻訳者まで) <sect1> <!-- Legalities and Distribution --> 法律義務と配布 <p> 以下の文は参考のため訳文を挙げますが、原文が優先されます。 <p>This document is Copyright 1999 by Matthew Borowski. You may freely distribute this document as long as the copyright notice remains unaltered. If you distribute this HOWTO as part of a commercial product, I would like to recieve a copy, but this is not required. If you wish to distribute a modified or translated version of this document, please contact me first for permission. <p>この文章は Matthew Borowski の著作物です(Copyright 1999)。 著作権表示が変更されずに残っている限り、この文章を自由に配布してもかま いません。この文章が商用製品の一部として配布されるときは製品のコピー を受け取りたいですが、これは必須ではありません。この文章の改変、翻訳版 を配布したい場合は、著者から許可を先に取ってください。 <sect1> <!-- History of this document --> この文章の履歴 <p> <itemize> <item> <!-- 991203: FTP HOWTO first written. Still a work-in-progress. --> 991203: FTP HOWTO 初版。まだ作業進行中。 </itemize> <p> <descrip> [訳注 : 日本語版改訂履歴を以下に示します。 <tag>v1.0, 2000 年 5 月 16 日</tag> 翻訳: 宮野浩史<tt><hmiyano@webjapan.com></tt> 校正: 日下部陽一 <tt><void@merope.pleiades.or.jp></tt>, 佐藤亮一 <tt><rsato@ipf.de></tt> 武井伸光 <tt><takei@kondara.org></tt>, 早川仁 <tt><uv9h-hykw@asahi-net.or.jp></tt> 山下義之 <tt><dica@eurus.dti.ne.jp></tt> 校正をしてくださった皆様、本当にありがとうございました。] </descrip> </p> <sect> <!-- About FTP --> FTP について <p> <!-- FTP (File Transfer Protocol) is a client/server protocol that allows a user to transfer files to and from a remote network site. It works with TCP and is most commonly used on the Internet, although it can also be used on a LAN. --> FTP(File Transfer Protocol : ファイル転送プロトコル)はリモートネットワークサ イト とファイルをやりとりするためのクライアント/サーバプロトコルです。この プロトコルは TCP と共に働きインターネットでもっともよく使われます( LAN で使うこともできますが)。 --> <p> <!-- An FTP site is a computer that is running FTP server software (also known an FTP daemon, or <tt>ftpd</tt>). A public ftp site can usually be accessed by anybody by logging in as <tt>anonymous</tt> or <tt>ftp</tt>. There are many excellent public ftp sites that make repositories of free Unix software available. By learning how to use FTP, you give yourself access to an indespensible resource. --> <!-- indespensible = indispensible (typo)--> FTP サイトとは FTP サーバソフトウェア( FTP デーモン、または <tt>ftpd</tt> としても知られています)を起動しているコンピュータのことで す。パブリック FTP サイトは誰でも <tt>anonymous</tt> か <tt>ftp</tt> として ログインすることでアクセスできます。これらの中には、フリーの Unix ソフ トウェアが入手できるリポジトリを持つ素晴らしいパブリック FTP サイトが たくさんあります。FTP の使い方を学べば、必要なリソースへアクセスをできるよう になります。 <p> <!-- Private FTP sites require a user name or password. If you have a shell account with your ISP, you may be able to access your files via FTP (contact your system administrator to check on this). --> プライベート FTP サイトは(訳注:アクセスするのに)ユーザ名かパスワー ドを必要とします。ISP のシェルアカウントも持っている場合は、 FTP を通してあなたのファイルにアクセスすることができるかもしれません (これを確かめるにはシステム管理者にコンタクトしてください)。 <p> <!-- An FTP client is the userland application that provides access to FTP servers. There are many FTP clients available. Some are graphical, and some are text-based. --> FTP クライアントは FTP サーバへのアクセスを提供するユーザサイドの アプリケーションです。数多くの FTP クライアントが利用可能で、 これにはグラフィカルとテキストベースのものがあります。 <p> <!-- FTP was first developed by the University of California, Berkeley for inclusion in 4.2BSD (Berkeley Unix). The RFC (Request for Comments) is available at <htmlurl url="ftp://nic.merit.edu/documents/rfc/rfc0959.txt">. --> FTP はカリフォルニア大学バークレー分校で最初に 4.2BSD (Berkeley Unix) に含まれる形で開発されました。RFC(仕様書)は <url url="ftp://nic.merit.edu/documents/rfc/rfc0959.txt"> から入手可能です。 <sect> <!-- Beginner's guide to using ftp --> FTP を使用する上での初心者へのガイド <p> <!-- <bf/A quick guide to using ftp./ --> <bf/FTP を使用するための簡単なガイド。/ <p> <!-- The standard ftp program is the original ftp client. It comes standard with most Linux distributions. It first appeared in 4.2BSD, which was developed by the University of California, Berkeley. --> 標準の FTP プログラムはオリジナル ftp クライアントです。ほとんどの Linux ディストリビューションに標準で付属しています。ftp は最初にカ リフォルニア大学バークレー分校によって開発された 4.2BSD で現れました。 <sect1> <!-- Running the <tt>ftp</tt> program --> <tt>ftp</tt> プログラムを起動する <p> <!-- It's easy to use ftp. Let's say you want to connect to the anonymous ftp site metalab.unc.edu, to download the latest Linux kernel source. --> ftp を使うのは簡単です。たとえば、最新の Linux カーネルソースをダウンロード するために metalab.unc.edu という名前の匿名 FTP サイトに接続したいとします。 <p> <!-- At the command line, type: --> コマンドラインから以下のようにタイプします: <tscreen><verb> $ ftp metalab.unc.edu </verb></tscreen> <p> <!-- The ftp program will attempt to connect to metalab.unc.edu. Another way to do this is to run <tt>ftp</tt> from the command line with no parameters, and use the <tt>open</tt> command, with the site name as an argument: --> これで ftp プログラムは metalab.unc.edu に接続しようとします。他のやり方で同 じことをするには <tt>ftp</tt> をパラメータなしで起動し、サイト名を引数として <tt>open</tt> コ マンドを 使用します。 <tscreen><verb> $ ftp ftp> open metalab.unc.edu </verb></tscreen> <sect1> <!-- Logging into an FTP server --> FTP サーバにログインする <p> <!-- 原文に括弧の閉め忘れがある --> <!-- When you connect to an FTP site, it will ask you for a login (pressing enter will log in as your local user name, in this case, <tt>foo</tt>: We log in as <tt>anonymous</tt> or <tt>ftp</tt>, to get to the public archive. --> FTP サイトに接続するとログインを要求されます(Enter を押すとローカルのユーザ 名で ログインします。この場合は <tt>foo</tt>)。ここでは <tt>anonymous</tt> ないし <tt>ftp</tt> としてログインし、 パブリックアーカイブへ行くことにします。 <tscreen><verb> 220 helios.oit.unc.edu FTP server (Version wu-2.6.0(2) Wed Nov 17 14:44:12 EST 1999) ready. Name (metalab.unc.edu:foo): </verb></tscreen> <p> <!-- Now, we enter a complete e-mail address as the password (this is what most public FTP sites request). --> 次に、完全な E-Mail アドレスをパスワードとして記入します(ほとんどのパブリッ ク FTP サイトはこれを要求します)。 <tscreen><verb> 331 Guest login ok, send your complete e-mail address as password. Password: </verb></tscreen> <p> <!-- After a successful login, the following information is given to us: --> ログインに成功すると、以下の情報が与えられます。 <tscreen><verb> Remote system type is UNIX. Using binary mode to transfer files. ftp> </verb></tscreen> <sect1> <!-- File transfer types --> ファイル転送タイプ <p> <!-- After you log in to an ftp site, <tt>ftp</tt> will print out the file transfer type. In our case, it is binary. Binary mode transfers the files, bit by bit, as they are on the FTP server. Ascii mode, however, will download the text directly. You can type <tt>ascii</tt> or <tt>binary</tt> to switch between the types. --> FTP サイトにログインしたあとに、<tt>ftp</tt> はファイル転送タイプを表示しま す。 上記の場合はバイナリ(binary)です。バイナリモードではファイルを1ビットずつ、 FTP サーバ にあるとおりに転送します。しかしながらアスキー(Ascii)モードではテキストを直 接ダウンロードします。 <tt>ascii</tt> や <tt>binary</tt> とタイプすることでタイプを変更できます。 <p> <!-- You want to download the kernel source, so you leave the file transfer type at binary. The binary type is also what you would use for any non-text files - such as graphic images, zip/gzip archives, executable programs, etc. If in doubt, use binary mode. --> 今回はカーネルソースをダウンロードしたいので、ファイル転送タイプはバイナリの ままに しておきます。バイナリタイプはテキストではない全てのファイルをダウンロードす るさいに 使用します(たとえば、画像イメージ、zip/gzip アーカイブ、実行ファイルなど)。 分からなかったらバイナリモードを使用しましょう。 <sect1> <!-- Navigating and listing directories --> ディレクトリの操作と一覧 <p> <!-- You do an <tt>ls</tt> to see a list of the files. The <tt>ls</tt> command on ftp servers is executed on the remote server, so the command line options that you can use with it vary from server to server. The most common options are generally available, check the manpage for <tt>ls</tt> for details. --> ファイルを一覧するには <tt>ls</tt> を使います。FTP サーバの <tt>ls</tt> はリ モートサーバ上で 実行されますので、使えるコマンドラインオプションはサーバによって異なります。 一般的なオプションは 普通は利用可能ですので、詳しいことは <tt>ls</tt> の man ページを調べてくださ い。 <tscreen><verb> ftp> ls 200 PORT command successful. 150 Opening ASCII mode data connection for /bin/ls. total 33590 -r--r--r-- 1 root other 34348506 Dec 03 03:53 IAFA-LISTINGS lrwxrwxrwx 1 root other 7 Jul 15 1997 README -> WELCOME -rw-r--r-- 1 root other 890 Nov 15 13:11 WELCOME dr-xr-xr-x 2 root other 512 Jul 15 1997 bin dr-xr-xr-x 2 root other 512 Jul 15 1997 dev dr-xr-xr-x 2 root other 512 Jul 18 1997 etc drwxrwxrwx 11 ftp 20 4608 Nov 28 16:00 incoming lrwxrwxrwx 1 root other 13 Jun 04 1998 ls-lR -> IAFA-LISTINGS dr-xr-xr-x 17 root root 512 Jun 08 11:43 pub dr-xr-xr-x 3 root other 512 Jul 15 1997 unc dr-xr-xr-x 5 root other 512 Jul 15 1997 usr 226 Transfer complete. </verb></tscreen> <p> <!-- If the <tt>ls</tt> command lists so many files that they scroll off the top of the screen, you can use Shift-PageUp to scroll up. This works in Linux console mode as well as in xterm or rxvt. --> もし <tt>ls</tt> コマンドで列挙したファイルが多すぎて画面から上にはみ出てし まった場合は、 Shift-PageUp を使うことで上にスクロールできます。これは Linux のコンソール上 での他、xterm や rxvt 上でも使えます。 <p> <!-- On public FTP archives, the downloadable resources are usually held in the <tt>/pub</tt> directory. In this example, you already know that the kernel sources are in the directory <tt>/pub/Linux/kernel</tt>, so you type the following to get into that directory: --> パブリック FTP アーカイブ上では、ダウンロードできるリソースは普通 <tt>/pub</tt> ディレクトリ に格納されています。この例では、カーネルソースが <tt>/pub/Linux/kernel</tt> にあることが分かって いることとして、次のようにタイプしてそのディレクトリまで移動します。 <tscreen><verb> ftp> cd pub/Linux/kernel 250-README for kernel 250- 250-What you'll find here: kernel sources and patches 250- 250- 250 CWD command successful. </verb></tscreen> <p> <!-- The messages you see, which begin with "250", are information messages sent by the server. In this case, the ftp server is configured to automatically send you the README file when you cd into the directory. --> 「250」で始まるメッセージはサーバから送られてきた情報メッセージです。 上記の場合、あなたがディレクトリに cd すると FTP サーバが自動的に README ファイル を送るように設定されています。 <sect1> <!-- Downloading and uploading files --> ファイルのダウンロードとアップロード <p> <!-- Now, after doing another <tt>ls</tt>, you see that you want to <tt>cd</tt> into the v2.2 directory. You do yet another <tt>ls</tt>, and find the file you want to download. It is <tt>linux-2.2.13.tar.gz</tt>. So you type this: --> さて、再度 <tt>ls</tt> すると、v2.2 ディレクトリがあるのでそこに <tt>cd</tt> します。 その後、また <tt>ls</tt> をすると、ダウンロードしたいファイル <tt>linux-2.2.13.tar.gz</tt> が見つかります。 そこで今度は次のようにタイプします。 <tscreen><verb> ftp> get linux-2.2.13.tar.gz local: linux-2.2.13.tar.gz remote: linux-2.2.13.tar.gz 200 PORT command successful. 150 Opening BINARY mode data connection for linux-2.2.13.tar.gz (15079540 bytes). </verb></tscreen> <p> <!-- The ftp program has started saving the remote file <tt>linux-2.2.13.tar.gz</tt> as the local file <tt>linux-2.2.13.tar.gz</tt>. --> ftp プログラムがリモートファイル <tt>linux-2.2.13.tar.gz</tt> をローカ ルファイル <tt>linux-2.2.13.tar.gz</tt> として保存し始めました。 <p> <!-- If you wanted to save it as the local file <tt>foo.tar.gz</tt>, you could have specified it like this: --> もしこれを <tt>foo.tar.gz</tt> という名前でローカルファイルに保存した ければ、次のように指定できます。 <tscreen><verb> ftp> get linux-2.2.13.tar.gz foo.tar.gz local: foo.tar.gz remote: linux-2.2.13.tar.gz 200 PORT command successful. 150 Opening BINARY mode data connection for linux-2.2.13.tar.gz (15079540 bytes). </verb></tscreen> <p> <!-- If you want to download more than one file at a time, you'll have to use the <tt>mget</tt> (multiple get) command. You can use <tt>mget</tt> together with a space-delimited list of filenames you want to download, or you can use wildcards with the <tt>mget</tt> command. For example: --> 一度に複数のファイルをダウンロードしたい場合は、<tt>mget</tt> (multiple get) コマンドを使う必要があります。<tt>mget</tt> は スペースで区切られたダウンロードしたいファイル名のリストをコマンド の引数として使うか、<tt>mget</tt> コマンドをワイルドカードと合わせて使用す ることもできます。たとえば、 <tscreen><verb> ftp> mget linux* </verb></tscreen> <p> <!-- Would get all files starting with the string "linux". Normally, <tt>mget</tt> will prompt you for each file before it downloads it. You can toggle this by using the <tt>prompt</tt> command. --> 上記のコマンドによって、「linux」で始まる全てのファイルを取得します。 普通 <tt>mget</tt> は各ファイルをダウンロードするまえに本当にダウンロー ドするかプロンプトを出します。<tt>prompt</tt> コマンドを使うことで これを切替えられます。 <p> <!-- Now let's say you've written a piece of software, and you want to upload it to MetaLab to be included in their Linux software archive. First, you'd change to the /incoming directory (most public FTP servers have a directory, usually called incoming or uploads, where files can be uploaded), then you'd use the put command: --> たとえばあなたが何かのソフトウェアを書いたとして、これを Linux ソフトウェ アアーカイブに含めてもらうために MetaLab にアップロードしたいとします。 それでは最初に、/incoming ディレクトリ(ほとんどのパブリック FTP サーバにはファイルがアップロードできる incoming や uploads といった名前のディレクトリがあります)に移動し、put コマンドを 使用します。 <tscreen><verb> ftp> cd /incoming ftp> put foo.tar.gz local: foo.tar.gz remote: foo.tar.gz 200 PORT command successful. 150 Opening BINARY mode data connection for foo.tar.gz. 226 Transfer complete. 10257 bytes sent in 0.00316 secs (3.2e+03 Kbytes/sec) </verb></tscreen> <p> <!-- The <tt>put</tt> command works the same way as the <tt>get</tt> command, so you can use <tt>mput</tt> to upload multiple files at the same time. You can also upload a local file with a different filename on the server by specifying the remote filename and/or pathname as an argument. --> <tt>put</tt> コマンドは <tt>get</tt> と同じように、<tt>mput</tt> で複 数のファイルを同時にアップロードできます。リモートファイル名やパスを引 数として指定すれば、ローカルファイルを別のファイル名でサーバ上にアップロードできます。 <p> <!-- What if the file <tt>foo.tar.gz</tt> is not in your current local directory when you try to upload it? You can switch local directories by using the <tt>lcd</tt> (local change directory) command: --> もしファイル <tt>foo.tar.gz</tt> が、アップロードしようとしたときに ローカルのカレントディレクトリにない場合はどうすればよいのでしょう? これは、<tt>lcd</tt> (local change directory)コマンドを使用することによって ロー カルのディレクトリを変更できます。 <tscreen><verb> ftp> lcd /home/foo/ Local directory now /home/foo </verb></tscreen> <sect1> <!-- Running shell commands --> シェルコマンドを起動する <p> <!-- The ftp client supports using the bang (!) to run local commands. For example, to get a listing of files in your current local directory, do this: --> FTP クライアントは感嘆符(!)を使うことによってローカルコマンドを起動す ることをサポートしています。たとえば、ローカルのカレントディレクトリのファイ ルを列挙するには次のようにします。 <tscreen><verb> ftp> !ls </verb></tscreen> <p> <!-- The way this works is that ftp calls the shell (specified in the <tt>$SHELL</tt> environment variable), and it is the shell which runs <tt>ls</tt>. Thus, you can run any command-line which works with your shell simply by prepending "!" to it (the default shell in most Linux distributions is bash, the Bourne Again SHell). Please note that <tt>!cd</tt> does not work as you would expect, this is why the <tt>lcd</tt> command exists. --> これがどうやって働くのかというと、ftp はシェル(<tt>$SHELL</tt> 環境変数 で指定された)を呼び出し、シェルが <tt>ls</tt> を起動します。つまりは、 シェルで動くコマンドラインなら、前に「!」をつけてやりさえすれば何でも 実行できます(ほとんどの Linux ディストリビューションでは bash (Bourne Again SHell)がデフォルトのシェルになっています)。しかし、<tt>!cd</tt> はあなたの思ったとおりには動いてくれないことに注意してください。 だからこそ <tt>lcd</tt> コマンドが存在するのです。 <sect1> <!-- Hash marks and tick --> ハッシュ記号とティック <p> <!-- Wouldn't it be nice if you could watch the progress while you're downloading a file with ftp? You can use the hash command to print out hash marks as you download a file: --> もし ftp でダウンロードをしているファイルの進行状況が見られたら便利だと思い ません か? hash コマンドを使用することによって、ダウンロード時にハッシュ記号を出力 します。 <tscreen><verb> ftp> hash Hash mark printing on (1024 bytes/hash mark). </verb></tscreen> <p> <!-- As you can tell, ftp will print a hash mark for every 1024 bytes of data you download. --> 見ても分かるように、ftp は 1024 バイト分データをダウンロードするたびに ハッシュ記号を出力します。 <p> <!-- There is also a <tt>tick</tt> option. --> その他にも <tt>tick</tt> オプションがあります。 <tscreen><verb> ftp> tick Tick counter printing on (10240 bytes/tick increment). <!-- This will print something to this effect as you download a file: --> これはダウンロードの進行状況を下のように出力します。 Bytes transferred: 11680 </verb></tscreen> <sect1> <!-- Other ftp commands --> その他の ftp コマンド <p> <!-- There are many other ftp commands. If you have the permissions to do so (which you should, if you are connected to your own private shell account), you can make a directory on the remote server using the <tt>mkdir</tt> command. You can remove a file on the remote server using the <tt>delete</tt> command, or <tt>rmdir</tt> to remove a directory. You can also change file permissions using the <tt>chmod</tt> command. --> ftp コマンドは他にもたくさんあります。もしあなたがパーミッションを与え られていれば(個人のプライベートシェルアカウントに接続している場合は そのはず) <tt>mkdir</tt> コマンドによってリモートサーバ上にディレ クトリを作成できます。<tt>delete</tt> コマンドでファイルをリ モートサーバ上から削除でき、<tt>rmdir</tt> ではディレクトリを削除しま す。<tt>chmod</tt> コマンドを使うことによって、ファイルのパーミッショ ンを変更することもできます。 <p> <!-- For more elaborate information on using ftp, please see the online help in the ftp program (accessible by typing help with no arguments for a list of commands, or help <commandname> for specific help on a command). You can also read the Unix man page for ftp by typing <tt>man ftp</tt> at your command prompt. --> ftp を使う上でのさらに詳しい情報は、ftp プログラム内のオンラインヘルプ を参照してください(コマンドを列挙するには引数なしで help とタイプ、特 定のコマンドのヘルプを見る場合は help <commandname>)。コマンドプ ロンプトから <tt>man ftp</tt> とタイプすることで、ftp の Unix man ペー ジを読むこともできます。 <sect> <!-- Console FTP clients --> コンソール FTP クライアント <p> <!-- The original ftp program was the original ftp client, and it is a good investment to learn it. It's the only ftp client that you can be certain is available on most systems (even Win32 comes with the ftp command, albeit an archaic, braindead version of it). --> 本来の FTP プログラムはオリジナル ftp クライアントで、これを勉強 しておくとためになるでしょう。これはほとんどのシステム(すたれた脳死版 ですが、Win32 にでさえも ftp コマンドが含まれています)で利用可能なこと が確かなただひとつの FTP クライアントです。 <p> <!-- There are many other console-mode (text-only) ftp clients available. The listing here is by no means comprehensive, but includes the most popular ones. Search at <htmlurl url="http://www.freshmeat.net" name="FreshMeat"> to find more. --> 世の中には他にも数多くのコンソールモード(テキストのみ)の FTP クライアントが 利用可能で す。このリストは内容豊富なものではありませんが、もっとも有名なものを含 みます。もっと探すには <url url="http://www.freshmeat.net" name="FreshMeat"> で検索してみてください。 <sect1>NcFTP <p> <!-- NcFTP is the all-time favorite ftp client of many Unix users. It comes bundled with most Linux distributions, and offers many advanced features such as tab completion and bookmarks. Version 2 of NcFTP had a curses based full-screen mode. This was done away with in Version 3 (now in beta). --> <!-- 翻訳時現在は既に正規版になっているよう --> NcFTP は時代を超えて数多くの Unix ユーザから好まれている FTP クライアントで す。これは ほとんどの Linux ディストリビューションにバンドルされていて、タブ補完 やブックマークなど数多くの発達した機能を提供します。NcFTP Version 2 では curses ベースのフルスクリーンモードがありましたが、この機能は Version 3 でなくなりました。 <p> <!-- 原文 &percnt 忘れ --> <!-- It's not 100% compatible with the commands that standard ftp uses. For example, get and put in NcFTP act like mget and mput do in standard ftp. So if you want to save a remote file as a different local filename, you'd have to do get -z remotename localname. Thankfully, NcFTP has a nice online help system to assist you in learning the commands. --> これは標準の ftp が使うコマンドと 100% 互換性があるわけではありませ ん。 たとえば、NcFTP の get と put は標準 ftp の mget や mput のように動作し ます。なので、リモートファイルを別名のローカルファイルとして保存 したい場合は get -z remotename localname とする必要があります。有難い ことに、NcFTP にはコマンドの勉強を手伝ってくれる便利なオンラインヘ ルプシステムがあります。 <p> <!-- You can get the latest version of NcFTP at <htmlurl url="http://www.ncftp.com">. --> 最新版の NcFTP は <url url="http://www.ncftp.com"> から入手できます。 <!-- 原作者の方から許可を頂いたので、そのまま訳注なしでいきます --> <p> Debian パッケージは <url url="ftp://ftp.freshmeat.net/pub/debs/ncftp/"> から入手可能です。 <p> Redhat パッケージは <url url="http://rpmfind.net/RPM/ncftp.html"> から入手可能です。 <sect1>lukemftp <p> <!-- A port of the NetBSD FTP client to other systems, lukemftp derives its name from the author of most of the enhanced features, which include: command-line editing, command-line fetches of FTP and HTTP URLs (including via proxies), context-sensitive word completion, dynamic progress bar, IPv6 support, modification time preservation, paging of local and remote files, passive mode support (with fallback to active mode), SOCKS support, TIS FWTK gate-ftp server support, and transfer rate throttling. --> lukemftp は NetBSD から他のシステムへのポートで、その名前を拡張機能のほとん どを書いた方から由来し、 以下の機能を含みます。コマンドライン エディティング、FTP と HTTP の URL のコマンドラインフェチ(プロキシ経由を含 む)、 コンテキストセンシティブ単語補完、ダイナミックプログレスバー、IPv6 サポー ト、変更時間保存、ローカルとリモート ファイルのページング、パッシブモードサポート(アクティブモードの代替として)、 SOCKS サポート、 TIS FWTK gate-ftp サーバサポート、それと転送レートの減速。 <p> <!-- I highly recommend lukemftp to users who don't want to change to anything drastically different from the standard ftp client, but want more advanced features. --> 標準の ftp クライアントから思いっ切り異なったものは欲しくないが、もっと発達 した機能が欲しい方 に lukemftp を強くお勧めします。 <p> <!-- You can get the latest version of lukemftp at <htmlurl url="ftp://ftp.netbsd.org/pub/NetBSD/misc/lukemftp/">. --> 最新版の lukemftp は <url url="ftp://ftp.netbsd.org/pub/NetBSD/misc/lukemftp/"> から入手できます。 <p> Redhat パッケージは <url url="http://www.innominate.org/~oku/rpms/lukemftp.html"> から入手可能です。 <sect1>lftp <p> <!-- lftp is a sophisticated command line based FTP client. Like bash, it has job control. It uses the GNU readline library for input, so you have command line completion and editing. lftp also has bookmarks, mirroring support, and can transfer several files in parellel. --> lftp は洗練されたコマンドラインベースの FTP クライアントです。bash の ようにジョブコントロールを持ちます。これは GNU readline ライブラリを入 力に使用するので、コマンドライン補完と編集機能を持ちます。lftp はさら にブックマーク、ミラーリングサポート、そして複数のファイルを並列に転送 できます。 <p> <!-- You can get the latest version of lftp at <htmlurl url="http://ftp.yars.free.net/projects/lftp/">. --> 最新版の lftp は <url url="http://ftp.yars.free.net/projects/lftp/"> から入手できます。 <p> <!-- Debian packages are available at <htmlurl url="ftp://ftp.freshmeat.net/pub/debs/lftp/">. --> Debian パッケージは <url url="ftp://ftp.freshmeat.net/pub/debs/lftp/"> から 入手可能です。 <p> Redhat パッケージは <url url="ftp://ftp.redhat.com/pub/contrib/hurricane/i386/"> から入手可能で す。 <sect1>cftp <p> <!-- Comfortable FTP (cftp) is a full screen mode client. What it lacks in features, it makes up for in ease of use. You browse through the directories using the arrow keys and enter. --> Comfortable FTP (cftp)はフルスクリーンモードのクライアントです。機能は少ない ですが、 それを使いやすさでカバーしています。矢印キーと Enter キーを使うことでディレ クトリ間を ブラウズできます。 <p> <!-- You should be able to get the latest version of cftp at <htmlurl url="http://ftp.giga.or.at/pub/nih/cftp/">. --> 最新版の cftp は <url url="http://ftp.giga.or.at/pub/nih/cftp/"> から入手できるはずです。 <p> Redhat パッケージは <url url="ftp://ftp.freshmeat.net/pub/rpms/cftp/"> から入手可能で す。 <sect1>yafc <p> <!-- Yafc is a very nice ftp client, with features including directory cache, remote filename completion, aliases, colorized ls, recursive get/put/ls/rm, nohup mode transfers, tagging (queueing), multiple connections, proxy support and more. It has support for Kerberos4 authentication. --> Yafc は、ディレクトリキャッシュ、リモートファイル名補完、エイリアス、色付き ls、 回帰できる get/put/ls/rm、nohup モード転送、タグ(キュー)、複数接続、 プロキシサポートと、その他たくさんの機能を含んだとても便利な FTP クライアン トです。 Yafc は Kerberos4 認証をサポートします。 <p> <!-- You can get the latest version of yafc from <htmlurl url="http://www.stacken.kth.se/~mhe/yafc/">. --> 最新版の yafc は <url url="http://www.stacken.kth.se/~mhe/yafc/"> から入手できます。 <p> <!-- Debian packages are available at <htmlurl url="http://members.home.com/decklin/experimental/">. --> Debian パッケージは <url url="http://members.home.com/decklin/experimental/"> から入手可能です。 <p> <!-- Redhat packages are available at <htmlurl url="http://lz.freeservers.com/linux/yafc.html">. --> Redhat パッケージは <url url="http://lz.freeservers.com/linux/yafc.html"> から入手可能です。 <sect> <!-- X Window FTP clients --> X Window System FTP クライアント <p> <!-- There are several graphical FTP clients designed to run on the X Window system. These clients offer ease of use for users who are used to graphical environments, and sometimes offer versatile options that would be hard to implement in a text-based ftp client. --> X Window System で起動するように設計されたグラフィカルな FTP クライアントも あります。 これらのクライアントはグラフィカル環境に慣れたユーザに使いやすさを提供し、さ らに時々 テキストベースの FTP クライアントでは提供するのが難しい融通の利くオプション を提供します。 <sect1>gFTP <p> <!-- gFTP is an FTP client for X Windows written using Gtk. The interface has some similarities to the popular WS_FTP software commonly used on a certain unstable operating system. --> gFTP は Gtk を使って書かれた X Windows System 用の FTP クライアントです。こ れのインターフェイスは、不安定な某 OS 上でよく利用される人気ソフト、WS_FTP に似たところがいくつかあります。 <p> <!-- gFTP features simultaneous downloads, resuming of interrupted file transfers, file transfer queues, downloading of entire directories, ftp proxy support, remote directory caching, passive and non-passive file transfers, drag-n-drop support, a very nice connection manager and more. --> gFTP は同時ダウンロード、中断されたファイル転送の再開、ファイル転送 キュー、ディレクトリ全体のダウンロード、FTP プロキシサポート、リモート ディレクトリキャッシング、パッシブとノンパッシブファイル転送、ドラッグ アンドドロップサポート、便利な接続マネージャとその他たくさんの機能を持ちま す。 <p> <!-- If you are running Red Hat Linux and have the GNOME desktop installed, then you probably already have gFTP. If not, you can download gFTP from its homepage at <htmlurl url="http://gftp.seul.org/">. --> もしあなたが Red Hat Linux を使っていて、 GNOME デスクトップがインストールさ れているなら、 恐らく gFTP を既に持っているでしょう。もしそうでなかったら gFTP のホームペー ジ <url url="http://gftp.seul.org/"> からダウンロードできます。 <sect1>WXftp <p> <!-- WXftp is an FTP client for the X Window System designed to be used mainly on Linux workstations. It is written using the WXWindows toolkit, so it can be compiled to use either Motif or GTK+ --> WXftp は 主に Linux ワークステーション上で使うために設計された X Window System 用の FTP クライアントです。これは WXWindows ツールキットを使用して書かれています ので、 Motif か GTK+ のどちらかを使用できるようにコンパイルすることができます。 <p> <!-- It includes an intuitive user interface (much like WS_FTP), a session manager, on-line help, a progress bar, and more --> これは直感的なインターフェイス(WS_FTP のような)、セッションマネージャ、 オンラインヘルプ、プログレスバー、その他たくさんの機能を持ちます。 <p> <!-- Check out WXftp's homepage at <htmlurl url="http://www.wxftp.seul.org">. --> WXftp のホームページ <url url="http://www.wxftp.seul.org"> を見て みましょう。 <sect1> <!-- LLNL XDIR and XFTP --> LLNL XDIR と XFTP <p> <!-- LLNL XFTP was one of the first graphical FTP clients for Linux. It supports FXP (file transfer between two remote hosts), and has a Motif based interface. --> LLNL XFTP は初期 Linux 用グラフィカル FTP クライアントのひとつです。 これは FXP (ふたつのリモートホスト間でのファイル転送)をサポートし、Motif ベース のインターフェイスを持ちます。 <p> <!-- More information is available at <htmlurl url="http://www.llnl.gov/ia/xdir_xftp/">. --> さらなる情報は <url url="http://www.llnl.gov/ia/xdir_xftp/"> で入手可能で す。 <sect1>guiftp <p> <!-- Guiftp is a simple ftp client written with the GTK+ toolkit. It's good if you don't need many features and want a simple, clean look. --> guiftp は GTK+ ツールキットで記述された簡単な FTP クライアントです。これは たくさんの機能は必要なくて、シンプルできれいな見た目が欲しいというときに よいでしょう。 <p> <!-- Guiftp's homepage is at <htmlurl url="http://www.altern.org/ldufresne/guiftp/">. --> guiftp のホームページは <url url="http://www.altern.org/ldufresne/guiftp/"> です。 <sect> <!-- FTP Servers --> FTP サーバ <sect1> <!-- How an FTP Server works --> FTP サーバのしくみ <p> <!-- A traditional FTP server is executed from inetd (the internet superserver daemon). The standard FTP port is port 21. When a user tries to log in, the FTP server uses a standard system call to check the user name and password against the entries in the system password file, or the NIS tables if you are using NIS. If the login is correct, the user is given access to the system. --> 伝統的な FTP サーバは inetd (internet superserver daemon)から実行されます。 標準の FTP ポートは 21 です。ユーザがログインしようとすると、FTP サーバは標 準システムコール を使ってユーザ名とパスワードが正しいかチェックします。普通はシステムパスワー ドファイルのエントリ、NIS を使っている場合は NIS テーブルのエントリと照合します。もしログインが正しい場合は、ユーザにシ ステムへのアクセス権が与えられます。 <p> <!-- Anonymous FTP works differently. The user logs in with either the anonymous or the ftp username (this can be defined in the config file). He is then given access to a directory tree that has been chroot()'ed. This ensures that the user can not gain access to directory trees he is not authorized for. The chrooted directory tree usually contains a mock filesystem, with bin/, etc/, and lib/ directories. The files for download are usually put in the pub/ directory. --> 匿名 FTP のしくみはまた別です。ユーザは anonymous (匿名)か、 FTP ユーザ名(こ れは 設定ファイルで定義できます)でログインします。そしてユーザは chroot() されて いる ディレクトリツリーにアクセスを与えられます。これはユーザが権限を与えられてい ない ディレクトリツリーにアクセスできないようにすることを確実にします。 chroot さ れた ディレクトリツリーは普通、bin/、etc/、と lib/ ディレクトリを含んだ模倣の ファイルシステムを持ちます。ダウンロードされるファイルは普通 pub/ ディレクト リに置かれます。 <p> <!-- The reason for a mock filesystem in an anonymous FTP tree is that the FTP daemon runs external commands for ls requests. You can also place additional programs in the bin directory, and a user can run them with the SITE command in his ftp client. For example, Red Hat's FTP includes the RPM command (for users to query RPM packages on the site). --> 匿名 FTP ツリー内の模倣のファイルシステムの理由は、FTP デーモンが ls の要求 の ために外部コマンドを実行するためです。これ以外のプログラムを bin ディレクト リに追加 することもできますし、ユーザは FTP クライアント内の SITE コマンドでこれらを 実行できます。 たとえば、Red Hat の FTP は RPM コマンドを含みます(ユーザがサイト上の RPM パッケージへ問い合わせ できるように)。 <p> <!-- Some FTP servers work differently. For example, some will allow user accounts to be set up independant of the system-wide password file (FTP-only accounts). Some servers (ProFTPD and NcFTPd for instance) have built-in ls commands and do not need a special directory tree within the chroot structure. Other ftp servers stray altogether from the standard ftp concept. FTP4ALL, for example, does not use system passwords at all. It uses it's own user and group file, and has features such as upload/download ratio and customizable server messages. --> さらに異なったしくみの FTP サーバもあります。たとえば、ユーザアカウントをシ ステム全体 のパスワードファイルから独立してセットされるのを許すものもあります(FTP オン リーのアカウント)。 ビルトインの ls コマンドを最初から持っていて、特別なディレクトリツリーを chroot 構造内に 必要としないものもあります(たとえば ProFTPD や NcFTPd)。その他、標準 ftp の 概念とは 全く異なったものもあります。たとえば FTP4ALL はシステムパスワードを全く使い ません。 これには独自のユーザとグループファイルを使用し、アップロードとダウンロードの 比率や カスタマイズできるサーバメッセージなどの機能があります。 <sect1> <!-- Help with FTP Servers --> FTP サーバについての助言 <sect2>WU-FTPD <p> <!-- WU-FTPD is the ftp daemon included with many Linux distributions, including Red Hat and Caldera. You can learn more about WU-FTPD at <htmlurl url="http://www.wu-ftpd.org">. --> WU-FTPD は Red Hat と Caldera や、その他たくさんの Linux ディストリビュー ションに 含まれている FTP デーモンです。 <url url="http://www.wu-ftpd.org"> で WU-FTPD についてもっと詳しいことを学べます。 <p> <!-- The WU-FTPD FAQ can be found on the web at <htmlurl url="http://www.cetis.hvu.nl/~koos/wu-ftpd-faq.html">. --> WU-FTPD FAQ は <url url="http://www.cetis.hvu.nl/~koos/wu-ftpd-faq.html"> で見つかります。 <sect2>ProFTPD  <p> <!-- ProFTPD is a powerful FTP server that includes Apache-style configuration, extensive support for virtual hosts, and internal ls. --> ProFTPD はアパッチ形式の設定、仮想ホストの広範囲サポート、インターナル ls を 含む パワフルな FTP サーバです。 <p> <!--A complete command reference and downloads can be found at <htmlurl url="http://www.proftpd.org"> --> <!-- http://www.proftpd.net に引越し --> 完全なコマンドリファレンスとダウンロードは <url url="http://www.proftpd.net"> で見つかります。 </article>