3 sz \- send a file using the zmodem protocol
5 \fBsz\fR [\fB\-LNbdefnopqruvy+\fR]\fR [\fB\-ci \fIcommand\fR] [\fB\-Ll\fR n\fR] [\fB\-t \fItimeout\fR]\fR
20 # Use \fIn\fR-byte packets
23 # Overwrite if source is newer/longer
29 # Send command for execution
32 # Convert dot to slash in names
35 # Escape for all control characters
41 # Send command and return immediately
44 # Flow control every \fIn\fR packets
47 # Overwrite destination if source is newer
50 # Use old (16-bit) checksum
53 # Protect file if it already exists
56 # Quiet; opposite of verbose
59 # Resume interrupt file transfer
62 # Set \fItimeout\fR in tenths of a second
65 # Unlink file after successful transmission
68 # Verbose; opposite of quiet
71 # Yes, clobber existing files
74 # Append to an existing file
77 .B sz file </dev/tty01 >/dev/tty01
81 XMODEM, YMODEM, and ZMODEM are a family of protocols that are widely used
82 is the \s-2MS-DOS\s0 world for transferring information reliably from one
83 computer to another. In all of these protocols, a series of bytes are sent
84 from one computer to the other, and then an acknowledgement is sent back
85 to confirm correct reception. Checksums are used to detect errors so that
86 transmission is reliable even in the face of noisy telephone lines.
87 \fISz\fR is a program that sends a file sent from another computer using the
89 The file can be received using \fIrz\fR.
91 \fISz\fR uses the ZMODEM error correcting
92 protocol to send one or more files over a dial-in serial
93 port to a variety of programs running under
96 \s-2MS-DOS\s0, \s-2CP/M\s0, \s-2VMS\s0, and other operating systems.
97 It is the successor to XMODEM and YMODEM.
99 ZMODEM greatly simplifies file transfers compared to XMODEM.
100 In addition to a friendly user interface, ZMODEM provides
101 Personal Computer and other users an efficient, accurate,
102 and robust file transfer method.
104 ZMODEM provides complete end-to-end data integrity between
105 application programs. ZMODEM's 32 bit CRC catches errors
106 that sneak into even the most advanced networks.
108 Output from another program may be piped to \fIsz\fR for
109 transmission by denoting standard input with \-:
111 .B " ""ls \-l | sz \-"
113 The program output is transmitted with the filename \fIsPID.sz\fR
114 where PID is the process ID of the \fIsz\fR program. If the
115 environment variable \fIONAME\fR is set, that is used instead. In
116 this case, the command:
118 .B " ""ls \-l | ONAME=con sz \-ay \-"
120 will send a \&'file\&' to the PC-DOS console display.
121 The \fB\-y\fR option instructs the receiver to open the file for writing
123 The \fB\-a\fR option causes the receiver to
126 newlines to PC-DOS carriage returns and linefeeds.
129 systems, additional information about the file is
130 transmitted. If the receiving program uses this
131 information, the transmitted file length controls the exact
132 number of bytes written to the output dataset, and the
133 modify time and file mode are set accordingly.
135 If \fIsz\fR is invoked with $SHELL set and if that variable
136 contains the string \fIrsh\fR or \fIrksh\fR (restricted shell), \fIsz\fR
137 operates in restricted mode. Restricted mode restricts
138 pathnames to the current directory and \fIPUBDIR\fR (usually
139 \fI/usr/spool/uucppublic\fR) and/or subdirectories thereof.
141 The options and flags available are:
146 Instruct the receiver to append transmitted data to an existing file.
150 Convert NL characters in the transmitted file to CR/LF.
151 This is done by the sender for XMODEM and YMODEM, by the receiver for ZMODEM.
155 Binary override: transfer file without any translation.
159 Send COMMAND (follows \fIc\fR) to the receiver for execution, return with
160 COMMAND's exit status.
164 Change all instances of \&'.\&' to \&'/\&' in the transmitted
165 pathname. Thus, C.omenB0000 (which is unacceptable to
166 \s-2MS-DOS\s0 or CP/M) is transmitted as C/omenB0000. If the
167 resultant filename has more than 8 characters in the
168 stem, a \&'.\&' is inserted to allow a total of eleven.
172 Escape all control characters; normally XON, XOFF, DLE,
173 CR-@-CR, and Ctrl-X are escaped.
177 Send Full pathname. Normally directory prefixes are stripped from
178 the transmitted filename.
182 Send COMMAND (follows \fIi\fR) to the receiver for execution, return
183 Immediately upon the receiving program's successful reception of the command.
187 Use ZMODEM sub-packets of length \fIn\fR (follows \fIL\fR).
188 A larger \fIn\fR (32 <= \fIn\fR <= 1024) gives slightly higher throughput, a
189 smaller one speeds error recovery. The default is 128 below 300
190 baud, 256 above 300 baud, or 1024 above 2400 baud.
194 Wait for the receiver to acknowledge correct data every
195 \fIn\fR (32 <= \fIn\fR <= 1024) characters.
196 This may be used to avoid network overrun when XOFF flow control is lacking.
200 Send each file if destination file does not exist.
201 Overwrite destination file if source file is newer than the destination file.
205 Send each file if destination file does not exist. Overwrite destination
206 file if source file is newer or longer than the destination file.
210 Disable automatic selection of 32 bit CRC.
214 Protect existing destination files by skipping transfer if the destination
219 Quiet suppresses verbosity.
223 Resume interrupted file transfer. If the source file is longer than the
224 destination file, the transfer commences at the offset in the source file
225 that equals the length of the destination file.
230 The timeout, in tenths of seconds, follows, the \fB\-t\fR flag.
234 Unlink the file after successful transmission.
238 Limit the transmit window size to \fIn\fR bytes (\fIn follows \fB(enw\fR).
242 Verbose causes a list of file names to be appended to \fI/tmp/szlog\fR.
246 Instruct a ZMODEM receiving program to overwrite any existing file with the
251 Instruct a ZMODEM receiving program to overwrite any existing file with the
252 same name, and to skip any source files that do have a file with the same
253 pathname on the destination system.
257 Below are some examples of the use of \fIsz\fR.
259 .B " ""sz \-a \d\s+2*\s0\u.c"
261 This single command transfers all .c files in the current
262 directory with conversion (\fB\-a\fR) to end-of-line
263 conventions appropriate to the receiving environment.
265 .B " ""sz \-Yan \d\s+2*\s0\u.c \d\s+2*\s0\u.h"
268 Send only the \fI.c\fR and \fI.h\fR files that exist on both systems,
269 and are newer on the sending system than the corresponding
270 version on the receiving system, converting
272 to \s-2MS-DOS\s0 text format.