プロジェクト

全般

プロフィール

Robocopy » 履歴 » バージョン 5

健二 酒井, 2019/04/23 15:17
無駄な努力お疲れ俺

1 1 健二 酒井
# Robocopy
2 1 健二 酒井
3 1 健二 酒井
頑張ってrobocopyの使い方を翻訳する
4 1 健二 酒井
5 5 健二 酒井
先駆者いたわ。マジ感謝。
6 5 健二 酒井
http://former.sunvisor.net/win/robocopy.html#file_class
7 1 健二 酒井
8 1 健二 酒井
9 1 健二 酒井
## 訳
10 1 健二 酒井
11 1 健二 酒井
### その1
12 1 健二 酒井
13 1 健二 酒井
```
14 1 健二 酒井
-------------------------------------------------------------------------------
15 1 健二 酒井
   ROBOCOPY     ::     Windows向けの堅牢なファイルコピー
16 1 健二 酒井
-------------------------------------------------------------------------------
17 1 健二 酒井
18 1 健二 酒井
  開始    : 2019年4月21日 21:49:46
19 1 健二 酒井
  コピー元 -
20 1 健二 酒井
  コピー先 -
21 1 健二 酒井
22 1 健二 酒井
    ファイル :
23 1 健二 酒井
  オプション : /DCOPY:DA /COPY:DAT /R:1000000 /W:30
24 1 健二 酒井
25 1 健二 酒井
------------------------------------------------------------------------------
26 1 健二 酒井
27 1 健二 酒井
エラー : 無効な引数 #1 : "/help"
28 1 健二 酒井
29 1 健二 酒井
       簡単な使い方  :: ROBOCOPY <コピー元> <コピー先> /MIR
30 1 健二 酒井
31 1 健二 酒井
            <コピー元> :: コピー元ディレクトリ (ドライブ文字:\パス または \\サーバー\共有フォルダ\パス).
32 1 健二 酒井
            <コピー先> :: コピー先ディレクトリ  (ドライブ文字:\パス または \\サーバー\共有フォルダ\パス).
33 1 健二 酒井
               /MIR :: ディレクトリツリーを忠実に復元します(原語:Mirror).
34 1 健二 酒井
35 1 健二 酒井
    これ以上の使い方の情報が欲しいとき ROBOCOPY /?
36 1 健二 酒井
37 1 健二 酒井
38 1 健二 酒井
****  /MIR はコピーするのと同じように「削除も」します
39 1 健二 酒井
```
40 1 健二 酒井
41 1 健二 酒井
### その2
42 1 健二 酒井
43 1 健二 酒井
```
44 1 健二 酒井
45 2 健二 酒井
::
46 2 健二 酒井
:: コピー オプション :
47 2 健二 酒井
::
48 2 健二 酒井
                 /S :: サブディレクトリをコピーします。ただし、空ディレクトリは含みません。
49 2 健二 酒井
                 /E :: サブディレクトリをコピーします。空ディレクトリも含みます。
50 2 健二 酒井
             /LEV:n :: コピー元ディレクトリツリーから上位n階層(原語:n LEVles)のみコピーします。
51 1 健二 酒井
52 2 健二 酒井
                 /Z :: 再開モードでファイルをコピーします。copy files in restartable mode.
53 2 健二 酒井
                 /B :: バックアップモードでファイルをコピーします.
54 2 健二 酒井
                /ZB :: 再開モードを使用します。アクセスできないときバックアップモードを使用します。
55 2 健二 酒井
                 /J :: バッファ無しI/Oを使用してコピーします(大きいファイルにおススメです)
56 2 健二 酒井
            /EFSRAW :: 暗号化ファイルをEFS RAWモードでコピーします。
57 2 健二 酒井
58 2 健二 酒井
  /COPY:コピーフラグ[s] :: 何をコピーするか指定します (初期値 /COPY:DAT).
59 2 健二 酒井
                       (コピーフラグ : D=データ, A=属性(原語:Attributes), T=タイムスタンプ).
60 2 健二 酒井
                       (S=Security=NTFS ACL, O=所有者情報, U=監査情報).
61 2 健二 酒井
62 2 健二 酒井
63 2 健二 酒井
               /SEC :: セキュリティ情報もコピーします (/COPY:DATSと等価です).
64 2 健二 酒井
           /COPYALL :: 全ての情報をコピーします (/COPY:DATSOUと等価です).
65 2 健二 酒井
            /NOCOPY :: ファイル情報をコピーしません。 (/PURGEとの併用が便利です).
66 2 健二 酒井
            /SECFIX :: FIX file SECurity on all files, even skipped files.
67 2 健二 酒井
            /TIMFIX :: FIX file TIMes on all files, even skipped files.
68 2 健二 酒井
69 2 健二 酒井
             /PURGE :: コピー元に存在しないファイル/ディレクトリをコピー先から削除します。
70 2 健二 酒井
               /MIR :: ディレクトリツリーを忠実に複製(原語:MIRror)します (これは/Eと/PURGEの指定に等価です。)
71 2 健二 酒井
72 2 健二 酒井
               /MOV :: ファイルを移動します(コピー後に、コピー元から削除されます)。
73 2 健二 酒井
              /MOVE :: ファイルとディレクトリを移動します (コピー後に、コピー元から削除されます).
74 2 健二 酒井
75 3 健二 酒井
     /A+:[RASHCNET] :: コピーされたファイルに属性を追加します。
76 3 健二 酒井
     /A-:[RASHCNET] :: コピーされたファイルから属性を削除します。
77 2 健二 酒井
78 3 健二 酒井
            /CREATE :: ディレクトリツリーとサイズ0のファイルのみ作成します。
79 3 健二 酒井
               /FAT :: 8.3FATファイル名でファイルを作成します。
80 3 健二 酒井
               /256 :: 長いファイルパス(256文字より多い)のサポートをオフにします。
81 2 健二 酒井
82 3 健二 酒井
             /MON:n :: コピー元を監視します。n個以上の変化があったとき再び実行します。
83 3 健二 酒井
             /MOT:m :: コピー元を監視します。m分後、変更があれば再び実行します。
84 2 健二 酒井
85 2 健二 酒井
      /RH:hhmm-hhmm :: Run Hours - times when new copies may be started.
86 2 健二 酒井
                /PF :: check run hours on a Per File (not per pass) basis.
87 1 健二 酒井
88 3 健二 酒井
             /IPG:n :: パケット間遅延(ms)、回線を絞るため、あるいは低速回線のためにあります。
89 1 健二 酒井
90 1 健二 酒井
                /SL :: copy symbolic links versus the target.
91 1 健二 酒井
92 3 健二 酒井
            /MT[:n] :: マルチスレッドを使用します。nスレッドでコピーします。(初期値 8).
93 3 健二 酒井
                       nは1以上128以下でなければなりません。
94 3 健二 酒井
                       このオプションは/IPGや/EFSRAWを両立しません。
95 3 健二 酒井
                       パフォーマンスを向上させるために、/LOGオプションを使用し出力をリダイレクトしてください。
96 1 健二 酒井
97 3 健二 酒井
 /DCOPY:copyflag[s] :: ディレクトリに対して何をコピーするか指定します(初期値は/DCOPY:DA).
98 3 健二 酒井
                       (コピーフラグ : D=データ, A=属性, T=タイムスタンプ).
99 1 健二 酒井
100 3 健二 酒井
           /NODCOPY :: ディレクトリ情報をコピーしません。 (初期値は/DCOPY:DA).
101 1 健二 酒井
102 3 健二 酒井
         /NOOFFLOAD :: Windowsコピーオフロード機構を使用せずにファイルをコピーします。
103 3 健二 酒井
104 3 健二 酒井
::
105 4 健二 酒井
:: ファイル選択オプション :
106 3 健二 酒井
::
107 4 健二 酒井
                 /A :: アーカイブ属性が設定されているファイルのみコピーします。
108 4 健二 酒井
                 /M :: アーカイブ属性が設定されているファイルのみコピーします。アーカイブ属性はリセットされます。
109 4 健二 酒井
    /IA:[RASHCNETO] :: 指定された属性が設定されているファイルだけ含めます。
110 4 健二 酒井
    /XA:[RASHCNETO] :: 指定された属性が設定されているファイルを除外します。
111 3 健二 酒井
112 4 健二 酒井
 /XF file [file]... :: 名前/パス/ワイルドカードに一致したファイルを除外します。
113 4 健二 酒井
 /XD dirs [dirs]... :: 名前/パス/ワイルドカードに一致したディレクトリを除外します
114 3 健二 酒井
115 4 健二 酒井
                /XC :: Changedファイルを除外します。eXclude Changed files.
116 4 健二 酒井
                /XN :: Newerファイルを除外します。
117 4 健二 酒井
                /XO :: Olderファイルを除外します。
118 4 健二 酒井
                /XX :: Extraファイル、ディレクトリを除外します。
119 4 健二 酒井
                /XL :: Lonelyファイル・ディレクトリを除外します。
120 4 健二 酒井
                /IS :: Sameファイルを含めます。
121 4 健二 酒井
                /IT :: Tweakedファイルを含めます。
122 3 健二 酒井
123 4 健二 酒井
             /MAX:n :: 最大ファイルサイズ - nバイトより大きいファイルを除外します。
124 4 健二 酒井
             /MIN:n :: 最小ファイルサイズ - nバイトより小さいファイルを除外します。
125 3 健二 酒井
126 3 健二 酒井
          /MAXAGE:n :: MAXimum file AGE - exclude files older than n days/date.
127 3 健二 酒井
          /MINAGE:n :: MINimum file AGE - exclude files newer than n days/date.
128 3 健二 酒井
          /MAXLAD:n :: MAXimum Last Access Date - exclude files unused since n.
129 3 健二 酒井
          /MINLAD:n :: MINimum Last Access Date - exclude files used since n.
130 3 健二 酒井
                       (If n < 1900 then n = n days, else n = YYYYMMDD date).
131 3 健二 酒井
132 4 健二 酒井
                /XJ :: ジャンクションとシンボリックリンクを除外します。(初期値では含まれています).
133 3 健二 酒井
134 3 健二 酒井
               /FFT :: assume FAT File Times (2-second granularity).
135 3 健二 酒井
               /DST :: compensate for one-hour DST time differences.
136 3 健二 酒井
137 4 健二 酒井
               /XJD :: ディレクトリに対するジャンクションとシンボリックリンクを除外します。
138 4 健二 酒井
               /XJF :: ファイルに対するシンボリックリンクを除外します。
139 3 健二 酒井
140 3 健二 酒井
141 3 健二 酒井
::
142 4 健二 酒井
:: リトライオプション :
143 3 健二 酒井
::
144 3 健二 酒井
               /R:n :: コピー失敗時のリトライ回数です。初期値100万回です。number of Retries on failed copies: default 1 million.
145 3 健二 酒井
               /W:n :: リトライ待機時間です。初期値は30秒です。
146 3 健二 酒井
147 3 健二 酒井
               /REG :: 初期値として/R:nと/W:nをレジストリに保存する
148 3 健二 酒井
149 3 健二 酒井
               /TBD :: wait for sharenames To Be Defined (retry error 67).
150 1 健二 酒井
```
151 2 健二 酒井
152 2 健二 酒井
### メモ
153 2 健二 酒井
154 2 健二 酒井
* 再開モード  
155 2 健二 酒井
ちょっとずつ、部分的にファイルをコピーしていくらしい。途中で失敗したら途中から再開するらしい。
156 2 健二 酒井
大きなファイルとかコピーするときに使うといいってさ。  
157 2 健二 酒井
https://stackoverflow.com/questions/20982968/what-is-robocopys-restartable-option
158 1 健二 酒井
159 1 健二 酒井
160 1 健二 酒井
## 元の文
161 1 健二 酒井
162 1 健二 酒井
### その1
163 1 健二 酒井
164 1 健二 酒井
```
165 1 健二 酒井
robocopy /help
166 1 健二 酒井
167 1 健二 酒井
-------------------------------------------------------------------------------
168 1 健二 酒井
   ROBOCOPY     ::     Robust File Copy for Windows
169 1 健二 酒井
-------------------------------------------------------------------------------
170 1 健二 酒井
171 1 健二 酒井
  Started : 2019年4月21日 21:49:46
172 1 健二 酒井
   Source -
173 1 健二 酒井
     Dest -
174 1 健二 酒井
175 1 健二 酒井
    Files :
176 1 健二 酒井
  Options : /DCOPY:DA /COPY:DAT /R:1000000 /W:30
177 1 健二 酒井
178 1 健二 酒井
------------------------------------------------------------------------------
179 1 健二 酒井
180 1 健二 酒井
ERROR : Invalid Parameter #1 : "/help"
181 1 健二 酒井
182 1 健二 酒井
       Simple Usage :: ROBOCOPY source destination /MIR
183 1 健二 酒井
184 1 健二 酒井
             source :: Source Directory (drive:\path or \\server\share\path).
185 1 健二 酒井
        destination :: Destination Dir  (drive:\path or \\server\share\path).
186 1 健二 酒井
               /MIR :: Mirror a complete directory tree.
187 1 健二 酒井
188 1 健二 酒井
    For more usage information run ROBOCOPY /?
189 1 健二 酒井
190 1 健二 酒井
191 1 健二 酒井
****  /MIR can DELETE files as well as copy them !
192 1 健二 酒井
```
193 1 健二 酒井
194 1 健二 酒井
### その2
195 1 健二 酒井
196 1 健二 酒井
```
197 1 健二 酒井
robocopy /?
198 1 健二 酒井
199 1 健二 酒井
-------------------------------------------------------------------------------
200 1 健二 酒井
   ROBOCOPY     ::     Robust File Copy for Windows
201 1 健二 酒井
-------------------------------------------------------------------------------
202 1 健二 酒井
203 1 健二 酒井
  Started : 2019年4月21日 21:50:27
204 1 健二 酒井
              Usage :: ROBOCOPY source destination [file [file]...] [options]
205 1 健二 酒井
206 1 健二 酒井
             source :: Source Directory (drive:\path or \\server\share\path).
207 1 健二 酒井
        destination :: Destination Dir  (drive:\path or \\server\share\path).
208 1 健二 酒井
               file :: File(s) to copy  (names/wildcards: default is "*.*").
209 1 健二 酒井
210 1 健二 酒井
::
211 1 健二 酒井
:: Copy options :
212 1 健二 酒井
::
213 1 健二 酒井
                 /S :: copy Subdirectories, but not empty ones.
214 1 健二 酒井
                 /E :: copy subdirectories, including Empty ones.
215 1 健二 酒井
             /LEV:n :: only copy the top n LEVels of the source directory tree.
216 1 健二 酒井
217 1 健二 酒井
                 /Z :: copy files in restartable mode.
218 1 健二 酒井
                 /B :: copy files in Backup mode.
219 1 健二 酒井
                /ZB :: use restartable mode; if access denied use Backup mode.
220 1 健二 酒井
                 /J :: copy using unbuffered I/O (recommended for large files).
221 1 健二 酒井
            /EFSRAW :: copy all encrypted files in EFS RAW mode.
222 1 健二 酒井
223 1 健二 酒井
  /COPY:copyflag[s] :: what to COPY for files (default is /COPY:DAT).
224 1 健二 酒井
                       (copyflags : D=Data, A=Attributes, T=Timestamps).
225 1 健二 酒井
                       (S=Security=NTFS ACLs, O=Owner info, U=aUditing info).
226 1 健二 酒井
227 1 健二 酒井
228 1 健二 酒井
               /SEC :: copy files with SECurity (equivalent to /COPY:DATS).
229 1 健二 酒井
           /COPYALL :: COPY ALL file info (equivalent to /COPY:DATSOU).
230 1 健二 酒井
            /NOCOPY :: COPY NO file info (useful with /PURGE).
231 1 健二 酒井
            /SECFIX :: FIX file SECurity on all files, even skipped files.
232 1 健二 酒井
            /TIMFIX :: FIX file TIMes on all files, even skipped files.
233 1 健二 酒井
234 1 健二 酒井
             /PURGE :: delete dest files/dirs that no longer exist in source.
235 1 健二 酒井
               /MIR :: MIRror a directory tree (equivalent to /E plus /PURGE).
236 1 健二 酒井
237 1 健二 酒井
               /MOV :: MOVe files (delete from source after copying).
238 1 健二 酒井
              /MOVE :: MOVE files AND dirs (delete from source after copying).
239 1 健二 酒井
240 1 健二 酒井
     /A+:[RASHCNET] :: add the given Attributes to copied files.
241 1 健二 酒井
     /A-:[RASHCNET] :: remove the given Attributes from copied files.
242 1 健二 酒井
243 1 健二 酒井
            /CREATE :: CREATE directory tree and zero-length files only.
244 1 健二 酒井
               /FAT :: create destination files using 8.3 FAT file names only.
245 1 健二 酒井
               /256 :: turn off very long path (> 256 characters) support.
246 1 健二 酒井
247 1 健二 酒井
             /MON:n :: MONitor source; run again when more than n changes seen.
248 1 健二 酒井
             /MOT:m :: MOnitor source; run again in m minutes Time, if changed.
249 1 健二 酒井
250 1 健二 酒井
      /RH:hhmm-hhmm :: Run Hours - times when new copies may be started.
251 1 健二 酒井
                /PF :: check run hours on a Per File (not per pass) basis.
252 1 健二 酒井
253 1 健二 酒井
             /IPG:n :: Inter-Packet Gap (ms), to free bandwidth on slow lines.
254 1 健二 酒井
255 1 健二 酒井
                /SL :: copy symbolic links versus the target.
256 1 健二 酒井
257 1 健二 酒井
            /MT[:n] :: Do multi-threaded copies with n threads (default 8).
258 1 健二 酒井
                       n must be at least 1 and not greater than 128.
259 1 健二 酒井
                       This option is incompatible with the /IPG and /EFSRAW options.
260 1 健二 酒井
                       Redirect output using /LOG option for better performance.
261 1 健二 酒井
262 1 健二 酒井
 /DCOPY:copyflag[s] :: what to COPY for directories (default is /DCOPY:DA).
263 1 健二 酒井
                       (copyflags : D=Data, A=Attributes, T=Timestamps).
264 1 健二 酒井
265 1 健二 酒井
           /NODCOPY :: COPY NO directory info (by default /DCOPY:DA is done).
266 1 健二 酒井
267 1 健二 酒井
         /NOOFFLOAD :: copy files without using the Windows Copy Offload mechanism.
268 1 健二 酒井
269 1 健二 酒井
::
270 1 健二 酒井
:: File Selection Options :
271 1 健二 酒井
::
272 1 健二 酒井
                 /A :: copy only files with the Archive attribute set.
273 1 健二 酒井
                 /M :: copy only files with the Archive attribute and reset it.
274 1 健二 酒井
    /IA:[RASHCNETO] :: Include only files with any of the given Attributes set.
275 1 健二 酒井
    /XA:[RASHCNETO] :: eXclude files with any of the given Attributes set.
276 1 健二 酒井
277 1 健二 酒井
 /XF file [file]... :: eXclude Files matching given names/paths/wildcards.
278 1 健二 酒井
 /XD dirs [dirs]... :: eXclude Directories matching given names/paths.
279 1 健二 酒井
280 1 健二 酒井
                /XC :: eXclude Changed files.
281 1 健二 酒井
                /XN :: eXclude Newer files.
282 1 健二 酒井
                /XO :: eXclude Older files.
283 1 健二 酒井
                /XX :: eXclude eXtra files and directories.
284 1 健二 酒井
                /XL :: eXclude Lonely files and directories.
285 1 健二 酒井
                /IS :: Include Same files.
286 1 健二 酒井
                /IT :: Include Tweaked files.
287 1 健二 酒井
288 1 健二 酒井
             /MAX:n :: MAXimum file size - exclude files bigger than n bytes.
289 1 健二 酒井
             /MIN:n :: MINimum file size - exclude files smaller than n bytes.
290 1 健二 酒井
291 1 健二 酒井
          /MAXAGE:n :: MAXimum file AGE - exclude files older than n days/date.
292 1 健二 酒井
          /MINAGE:n :: MINimum file AGE - exclude files newer than n days/date.
293 1 健二 酒井
          /MAXLAD:n :: MAXimum Last Access Date - exclude files unused since n.
294 1 健二 酒井
          /MINLAD:n :: MINimum Last Access Date - exclude files used since n.
295 1 健二 酒井
                       (If n < 1900 then n = n days, else n = YYYYMMDD date).
296 1 健二 酒井
297 1 健二 酒井
                /XJ :: eXclude Junction points and symbolic links. (normally included by default).
298 1 健二 酒井
299 1 健二 酒井
               /FFT :: assume FAT File Times (2-second granularity).
300 1 健二 酒井
               /DST :: compensate for one-hour DST time differences.
301 1 健二 酒井
302 1 健二 酒井
               /XJD :: eXclude Junction points and symbolic links for Directories.
303 1 健二 酒井
               /XJF :: eXclude symbolic links for Files.
304 1 健二 酒井
305 1 健二 酒井
::
306 1 健二 酒井
:: Retry Options :
307 1 健二 酒井
::
308 1 健二 酒井
               /R:n :: number of Retries on failed copies: default 1 million.
309 1 健二 酒井
               /W:n :: Wait time between retries: default is 30 seconds.
310 1 健二 酒井
311 1 健二 酒井
               /REG :: Save /R:n and /W:n in the Registry as default settings.
312 1 健二 酒井
313 1 健二 酒井
               /TBD :: wait for sharenames To Be Defined (retry error 67).
314 1 健二 酒井
315 1 健二 酒井
::
316 1 健二 酒井
:: Logging Options :
317 1 健二 酒井
::
318 1 健二 酒井
                 /L :: List only - don't copy, timestamp or delete any files.
319 1 健二 酒井
                 /X :: report all eXtra files, not just those selected.
320 1 健二 酒井
                 /V :: produce Verbose output, showing skipped files.
321 1 健二 酒井
                /TS :: include source file Time Stamps in the output.
322 1 健二 酒井
                /FP :: include Full Pathname of files in the output.
323 1 健二 酒井
             /BYTES :: Print sizes as bytes.
324 1 健二 酒井
325 1 健二 酒井
                /NS :: No Size - don't log file sizes.
326 1 健二 酒井
                /NC :: No Class - don't log file classes.
327 1 健二 酒井
               /NFL :: No File List - don't log file names.
328 1 健二 酒井
               /NDL :: No Directory List - don't log directory names.
329 1 健二 酒井
330 1 健二 酒井
                /NP :: No Progress - don't display percentage copied.
331 1 健二 酒井
               /ETA :: show Estimated Time of Arrival of copied files.
332 1 健二 酒井
333 1 健二 酒井
          /LOG:file :: output status to LOG file (overwrite existing log).
334 1 健二 酒井
         /LOG+:file :: output status to LOG file (append to existing log).
335 1 健二 酒井
336 1 健二 酒井
       /UNILOG:file :: output status to LOG file as UNICODE (overwrite existing log).
337 1 健二 酒井
      /UNILOG+:file :: output status to LOG file as UNICODE (append to existing log).
338 1 健二 酒井
339 1 健二 酒井
               /TEE :: output to console window, as well as the log file.
340 1 健二 酒井
341 1 健二 酒井
               /NJH :: No Job Header.
342 1 健二 酒井
               /NJS :: No Job Summary.
343 1 健二 酒井
344 1 健二 酒井
           /UNICODE :: output status as UNICODE.
345 1 健二 酒井
346 1 健二 酒井
::
347 1 健二 酒井
:: Job Options :
348 1 健二 酒井
::
349 1 健二 酒井
       /JOB:jobname :: take parameters from the named JOB file.
350 1 健二 酒井
      /SAVE:jobname :: SAVE parameters to the named job file
351 1 健二 酒井
              /QUIT :: QUIT after processing command line (to view parameters).
352 1 健二 酒井
              /NOSD :: NO Source Directory is specified.
353 1 健二 酒井
              /NODD :: NO Destination Directory is specified.
354 1 健二 酒井
                /IF :: Include the following Files.
355 1 健二 酒井
356 1 健二 酒井
::
357 1 健二 酒井
:: Remarks :
358 1 健二 酒井
::
359 1 健二 酒井
       Using /PURGE or /MIR on the root directory of the volume formerly caused
360 1 健二 酒井
       robocopy to apply the requested operation on files inside the System
361 1 健二 酒井
       Volume Information directory as well. This is no longer the case; if
362 1 健二 酒井
       either is specified, robocopy will skip any files or directories with that
363 1 健二 酒井
       name in the top-level source and destination directories of the copy session.
364 1 健二 酒井
```