16.12.2012 Views

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

dd<br />

Example<br />

ibs=size<br />

Sets the input block size in bytes. You specify it in the same way as with<br />

the bs option.<br />

if=file Reads input data from file. If you don’t specify this option, dd reads data<br />

from standard input (stdin).<br />

imsg=string<br />

Displays string when all data has been read from the current volume,<br />

replacing all occurrences of %d in string with the number of the next volume<br />

to be read. dd then reads and discards a line from the controlling terminal.<br />

iseek=n<br />

seeks to the nth block of the input file. The distinction between this and the<br />

skip option is that iseek does not read the discarded data. There are some<br />

devices, however, such as tape drives and communication lines, on which<br />

seeking is not possible, so only skip is appropriate.<br />

obs=size<br />

Sets the output block size in bytes. You specify it in the same way as the<br />

bs value. The size of the destination should be a multiple of the value<br />

chosen for size. For example, if you choose obs=10K, the destination’s size<br />

should be a multiple of 10K.<br />

of=file Writes output data to file. If you don’t specify this option, dd writes data to<br />

standard output (stdout). dd truncates the output file before writing to it,<br />

unless you specified the seek=n operand. If you specify seek=n, but do not<br />

specify conv=notrunc, dd preserves only those blocks in the output file over<br />

which it seeks. If the size of the seek plus the size of the input file is less<br />

than the size of the output file, this can result in a shortened output file.<br />

omsg=string<br />

Displays string when dd runs out of room while writing to the current<br />

volume. Any occurrences of %d in string are replaced with the number of the<br />

next volume to be written. dd then reads and discards a line from the<br />

controlling terminal.<br />

seek=n<br />

Initially seeks to the nth block of the output file.<br />

skip=n<br />

Entering:<br />

Note: Use caution when working with DBCS characters and the seek<br />

option. Seeking into the output file that contains DBCS characters<br />

can cause the DBCS string in the output file to be corrupted. Be sure<br />

that the seek count is not aligned with an existing DBCS string in the<br />

output file. Otherwise, part of the existing DBCS string either is<br />

written over with singlebyte data or has extra shift codes from the<br />

input file’s DBCS data.<br />

Reads and discards the first n blocks of input.<br />

dd if=in of=out conv=ascii cbs=80 ibs=6400 obs=512<br />

converts 80-byte fixed-length EBCDIC card images in 6400-byte input blocks to<br />

variable-length ASCII lines, 512 bytes to the output block.<br />

232 z/<strong>OS</strong> <strong>V1R9.0</strong> <strong>UNIX</strong> <strong>System</strong> <strong>Services</strong> <strong>Command</strong> Reference

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!