Partager via


Cabarc Examples

Applies To: Windows Server 2003, Windows Server 2003 R2, Windows Server 2003 with SP1, Windows Server 2003 with SP2

CABArc Examples

Example 1: List Files in a Cabinet

You want to list the files in support.cab. Type the following at the command prompt:

cabarc l c:\builds\support.cab

Press Enter. You will see the following output:

Microsoft (R) Cabinet Tool - Version 5.1.2600.0
Copyright (c) Microsoft Corporation. All rights reserved..

Listing of cabinet file 'c:\builds\support.cab' (size 4091527):
   89 file(s), 4 folder(s), set ID 32099, cabinet #0

File name                      File size     Date      Time   Attrs
-----------------------------  ---------- ---------- -------- -----
   acldiag.exe                      84992 2002/05/24 07:41:56  ----
   adprop.dll                      735232 2002/05/24 07:41:42  ----
   addiag.exe                      216091 2002/05/24 04:28:48  ----
   adsiedit.dll                    330240 2002/05/24 07:41:10  ----
   adsiedit.msc                     42986 2001/10/15 17:40:54  ----
   bitsadmin.exe                    48640 2002/05/24 07:41:16  ----
   bindiff.exe                      17408 2002/05/24 08:28:54  ----
   browstat.exe                     41472 2002/05/24 07:53:38  ----

Example 2: Extract Files from Cabinet

You want to extract all of the .dll files in the support.cab file. Type the following at the command prompt:

cabarc x c:\builds\support.cab *.dll

Press Enter. The .dll files will be extracted to the current directory. The following output is displayed:

Microsoft (R) Cabinet Tool - Version 5.1.2600.0
Copyright (c) Microsoft Corporation. All rights reserved..

Extracting file(s) from cabinet 'c:\builds\support.cab':
   extracting: adprop.dll
   -- File 'adsiedit.dll' already exists; overwrite? (Yes/No/All/Quit):

Type the following to make CABArc overwrite all preexisting files without continuing to prompt:

a

The following output is displayed:

   extracting: adsiedit.dll
   extracting: clonepr.dll
   extracting: depends.dll
   extracting: iadstools.dll
   extracting: movetree.dll
   extracting: rstools.dll
   extracting: sidwkr.dll

Operation successful

Example 3: Create a New Cabinet

You want to create a new cabinet file. Type the following at the command prompt:

cabarc n test1.cab *.dll

Press Enter. The following output is displayed:

Microsoft (R) Cabinet Tool - Version 5.1.2600.0
Copyright (c) Microsoft Corporation. All rights reserved..

Creating new cabinet 'test1.cab' with compression 'MSZIP':
  -- adding adprop.dll
  -- adding adsiedit.dll
  -- adding apidll.dll
  -- adding clonepr.dll
  -- adding depends.dll
  -- adding gutils.dll
  -- adding iadstools.dll
  -- adding movetree.dll
  -- adding ntfrsapi.dll
  -- adding rstools.dll
  -- adding sidwkr.dll
  -- adding traceprt.dll

Completed successfully

The cabinet file test1.cab is created in the current directory with MSZIP compression.

See Also

Concepts

Cabarc Overview
Cabarc Remarks
Cabarc Syntax
Alphabetical List of Tools
Topchk.cmd
Rsdir Overview
Rsdiag Overview
Iologsum Overview
Health_chk Overview
Ftonline Overview
Filever Overview
Efsinfo Overview
Dmdiag Overview
Dskprobe Overview
Diruse Overview
Dfsutil Overview
Connstat Overview
Bitsadmin Overview