[patch] fix parallel building of tftp-hpa
[tftp-hpa.git] / tftp / tftp.1.in
blob41606fec3bbbe7812d52b7dd7b2dc9b65c3fbd5d
1 .\" -*- nroff -*- --------------------------------------------------------- *
2 .\" $Id$
3 .\"  
4 .\" Copyright (c) 1990, 1993, 1994
5 .\"     The Regents of the University of California.  All rights reserved.
6 .\"
7 .\" Copyright 2001 H. Peter Anvin - All Rights Reserved
8 .\"
9 .\" Redistribution and use in source and binary forms, with or without
10 .\" modification, are permitted provided that the following conditions
11 .\" are met:
12 .\" 1. Redistributions of source code must retain the above copyright
13 .\"    notice, this list of conditions and the following disclaimer.
14 .\" 2. Redistributions in binary form must reproduce the above copyright
15 .\"    notice, this list of conditions and the following disclaimer in the
16 .\"    documentation and/or other materials provided with the distribution.
17 .\" 3. Neither the name of the University nor the names of its contributors
18 .\"    may be used to endorse or promote products derived from this software
19 .\"    without specific prior written permission.
20 .\"
21 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
22 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
25 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 .\" SUCH DAMAGE.
32 .\"
33 .\"----------------------------------------------------------------------- */
34 .TH TFTP 1 "12 December 2006" "tftp-hpa @@VERSION@@" "User's Manual"
35 .SH NAME
36 .B tftp
37 \- IPv4 Trivial File Transfer Protocol client
38 .SH SYNOPSIS
39 .B tftp
40 [ \fIoptions...\fP ]
41 [\fIhost\fP [\fIport\fP]]
42 [\fB\-c\fP \fIcommand\fP]
43 .br
44 .SH DESCRIPTION
45 .B tftp
46 is a client for the IPv4 Trivial file Transfer Protocol, which can be
47 used to transfer files to and from remote machines, including some
48 very minimalistic, usually embedded, systems.  The remote
49 .I host
50 may be specified on the command line, in which case
51 .B tftp
52 uses
53 .I host
54 as the default host for future transfers (see the
55 .B connect
56 command below.)
57 .SH OPTIONS
58 .TP
59 \fB\-c\fP \fIcommand\fP
60 Execute \fIcommand\fP as if it had been entered on the tftp prompt.
61 Must be specified last on the command line.
62 .TP
63 .B \-l
64 Default to literal mode. Used to avoid special processing of ':' in a
65 file name.
66 .TP
67 \fB\-m\fP \fImode\fP
68 Set the default transfer mode to \fImode\fP.  This is usually used with \-c.
69 .TP
70 \fB\-R\fP \fIport:port\fP
71 Force the originating port number to be in the specified range of port
72 numbers.
73 .TP
74 .B \-v
75 Default to verbose mode.
76 .TP
77 .B \-V
78 Print the version number and configuration to standard output, then
79 exit gracefully.
80 .SH COMMANDS
81 Once
82 .B tftp
83 is running, it issues the prompt
84 \f(CWtftp>\fP
85 and recognizes the following commands:
86 .TP
87 \fB?\fP \fIcommand-name...\fP
88 .TP
89 \fBhelp\fP \fIcommand-name...\fP
90 Print help information
91 .TP
92 .B ascii
93 Shorthand for
94 .BR "mode ascii" .
95 .TP
96 .B binary
97 Shorthand for
98 .BR "mode binary" .
99 .TP
100 \fBconnect\fP \fIhost [port]\fP
101 Set the
102 .I host
103 (and optionally
104 .IR port )
105 for transfers.  Note that the TFTP protocol, unlike the FTP protocol,
106 does not maintain connections between transfers; thus, the
107 .B connect
108 command does not actually create a connection, but merely remembers
109 what host is to be used for transfers.  You do not have to use the
110 .B connect
111 command; the remote host can be specified as part of the
112 .B get
114 .B put
115 commands.
117 \fBget\fP \fIfile\fP
118 .sp -.6l
120 \fBget\fP \fIremotefile localfile\fP
121 .sp -.6l
123 \fBget\fP \fIfile1 file2 file3...\fP
124 Get a file or set of files from the specified sources.  A remote
125 filename can be in one of two forms: a plain filename on the remote
126 host, if the host has already been specified, or a string of the form
127 .I "host:filename"
128 to specify both a host and filename at the same time.  If the latter
129 form is used, the last hostname specified becomes the default for
130 future transfers.  Enable
131 .B literal
132 mode to prevent special treatment of the ':' character (e.g. C:\\dir\\file).
134 .B literal
135 Toggle literal mode.  When set, this mode prevents special treatment of ':' in filenames. 
137 \fBmode\fP \fItransfer-mode\fP
138 Specify the mode for transfers;
139 .I transfer-mode
140 may be one of
141 .B ascii
143 .BR netascii )
145 .B binary
147 .BR octet .)
148 The default is
149 .BR ascii .
151 \fBput\fP \fIfile\fP
152 .sp -.6l
154 \fBput\fP \fIlocalfile remotefile\fP
155 .sp -.6l
157 \fBput\fP \fIfile1 file2 file3... remote-directory\fP
158 Put a file or set of files to the specified remote file or directory.
159 The destination can be in one of two forms: a filename on the remote
160 host, if the host has already been specified, or a string of the form
161 .I "host:filename"
162 to specify both a host and filename at the same time.  If the latter
163 form is used, the hostname specified becomes the default for future
164 transfers.  If the remote-directory form is used, the remote host is
165 assumed to be a UNIX system or another system using
166 .B /
167 as directory separator.  Enable
168 .B literal
169 mode to prevent special treatment of the ':' character (e.g. C:\\dir\\file).
171 .B quit
172 Exit
173 .BR tftp .
174 End-of-file will also exit.
176 \fBrexmt\fP \fIretransmission-timeout\fP
177 Set the per-packet retransmission timeout, in seconds.
179 .B status
180 Show current status.
182 \fBtimeout\fP \fItotal-transmission-timeout\fP
183 Set the total transmission timeout, in seconds.
185 .B trace
186 Toggle packet tracing (a debugging feature.)
188 .B verbose
189 Toggle verbose mode.
190 .SH "NOTES"
191 The TFTP protocol provides no provisions for authentication or
192 security.  Therefore, the remote server will probably implement some
193 kinds of access restriction or firewalling.  These access restrictions
194 are likely to be site- and server-specific.
195 .SH "AUTHOR"
196 This version of
197 .B tftp
198 is maintained by H. Peter Anvin <hpa@zytor.com>.  It was derived from,
199 but has substantially diverged from, an OpenBSD source base, with
200 added patches by Markus Gutschke and Gero Kulhman.
201 .SH "SEE ALSO"
202 .BR tftpd (8).