Skip to main content
Version: 3.2

Export a CZAR from Cherwell via the command line

You can produce a Cherwell Archive (.czar or .car) from an existing CSM database without using the Administrator “Export Data” window by using Ivanti’s Command-Line Configuration (CLC) tool with the /exportsystem command.

License no longer active?

You can still run this command-line export even if your Cherwell license has expired or you no longer have access to the Administrator client — the CLC tool only needs to reach the CSM database. This is a reliable way to get your data exported for migration to Cortex when the license-gated Admin windows are no longer available to you.

This page summarizes how that CLI works and how it lines up with the GUI-based CZAR export. For the authoritative parameter list and any product updates, see Ivanti’s documentation: Export System Command-Line Options and Command-Line Configuration (CLC) Options.


What you run

CLC is shipped with CSM. From a command prompt on a machine where CSM is installed, run Trebuchet.CommandLineConfigure.exe (Ivanti documents this as usually under C:\Program Files\Cherwell Service Management) and pass /exportsystem plus the arguments below. Per Ivanti, you may use / or - as the prefix on switches (for example /connection or -connection).


Required arguments

ArgumentPurpose
/connectionName of the CSM connection to use (string). This must match a connection defined for your environment—for example "[Common]Cherwell Browser" in Ivanti’s sample. Use the same connection name you would pick in the client.
/connectionuseridCSM user ID for that connection.
/connectionpasswordPassword for that user.
/filenameFull path to the output file (for example C:\Exports\mysystem.czar). The folder must already exist; the tool does not create missing parent directories.

Optional arguments

ArgumentValues / defaultPurpose
/formatczar or car (default czar)Archive format.
/modeEntireSystemAndData, EntireSystemStructureOnly, or EntireSystemAndLookupData (default EntireSystemAndData)Scope of the export. EntireSystemStructureOnly is the usual choice when you must not share business data—similar to “Export table structure only” in the GUI. EntireSystemAndLookupData aligns with exporting structure plus lookup data. EntireSystemAndData is a full system export (all data).
/flagsComma- or pipe-separated listExtra behavior. Documented values include ExcludeAttachments, GenerateLog, ExcludeBusinessProcessData, ExcludeEncryptedFields, and ExcludeEmails.

Example (structure + lookup, typical for sharing with vendors)

Adjust the connection name, credentials, and paths for your site.

"C:\Program Files\Cherwell Service Management\Trebuchet.CommandLineConfigure.exe" ^
/exportsystem ^
/connection="[Common]Cherwell Browser" ^
/connectionuserid=YourAdminUser ^
/connectionpassword=YourPassword ^
/filename=C:\Exports\system-structure-and-lookup.czar ^
/format=Czar ^
/mode=EntireSystemAndLookupData ^
/flags=GenerateLog

Example for structure only (no business or lookup table data in the archive—confirm with your security team that this meets your policy):

"C:\Program Files\Cherwell Service Management\Trebuchet.CommandLineConfigure.exe" ^
/exportsystem ^
/connection="[Common]Cherwell Browser" ^
/connectionuserid=YourAdminUser ^
/connectionpassword=YourPassword ^
/filename=C:\Exports\system-structure-only.czar ^
/format=Czar ^
/mode=EntireSystemStructureOnly
GUI equivalent

If you prefer the Administrator UI, the same kinds of exports are described under Exporting a CZAR File.


Security and operational notes

  • Passwords on the command line are visible in process listings and script history. Prefer a dedicated export account, locked-down host, or secret store patterns your organization already uses for automation.
  • Encrypted fields and attachments: Use /flags (for example ExcludeEncryptedFields, ExcludeAttachments) when you need a smaller file or must limit sensitive content—similar to options in the GUI export dialog. Ivanti’s Data Export Tool documentation discusses encrypted data and support handoffs in more detail.
  • Licensing and rights: The user you supply must have rights to perform a full export for the chosen mode. If the command fails with an authorization error, verify the account in the Admin client first.
  • Large files: CZAR files can be very large. Plan disk space on the export volume and use the same transfer practices as in Sending the File.

Troubleshooting

SymptomThings to check
Export fails immediatelyConfirm /filename directory exists and the service account or user can write there.
Cannot connectVerify /connection matches the connection name exactly (including any [Common] prefix).
Wrong scope in the fileRe-check /mode; default is EntireSystemAndData, which includes all business data.

For behavior that differs by CSM version, always defer to the Ivanti help links above.