OSDN Git Service

Convert release and draft pages to UTF-8.
[linuxjm/jm.git] / manual / gnumaniak / draft / man1 / dd.1
1 .\" Copyright Andries Brouwer, A. Wik 1998, Ragnar Hojland Espinosa 1998-2002
2 .\"
3 .\" This file may be copied under the conditions described
4 .\" in the LDP GENERAL PUBLIC LICENSE, Version 1, September 1998
5 .\" that should have been distributed together with this file.
6 .\"
7 .\" Japanese Version Copyright (c) 1999-2003 Yuichi SATO
8 .\"         all rights reserved.                                               
9 .\" Translated Sat Oct 16 14:30:53 JST 1999
10 .\"         by Yuichi SATO <sato@complex.eng.hokudai.ac.jp>
11 .\" Updated & Modified Sun Feb 16 16:22:07 JST 2003
12 .\"         by Yuichi SATO <ysato444@yahoo.co.jp>
13 .\"
14 .TH DD 1 "18 June 2002" "GNU fileutils 4.1"
15 .\"O .SH NAME
16 .SH 名前
17 .\"O dd \- convert and copy a file
18 dd \- ファイルを変換してコピーする
19 .\"O .SH SYNOPSIS
20 .SH 書式
21 .B dd
22 .B [\-\-help] [\-\-version]
23 .BI [if= file ]
24 .BI [of= file ]
25 .BI [ibs= bytes ]
26 .BI [obs= bytes ]
27 .BI [bs= bytes ]
28 .BI [cbs= bytes ]
29 .BI [skip= blocks ]
30 .BI [seek= blocks ]
31 .BI [count= blocks ]
32 .B "[conv={ascii, ebcdic, ibm, block, unblock, lcase, ucase, swab, noerror, notrunc, sync}]"
33 .\"O .SH DESCRIPTION
34 .SH 説明
35 .\"O .B dd
36 .\"O copies a file (from standard input to standard output, by
37 .\"O default) using specific input and output blocksizes,
38 .\"O while optionally performing conversions on it.
39 .B dd
40 はファイルを指定された入出力ブロックサイズで
41 (デフォルトでは標準入力から標準出力へ) コピーする。
42 入出力の間に変換を指定することもできる。
43 .PP
44 .\"O It reads the input one block at a time, using the specified input
45 .\"O block size (the default is 512 bytes).
46 .\"O If the
47 .\"O .BI bs= bytes
48 .\"O option was given, and no conversion other than
49 .\"O .BR sync ", " noerror ", or " notrunc
50 .\"O was specified, it writes the amount of data read (which could be smaller
51 .\"O than what was requested) in a separate output block. This output block
52 .\"O has precisely the same length as was read unless the
53 .\"O .B sync
54 .\"O conversion was specified, in which case the data is padded with NULs
55 .\"O or spaces (see below).
56 .B dd
57 は指定された入力ブロックサイズ (デフォルトは 512 バイト) で、
58 一度に 1 ブロックを読み込む。
59 .BI bs= bytes
60 オプションが指定されていて、
61 .BR sync ", " noerror ", " notrunc
62 以外の変換が指定されていない場合、
63 読み込んだ全データ (要求されたサイズより小さくてもよい)
64 を出力ブロックに書き出す。
65 この出力ブロックは
66 .B sync
67 変換が指定されていない限り、
68 読み込まれたものと正確に同じ長さを持っている。
69 .B sync
70 が指定された場合は、
71 データは NUL またはスペースで埋められる (下記参照)。
72 .PP
73 .\"O Otherwise, the input, read one block at a time, is processed
74 .\"O and the resulting output is collected and written in blocks
75 .\"O of the specified output block size. The final output block
76 .\"O may be shorter.
77 それ以外の場合、入力は一度に 1 ブロックずつ読み込まれて処理され、
78 その結果は出力ブロックサイズに指定された大きさごとに書き出される。
79 最後の出力ブロックは短くなることがある。
80 .PP
81 .\"O The numeric-valued options below (bytes and blocks) can be followed
82 .\"O by a multiplier, as listed in \fBMULTIPLIERS\fR.  Two or more of such
83 .\"O numeric expressions can be multiplied by putting \fBx\fR in between.
84 下記の (バイトまたはブロック) といった数値オプションの後ろには、
85 \fB乗数\fRの項目で挙げる乗数を続けて置くことができる。
86 \fBx\fR を間に挟んで、このような数値表記を 2 つ以上掛けあわせることもできる。
87 .\"O .SH OPTIONS
88 .SH オプション
89 .TP
90 .BI "if=" file
91 .\"O Read from
92 .\"O .I file
93 .\"O instead of standard input.
94 標準入力の代わりに、ファイル 
95 .I file 
96 から読み込む。
97 .TP
98 .BI "of=" file
99 .\"O Write to
100 .\"O .I file
101 .\"O instead of standard output.  Unless
102 .\"O .B conv=notrunc
103 .\"O is given,
104 .\"O .B dd
105 .\"O truncates
106 .\"O .I file
107 .\"O to zero bytes (or the size specified with
108 .\"O .BR seek= ")."
109 標準出力の代わりに、ファイル
110 .I file
111 へ書き出す。
112 .B conv=notrunc
113 が与えられない限り、
114 .B dd
115 はファイル
116 .I file
117 を (訳注: コピー前に) 0 バイト (もしくは
118 .BR seek= 
119 で指定されたサイズ) に切り詰める。
120 .TP
121 .BI "ibs=" bytes
122 .\"O Read
123 .\"O .I bytes
124 .\"O bytes at a time. The default is 512.
125 一度に
126 .I bytes
127 バイトずつ読み込む。デフォルトは 512。
128 .TP
129 .BI "obs=" bytes
130 .\"O Write
131 .\"O .I bytes
132 .\"O bytes at a time. The default is 512.
133 一度に
134 .I bytes
135 バイトずつ書き出す。デフォルトは 512。
136 .TP
137 .BI "bs=" bytes
138 .\"O Both read and write
139 .\"O .I bytes
140 .\"O bytes at a time.  This overrides
141 .\"O .B ibs
142 .\"O and
143 .\"O .BR obs .
144 一度に
145 .I bytes
146 バイトずつ読み込みと書き出しをする。
147 .B ibs
148
149 .B obs
150 より優先される。
151 .\"O (And setting
152 .\"O .B bs
153 .\"O is not equivalent with setting both
154 .\"O .B ibs
155 .\"O and
156 .\"O .B obs
157 .\"O to this same value, at least when no conversion other than
158 .\"O .BR sync ,
159 .\"O .B noerror
160 .\"O and
161 .\"O .B notrunc
162 .\"O is specified, since it stipulates that each input block
163 .\"O shall be copied to the output as a single block
164 .\"O without aggregating short blocks.)
165 (少なくとも
166 .BR sync ,
167 .BR noerror ,
168 .B notrunc
169 以外の変換が指定されていない場合には、
170 .B bs
171 の指定は
172 .B ibs
173
174 .B obs
175 の両方をこれと同じ値に設定することと等価ではない。
176 なぜなら
177 .B bs
178 では、各入力ブロックが単一の出力ブロックにコピーされる、
179 すなわち短い複数の入力ブロックをまとめない、
180 ということが規定されているからである。)
181 .TP
182 .BI "cbs=" bytes
183 .\"O Specify the conversion block size for
184 .\"O .B block
185 .\"O and
186 .\"O .BR unblock .
187 .B block
188
189 .B unblock
190 の変換ブロックサイズを指定する。
191 .TP
192 .BI "skip=" blocks
193 .\"O Skip
194 .\"O .I blocks
195 .\"O .BR ibs -byte
196 .\"O blocks in the input file before copying.
197 .B ibs
198 バイトのブロック
199 .I blocks
200 個分だけ入力ファイルの先頭をスキップする。
201 .TP
202 .BI "seek=" blocks
203 .\"O Skip
204 .\"O .I blocks
205 .\"O .BR obs -byte
206 .\"O blocks in the output file before copying.
207 出力の先頭にある
208 .B obs
209 バイトのブロック
210 .I blocks
211 個分を書き出さない。
212 .TP
213 .BI "count=" blocks
214 .\"O Copy
215 .\"O .I blocks
216 .\"O .BR ibs -byte
217 .\"O blocks from the input file, instead of everything
218 .\"O until the end of the file.
219 入力ファイルの終りまで全てではなく、
220 .B ibs
221 バイトのブロック
222 .I blocks
223 個分だけ入力ファイルをコピーする。
224 .TP
225 .BI "conv=" CONVERSION "[," CONVERSION "]..."
226 .\"O Convert the file as specified by the
227 .\"O .I CONVERSION
228 .\"O argument(s).  (No spaces around any comma(s).)
229 引き数
230 .I CONVERSION
231 で指定されたファイル変換を行う。(コンマの前後にスペースを置かない。)
232 .RS
233 .PP
234 .\"O Conversions:
235 変換:
236 .PP
237 .TP
238 .B ascii
239 .\"O Convert EBCDIC to ASCII.
240 EBCDIC から ASCII に変換する。
241 .TP
242 .B ebcdic
243 .\"O Convert ASCII to EBCDIC.
244 ASCII から EBCDIC に変換する。
245 .TP
246 .B ibm
247 .\"O Convert ASCII to alternate EBCDIC.
248 ASCII から別の (IBM の) EBCDIC に変換する。
249 .TP
250 .B block
251 .\"O For each line in the input, output
252 .\"O .B cbs
253 .\"O bytes, replacing the input newline with a space and padding
254 .\"O with spaces as necessary.
255 入力された各行につき、
256 .B cbs
257 バイトずつを出力する。
258 改行文字は空白文字で置き換え、
259 必要であれば複数の空白文字を詰める。
260 .TP
261 .B unblock
262 .\"O Replace trailing spaces in each
263 .\"O .BR cbs -sized
264 .\"O input block with a newline.
265 入力された
266 .B cbs
267 バイトのブロックそれぞれにおいて、
268 末尾の連続した複数の空白文字を一つの改行文字に変換する。
269 .TP
270 .B lcase
271 大文字を小文字に変換する。
272 .TP
273 .B ucase
274 小文字を大文字に変換する。
275 .TP
276 .B swab
277 .\"O Swap every pair of input bytes.
278 .\"O .SM GNU
279 .\"O .BR dd ,
280 .\"O unlike others, works when an odd number of bytes are read--the last
281 .\"O byte is simply copied (since there is nothing to swap it with).
282 入力バイトの全ての (訳註:2バイトずつの) ペアを入れ換える。
283 .SM GNU
284 .B dd
285 は他と違い、奇数個のバイトを読み込んだ場合にも動作する。
286 奇数個の場合、
287 最後のバイトは (入れ換えるバイトがないので) 単純にコピーされる。
288 .TP
289 .B noerror
290 .\"O Continue after read errors.
291 読み込みエラーが発生しても継続する。
292 .TP
293 .B notrunc
294 .\"O Do not truncate the output file.
295 出力ファイルを切り詰めない。
296 (訳注: 書き込み前の切り詰めを行わず、
297 そのまま先頭バイトから書き込みを行います。
298 入力ファイルと出力ファイルが同じ場合にファイルが壊れません。)
299 .TP
300 .B sync
301 .\"O Pad every input block to size of
302 .\"O .B ibs
303 .\"O with trailing zero bytes.
304 .\"O with trailing NULs, unless \fBblock\fR or \fBunblock\fR was used.
305 \fBblock\fR または \fBunblock\fR が指定されていなければ、
306 各入力ブロックに対して、大きさが
307 .B ibs
308 になるまで連続して NUL (バイト 0) を詰める。
309 指定されている場合はスペースで詰める。
310 .RE
311 .\"O .SH "GNU STANDARD OPTIONS"
312 .SH "GNU 標準オプション"
313 .TP
314 .B "\-\-help"
315 .\"O Print a usage message on standard output and exit successfully.
316 標準出力に使用方法のメッセージを出力して正常終了する。
317 .TP
318 .B "\-\-version"
319 .\"O Print version information on standard output, then exit successfully.
320 標準出力にバージョン情報を出力して正常終了する。
321 .TP
322 .B "\-\-"
323 .\"O Terminate option list.
324 オプションリストの終りを示す。
325 .\"O .SH MULTIPLIERS
326 .SH 乗数
327 .\"O Numbers may be followed by a size letter to specify a multiple of that
328 .\"O size, and a \fBB\fR to select normal bytes or a \fBD\fR to select
329 .\"O decimal "commercial" bytes.  For example `1KB' is equal to `1024' and
330 .\"O `1KD' is equal to `1000'.  Exceptions are \fBb\fR (512 bytes), \fBc\fR (1
331 .\"O byte), and \fBw\fR (which should never be used - it means 2 in System V and
332 .\"O 4 in 4.2BSD), which can't be followed by a \fBB\fR or \fBD\fR.
333 数値の後には、倍数を指定するサイズ指定文字と、
334 通常のバイトを意味する \fBB\fR または
335 10 進の「商業用」バイトを意味する \fBD\fR を
336 続けて置くことができる。
337 たとえば `1KB' は `1024' と等しく、`1KD' は `1000' と等しい。
338 この例外は \fBb\fR (512 バイト)、\fBc\fR (1 バイト)、
339 \fBw\fR (使うべきでない - System V では 2 を意味し、
340 4.2BSD では 4 を意味する) の 3 つで、
341 これらの後に \fBB\fR や \fBD\fR をおくことはできない。
342 .TP
343 .B k
344 .\"O kilo: 2^10 = 1024 for normal bytes, or 10^3 = 1000 for decimal bytes
345 キロ: 通常バイト指定なら 2^10 = 1024、10 進バイト指定なら 10^3 = 1000
346 .TP
347 .B M
348 .\"O Mega: 2^20 = 1,048,576 or 10^6 = 1,000,000
349 メガ: 2^20 = 1,048,576 または 10^6 = 1,000,000
350 .TP
351 .B G
352 .\"O Giga: 2^30 = 1,073,741,824 or 10^9 = 1,000,000,000
353 ギガ: 2^30 = 1,073,741,824 または 10^9 = 1,000,000,000
354 .TP
355 .B T
356 .\"O Tera: 2^40 = 1,099,511,627,776 or 10^12 = 1,000,000,000,000
357 テラ: 2^40 = 1,099,511,627,776 または 10^12 = 1,000,000,000,000
358 .TP
359 .B P
360 .\"O Peta: 2^50 = 1,125,899,906,842,624 or 10^15 = 1,000,000,000,000,000
361 ペタ: 2^50 = 1,125,899,906,842,624 
362 または 10^15 = 1,000,000,000,000,000
363 .TP
364 .B E
365 .\"O Exa: 2^60 = 1,152,921,504,606,846,976 or 10^18 = 1,000,000,000,000,000,000
366 エクサ: 2^60 = 1,152,921,504,606,846,976 
367 または 10^18 = 1,000,000,000,000,000,000
368 .TP
369 .B Z
370 .\"O Zetta: 2^70 = 1,180,591,620,717,411,303,424 or 10^21 =
371 .\"O 1,000,000,000,000,000,000,000
372 ゼタ: 2^70 = 1,180,591,620,717,411,303,424
373 または 10^21 = 1,000,000,000,000,000,000,000
374 .TP
375 .B Y
376 .\"O Yotta: 2^80 = 1,208,925,819,614,629,174,706,176 or 10^24 =
377 .\"O 1,000,000,000,000,000,000,000,000
378 ヨタ: 2^80 = 1,208,925,819,614,629,174,706,176 
379 または 10^24 = 1,000,000,000,000,000,000,000,000
380 .\"O .SH ENVIRONMENT
381 .SH "環境変数"
382 .\"O The variables LANG, LC_ALL, LC_CTYPE and LC_MESSAGES have the
383 .\"O usual meaning.
384 変数 LANG, LC_ALL, LC_CTYPE, LC_MESSAGES が通常の意味を持つ。
385 .\"O .SH "CONFORMING TO"
386 .SH "準拠"
387 POSIX 1003.2
388 .\"O .SH NOTES
389 .SH "注意"
390 .\"O This page describes
391 .\"O .B dd
392 .\"O as found in the fileutils-4.1 package;
393 .\"O other versions may differ slightly. Mail corrections and additions to
394 .\"O aeb@cwi.nl and aw@mail1.bet1.puv.fi and ragnar@ragnar-hojland.com
395 .\"O Report bugs in the program to bug-fileutils@gnu.org.
396 このページは fileutils-4.1 パッケージの
397 .B dd
398 コマンドについて説明したものである;
399 その他のバージョンでは少し違いがあるかもしれない。
400 修正や追加は aeb@cwi.nl, aw@mail1.bet1.puv.fi, ragnar@ragnar-hojland.com
401 宛にメールで連絡してください。
402 プログラムのバグについては bug-fileutils@gnu.org へ報告してください。