zac for Linux (1)

Name

zac - The command line management interface for the Micro Focus ZENworks Agent that is installed and running on Linux managed devices.

Syntax

zac command options

Description

The zac utility performs command line management functions on the ZENworks managed device, including installing and removing software bundles, applying policies, and registering and unregistering the device.

Guide to Usage

This section contains a guide to general command formatting and conventions.

Most commands have a long form and a short form:

  • Long form: add-reg-key
  • Short form: ark

When both forms are available, the command is listed as follows:

add-reg-key (ark) options

When using the command, enter only the long form or the short form:

zac add-reg-key options

zac ark options

If an option includes a space, enclose it in quotation marks:

zac ark "option 1"

Mandatory and Optional arguments

Arguments enclosed inside parentheses ( ) are mandatory and those enclosed by square brackets [ ] are optional.

Ellipsis (…)

An ellipsis indicates that a command accepts multiple entries of the last argument type. The arguments must be separated by space or commas, depending on the command. For example:

zman server-add-bundle [options] (server) (bundle) [...]

The ellipsis indicates that server-add-bundle can accept multiple bundles. In the command level help, the multiple entry argument help is given as [(bundle) (bundle) ... (bundle)] for more clarity.

Help Commands

/? or --help

Displays help for the system.

COMMAND /?

Displays the description for a specified command.

/g or --group

Displays commands of the specified group.

Authentication Satellite Server Commands

authentication server reconfigure (asr) [-t all|config|jetty|casa] [-u username] [-p password]

Reconfigures an enabled Authentication Satellite.

Examples:

To fetch the configuration files from the server:

zac asr -t config

To reconfigure the CASA signing certificate:

zac asr -t casa

To reconfigure the Jetty web server:

zac asr -t jetty -u Administrator -p password

To reconfigure the entire Satellite:

zac asr -t all -u Administrator -p password

If a username and password is required but is not provided on the command line you will be prompted.

import-authentication-cert(iac)[-pk <private-key.der>] [-c <signed-server-certificate.der>] [-ca <signing-authority-public-certificate.der>] [-ks <keystore.jks>] [-ksp <keystore-pass-phrase>] [-a <signed-cert-alias>] [-ks <signed-cert-passphrase>] [-u username] [-p password] [-rc]

Configures an Authentication Satellite device with externally signed certificates.

  • rc - Confirms reconfiguration of the Authentication Satellite Server so that the administrator is not prompted for reconfiguration.

Each Satellite must have its own individual server certificate and private key. For more information about generating external certificates, see the ZENworks Server Installation Guide.

Bundle Commands

bundle-install (bin) [options] [bundlename | GUID | Pattern]

Installs the specified bundles based on the display name that match the specified regular expression or string, or the bundle GUID. Use the bundle-list command to get a list of the available bundles and their display names.

The following regular expressions are supported:

Regular Expression

Functionality

^abc

Matches string starting with 'abc'.

[abc]

Matches string containing 'a', 'b', or 'c'.

a*c

Matches zero or more times 'a' followed by 'c', 'ac','aac','aaac',or 'c'.

Accepts the following option:

  • -N, --dryrun - Tests and displays but does not actually perform the requested action. You can perform a dry run on a bundle version only once. This option is applicable only for the Install RPM actions of the bundle.

An example to install a bundle based on the bundle name:

zac bin bundle1

bundle-launch (bln) [bundle display name] [-noSelfHeal]

Launches the specified bundle. The actions in the Launch Action set are executed.

If you try to launch a bundle that is not installed, the bundle is first installed and then launched.

Use the bundle-list command to get a list of the available bundles and their display names.

An example to launch a bundle based on the display name:

zac bln bundle1

Example to launch a bundle based on the display name and to turn self-healing off if the launch action fails (by default, selfhealing is turned on):

zac bln bundle1 -noSelfHeal

bundle-list (bl) [options]

Displays the list of bundles assigned to the device and the logged-in user.

The output of this command is displayed in columns and provide the details of every bundle assigned or available for the managed device. The Display Name, Version, and Bundle Type columns represent the bundle display name, the version number of the bundle or sandbox if the bundle is a sandbox version, and the bundle type, respectively.The Status column displays the following states:

  • Available: Displays this state if the bundle is installed.
  • Not Installed: Displays this state if the particular bundle version is not installed.
  • Downloaded: Displays this state if the contents are downloaded but the action in the Install Action set have not been executed.

This command accepts the following options:

  • -a, --all - Lists both the filtered and non-filtered bundles. Filtered bundles are chain bundles. By default, the non-filtered bundles are displayed.
  • -g, --show-guid - Displays the bundle GUID.

An example to list all the bundles:

zac bl -a

bundle-lock-add (bla) [options] [bundlename] […]

Locks the specified bundles that match the specified regular expression or string from being upgraded or removed.

The following regular expressions are supported:

Regular Expression

Functionality

^abc

Matches string starting with 'abc'.

[abc]

Matches string containing 'a', 'b', or 'c'.

a*c

Matches zero or more times 'a' followed by 'c', 'ac','aac','aaac',or 'c'.

Accepts the following options:

  • -li, --lock-install - Locks the bundle and prevents the installation of the bundle that is specified in the lock.

NOTE:Bundle locks are applicable only for Install action set.

  • -t, --type - Specify the bundle type to be locked. The available types are linux and patch. If no type is specified, the type, bundle, is selected.
bundle-lock-list (bll)

Lists the bundle locks. The bundle locks are sorted by ID number.

Example:

zac bll

bundle-lock-remove (blr) [options] [bundleindex] […]

Removes the bundle lock that you specify by its number. You can find the number for each lock by using the bundle-lock-list (bll) command.

Accepts the following options:

  • -n - Removes the specified bundle locks by name. Ensure that the name does not contain any patterns.
  • --remove-all - Removes all bundle locks.

An example to remove a bundle lock abc:

zac blr -n abc

An example to remove all bundle locks:

zac blr --remove-all

bundle-refresh (br) [bundle display name | guid]

Refreshes information about the specified bundle.

Example:

zac br bundle1

bundle-search (bse) [options] pattern

Searches for bundles that match the specified regular expression or string.

The following regular expressions are supported:

Regular Expression

Functionality

a+bc

Matches one or more times ‘a’ followed by ‘bc’.

For example, matches one or more times ‘a’ followed by ‘abc’ or ‘aabc’.

[a-z]\*

Matches the empty string and strings with names containing only alphabets.

For example, matches the empty string "", or strings with names such as acb and xyz with only alphabets.

a*bc

Matches zero or more times 'a' followed by 'bc'.

For example, matches zero or more times ‘a’ followed by ‘abc’, ‘aabc’, ‘aaabc’, or ‘bc’.

The output of this command is similar to the output of the zac bl command.

Accepts the following option:

  • -i, --installed-only - Searches only the list of installed bundles.
bundle-uninstall (bu) [bundle display name | guid]

Uninstalls the specified bundle. The actions that support the Undo action are executed while uninstalling the bundle. After the bundle uninstall is complete, the bundle state is displayed as Not Installed.

Use the bundle-list command to get a list of the installed bundles and their display names.

Example:

zac bu bundle1

bundle-verify (bv) [bundle display name]

Reinstalls the bundle and executes the Verify Action sets to ensure that no files have been removed or corrupted. Use the bundle-list command to get a list of the installed bundles and their display names.

Example:

zac bv bundle1

Certificate Commands

cert-info (ci) [ca certificate file path] [-u <username> -p <password>]

Lists public key certificate information for each known ZENworks server or adds a trusted root certificate to the device trusted store. The file can be in ASN.1 DER format or base-64 encoded delimited by ----BEGIN CERTIFICATE---- and ----END CERTIFICATE--.

Example:

To list the certificate for each known ZENworks server:

zac ci

To add a trusted root certificate to the devices trusted store:

zac ci c:\certs\mytrustcacert.der -u myuser -p mypassword

Collection Rollup Commands

collection-clients (crc)

Displays devices that have uploaded files to this Collection.

Example:

zac crc

collection-point (cp)

Shows the status and configuration of the collection role.

Example:

collection-point [wake]

wake - Wakes the modules that perform collection (Inventory, MD status, Message sender)

collection-queued (crq)

Displays collected files that have not yet been rolled up.

Example:

zac crq

collection-state (crs)

Displays the current state of the Satellite Collection role.

Example:

zac crs

collection-upload-orphans (cuo)

Finds orphaned files on the Satellite device and rolls them up to the parent collection server or deletes them if they have already been rolled up.

This command builds a list of the files in the folders under /var/opt/novell/zenworks/work/collection (except for the collectionStatsDB folder) and then tries to find the original upload information for each entry in the collection stats database.

If there is an entry for a file in the database, and it shows that the file has not been rolled up, it rolls the file up. If the entry shows that the file has already been rolled up, it deletes the file on the Satellite device. If there is no entry for a file in the database, the file is rolled up. This command also lists any files that were not uploaded or deleted.

Before running this command, you should run the zac crw command to send any pending files to the parent server.

Example:

zac cuo

collection-wake (crw)

Sends collected files to the parent server.

Example:

zac crw

Content Distribution Commands

cdp-checksum (cchk) [-l:<path to log>]

Validates satellite content by computing the checksum on each file.

The optional log file details results of the checksum comparison.

Example:

zac cchk -l:"/var/opt/novell/zenworks/logs/cchk.log"

cdp-verify-content (cvc) [-c] [-l:<path to log>]

Compares the list of content IDs and their sync states on this CDP with what the Primary Servers thinks it should have.

You can use the following options:

  • c - Computes the checksum on the local content.

Example:

zac cvc -l:"/var/opt/novell/zenworks/logs/cvc.log"

cdp-import-content (cic) <content path> [<path to log>]

Imports missing content from the directory specified by content-path, logging to the file specified by log-path.

Example:

zac cic /usr/content_Dir /var/opt/novell/zenworks/logs/cic.log

distribution-info (cdi) [option]

Displays statistical information about the Content role. You can use the following options:

  • all - Executes all options marked with *.
  • ss - Shows sync status *.
  • rs - Gets the Content Repository size *.
  • da - Lists devices that have retrieved data from this device *.
  • ne - Gets the number of content distribution errors *.
  • ds - Gets the size of data served by this device *.
  • fs - Gets the number of files served *.
  • ah [n] - Displays n (default all) entries from the access history.
  • ch - Clears the history.
  • eh <file> - Exports the access history to <file>, where the path is included and the file itself must not exist.

Examples:

zac cdi

zac cdi rs

distribution-state (cds)

Displays the state of the Satellite Content role. Displays if the role is enabled/disabled, the status (Starting, Active, Stopping, Stopped), the Parent URLs, and the replication schedule.

Example:

zac cds

distribution-wake (cdp) [replicate | cleanup]

Wakes the Content Distribution Point worker thread. You can use either of the following options:

  • replicate - Downloads any new or changed content from the Content Distribution Point’s parent ZENworks Server.
  • cleanup - Removes any content that should no longer be stored on the Content Distribution Point.

Examples:

zac cdp

zac cdp replicate

Core Commands

get-settings (gs) <key>

Lists the effective settings associated with the specified registration key.

Example:

zac gs key1

Example to list the Remote Management settings:

zac gs RemoteManagement

All the valid ZENworks settings keys are stored in the /var/opt/novell/zenworks/zmd/cache/settings/ directory.

get-pref (get) <preference name>

Displays the preferences that are currently set.

Example to display all preferences that are set:

zac get-pref

Example to display all preferences that have names beginning with abc:

zac get-pref abc

set-pref (set) <preference name> <preference value>

Sets the value for a preference.

Example to set the value of preference abc to 123:

zac set-pref abc 123

NOTE:If you want to configure a proxy server for a managed device, ensure that the managed device has both the proxy-host and proxy-port preferences configured. If the proxy server requires authentication, the managed device must additionally have the proxy-username and proxy-password preferences configured.

set-proxy (sp) [options] <IP address/Hostname:port> [username] [password]

Specifies a proxy to contact rather than contacting a ZENworks Server directly.

The options are:

  • /default - Sets a proxy that can be overriden by proxy settings from the Management Zone.
  • /clear - Clears the current proxy, but will use proxy settings from the Management Zone.

Examples:

IPv4:

zac sp 123.456.78.90:2349 administrator novell

zac sp /default 123.456.78.90:2349

zac sp /clear

If a username and password is not specified, then you will be prompted to enter them.

System Update Commands

zac zeus-refresh / zeus-ref

Retrieves the system update when it is assigned to a device.

External Service Commands

These commands are used to manage external services.

external-service-add (esa) --type (type) (url) (Service Name) [Properties]

Adds external package repositories like YUM, ZYPP, or the Local directory that contains the RPMs. All the type-specific properties should start with -D.

You can list the service types that you can add by using the zac est command.

It supports the following types:

  • YUM: Adds repository of type YUM. Accepts the following properties:

    • -Dusername=value -Dpassword=value - This property is optional and is used while adding an authenticated YUM repository.
    • -DsyncExternal=true - This property is optional and is used to synchronize with the Local Package Management tool.

    For example, run the following command to add a YUM service type:

    zac esa --type YUM -Dusername=username -Dpassword=passwd https://nu.novell.com/sles11 sles11-yum-repo

  • ZYPP: Adds repository of type ZYPP. Accepts the following properties:

    • -DsyncExternal=true - This property is optional and is used to synchronize with the Local Package Management tool.

    For example, run the following command to add a ZYPP service type:

    zac esa --type ZYPP http://zypp.source.com/sles11/x86_64 sles11-zypp-repo

  • Mount: Adds a repository of type Mount. A Mount type adds a service from the Local directory that contains the RPMs. Accepts the following properties:

    • -Drecursive=(Value) - This property is optional. The valid values are true or false. If true, the RPMs are added recursively from all the directories under the specified absolute path.
    • -DsyncExternal=true - This property is optional and is used to synchronize with the Local Package Management tool.

    For example, run the following command to add packages recursively from all directories by using the Mount service type:

    zac esa --type mount -Drecursive=true file:///mnt/sles11-cd/i586 sles11-rpms

NOTE:The ZYPP or Mount services do not synchronize with the YUM Package Management Tool on Red Hat devices.

external-service-delete (esd) (index | name | url | --all)

Removes the specified external services.

The --all option deletes all the external services.

external-service-list (esl)

Lists all the external services.

The Source column displays the ZENworks Agents that were added by using the zac command and displays the ZENworks Server that was added through an External Service Policy.

The Status column displays whether the external service is active or inactive. You cannot refresh the external services that display their status as Inactive.

The State column displays whether the external service is enabled or disabled.

external-service-refresh (esr) (index | name | url | --all)

Refreshes the specified external services.

The --all option refreshes all the services.

external-service-state (ess) (enable | disable) (index | name | url | --all)

Enables or disables the specified external services.

The --all option changes the service state of all the services.

external-service-types (est)

Lists the available service types.

Imaging Commands

file-system-guid (fsg) [-d] [-r]

Removes and restores the workstation GUID in the file system in preparation for taking an image.

Example to remove the GUID from the file system:

zac file-system-guid -d

Example to restore the GUID to the file system:

zac file-system-guid -r

Example to print the GUID value:

zac fsg

Inventory Commands

inventory (inv) [scannow | cdf]

Runs an inventory scan or opens the Collection Data Form.

Example to run an inventory scan:

zac inv scannow

Example to open the Collection Data Form:

zac inv cdf

Inventory-Only Commands

These commands are used only for Inventory-Only (IOA) agents.

zac ioa cfg <server ip>

Configures the Linux IOA device to the mentioned server ip.

Example to run an Inventory-Only scan:

zac ioa cfg 10.70.13.124

zac ioa version

Displays the version of the Inventory-Only (IOA) agent.

inventory (inv) [scannow]

Runs an inventory scan.

An example to run an inventory scan:

zac inv scannow

Local User Management Commands

These commands are used to manage local users and their privileges.

user-add (ua) (username)

Adds a local user to the ZENworks privilege store.

Example:

zac ua username

user-delete (ud) (username)

Deletes a local user from the ZENworks privilege store.

Example:

zac ud username

user-list (ul)

Lists the following:

  • - User names and privileges for the local users added to the ZENworks privilege store.
  • - Privileges for the local users not added to the ZENworks privilege store (default user). The default user is represented by * (asterisk).

Example:

zac ul

user-edit (ue) (username) [+/-Privilege]

Edits the local user privileges. You use + (plus) to add a new privilege and - (minus) to remove an existing privilege.

By default, a newly created local user has the View privilege. The local users that are not added to the ZENworks privilege store inherit the privilege assigned to the default user that is represented by * (asterisk). You can change the privileges assigned to any local user and assign the user the following privileges:

Privilege

Functionality

View

View or list the information on bundles, policies, configuration, and so on.

Install

Install or uninstall bundles, policies, packages, and so on.

Configure

Run the configuration commands.

SuperUser

Execute all the zac commands because a SuperUser is assigned all the privileges. By default, the root user is assigned the SuperUser privilege, which cannot be modified.

Examples:

If you want to allow the local users in the ZENworks privilege store to view, install, and uninstall bundles and policies, you can assign the View and Install privileges to these users by running the following command:

zac ue username +Install

If you want to allow the local users that are not added to the ZENworks privilege store to view, install, and uninstall bundles and policies, you can assign the View and Install privileges to to the * user by running the following command:

zac ue '*' +Install

user-privilege-export (upe) (.xml filename)

Exports a list of local users and their privileges to a specified .xml file for reusing this list on other managed devices.

Example:

zac upe /tmp/privileges.xml

After exporting the list, you can import it to other managed devices by running the user-privilege-import (upi) command.

user-privilege-import (upi) (.xml filename)

Imports a list of local users and their privileges to other managed devices from a specified .xml file. This list can be exported to the .xml file by running the user-privilege-export (upe) command.

Example:

zac upi /tmp/privileges.xml

Location Commands

config-location (cl)

Displays the configuration location. The configuration location determines which ZENworks server (or servers) the device connects to for authentication, configuration, content, and collection purposes.

Examples:

zac config-location

zac cl

Logging Commands

logger [resetlog | level [MANAGED|ERROR|WARN|INFO|DEBUG] | managedlevel]

Changes the logger configuration.

You can use the following options:

  • resetlog - Resets the log.
  • level - If used without a level, displays the current managed logging level. If used with one of the levels, changes the logging level to the specified level.
  • managedlevel - Displays the Global Log level of the zone.

Example to reset the log file:

zac logger resetlog

Example to show the current log level:

zac logger level

Example to set the log level to DEBUG and above:

zac logger level DEBUG

Package Management Commands

checkpoint-add (cpa) (name) [date]

Adds a checkpoint. If the date is not specified, adds a check point with the current date.

checkpoints-list

Lists the saved checkpoints.

checkpoint-remove (cpr) (name) […]

Removes the specified checkpoints.

dist-upgrade (dup) [options] [bundle name|service name] […]

Performs a distribution upgrade. This command performs an update of all packages with a special resolver algorithm which takes care of package architecture change, package splits, pattern and product updates, etc. If no arguments are provided, packages from all ZENworks bundles and external services are considered for distribution upgrade.

Accepts the following options:

  • -d, --download-only - Only downloads packages.
  • -N, --dry-run - Tests and displays the requested actions but does not actually perform them.
  • -y, --no-confirm - Does not prompt for confirmation.

For example, you can upgrade the distribution from SLES 10 SP2 to SLES 10 SP3.

info (info) [option] pattern

Displays package information for the specified package that matches the specified pattern.

The following regular expressions are supported:

Regular Expression

Functionality

^abc

Matches string starting with 'abc'.

[abc]

Matches string containing 'a', 'b', or 'c'.

a*c

Matches zero or more times 'a' followed by 'c', 'ac','aac','aaac',or 'c'.

The command displays the Name, Version, Architecture, and Description of the packages.

Accepts the following options:

  • --provides - Lists packages and files that is provided by the package that matches the specified pattern.
  • --requires - Lists packages and files that is required by the package that matches the specified pattern.
install (in) [options] (package name) […]

Installs the specified packages. If you specify a package with a version, the exact version of the package is installed. If you specify a package with a name, the best version of the package is installed.

NOTE:If you want to downgrade a package, specify the version to which you want to downgrade the package.

Accepts the following options:

  • -b, --bundle [bundle name] - Installs a package from the specified bundle. The bundle that you specify can also be a Linux Dependency Bundle. However, to install a Linux Dependency Bundle, the Publish Packages should be set to True.
  • -d, --download-only - Downloads packages to the zen cache directory. By default, the zen cache directory is located in /var/opt/novell/zenworks/zmd/cache.
  • -N, --dry-run - Tests and displays the requested actions but does not actually perform them.
  • -y, --no-confirm - Does not prompt for confirmation.
  • -f, --freshen - Installs packages only if an earlier version of the package exists.
  • -s, --service [service name] - Installs a package from the specified service.
  • -p, --pattern [pattern name] - Installs a package of a specified pattern. However, only the mandatory packages part of the pattern is installed.
  • --entire-bundle [bundle name] […] - Installs all packages from the specified bundles. You can specify a single bundle or multiple bundles.
  • --ignore-dependency - Does not check for dependency. The dependant packages are skipped and only the packages are installed.
  • -r, --regex-pattern <regex pattern> [<regex pattern>]- Installs all the packages that match the specified regular expression.

The following regular expressions are supported:

Regular Expression

Functionality

^abc

Matches string starting with 'abc'.

[abc]

Matches string containing 'a', 'b', or 'c'.

a*c

Matches zero or more times 'a' followed by 'c', 'ac','aac','aaac',or 'c'.

Additionally, the command also lists the dependent packages to successfully complete the installation.

list-updates (lu) [options] [bundle name|service name] […]

Displays available updates in the specified bundles and services. You can specify a single bundle or service, or multiple bundles or services for which you want to display the updates. If no bundle or service is specified, the command displays all the available updates.

Accepts the following option:

  • -t, --type [type] - Lists updates from the specified service type.
lock-add (la) (name or pattern)[version]

Adds a package lock rule. This command locks the specified packages, which if match the specified regular expression or string, are not upgraded or removed. The package name can be specified individually, with wildcard patterns, or even with version number relations. The version number should be specified within single or double quotes.

Relational Operator

Functionality

=

Locks only the specific package version.

<

Locks all versions of the package older than the specified version, excluding the specified version.

>

Locks all versions of the package later than the specified version, excluding the specified version.

<=

Locks all versions of the package older than the specified version, as well as the specified version.

>=

Locks all versions of the package later than the specified version, as well as the specified version.

If you want to install a specific version of the package, this command first checks if the package version has been locked, then installs the package version only if it is not locked. For example, assume that all the later versions of the package “X 1.7” have been locked by using the zac la X '>' 1.7 command. If you try to install the X 1.9 package by using the zac in X (1.9) command, the installation fails.

lock-delete (ld) (lock number) […]

Deletes the package lock that you specify by its number. You can find the number for each lock with the lock-list (ll) command.

lock-list (ll)

Lists the package locks.

packagehistory (ph) [options] […]

Lists package transaction history that is performed by using ZENworks. This command displays the package name, date, operation, version, and release.

Accepts the following option flags:

  • -n, --search-name [package name] - Searches by package name
  • -a, --search-action [action name] - Searches by action name. The valid action names are None, Install, Removal, and Upgrade.
  • -d, --days-back [days] - Maximum number of days to look back (default 30).
  • -c, --clean-history - Cleans package history.
  • -o, --search-operation [operation] - Searches based on the operation performed. The operation performed can be Install, Removal, or Upgrade.
remove (rm) [options] (package name) […]

Removes the specified packages.

Accepts the following options:

  • --entire-bundle [bundle name] - Removes all the packages from the specified bundle.
  • -N, --dry-run - Tests and displays but does not actually perform the requested actions.
  • -y, --no-confirm - Does not prompt for confirmation.
  • -r, --regex-pattern <regex pattern> [<regex pattern>] - Removes all the packages matching the specified regular expression.

The following regular expressions are supported:

Regular Expression

Functionality

^abc

Matches string starting with 'abc'.

[abc]

Matches string containing 'a', 'b', or 'c'.

a*c

Matches zero or more times 'a' followed by 'c', 'ac','aac','aaac',or 'c'.

Additionally, this command also lists the dependent packages to successfully complete the removal of the specified package.

rollback (ro) [options] [date or check point]

Rolls back package transactions to the time and date you specify, if the rollback preference is set. By default, the rollback preference is disabled. You can enable the rollback preference by running the zac set rollback true command.

If you want to roll back to a particular version of the package, that version of the package and its dependencies should be available as part of the service or the assigned bundle. If the version of the package or its dependencies is not available, the rollback fails.

Additionally, this command also lists the dependent packages that are required to successfully roll back.

Accepts the following options:

  • -d, --download-only - Only downloads packages.
  • -N, --dry-run - Tests and displays but does not actually perform the requested actions.
  • -y, --no-confirm - Does not prompt for confirmation.
  • -p, --package (package name) - Name of the package that needs to be rolled back.
search (se) [options] [pattern]

Searches for packages that match the specified pattern. If no arguments are provided, it displays all the packages. This command displays the source name, source type, package name, version, and architecture.

Accepts the following options:

  • -b, --bundle [bundle name] - Searches packages in the specified bundle.
  • -d, --search-in-description - Searches in package descriptions but not package names.
  • -i, --installed-only - Shows only installed packages.
  • -u, --uninstalled-only - Shows only uninstalled packages.
  • -s, --service [service name] - Searches packages in the specified service.
  • -t, --type [service type] - Searches packages, based on the specified service type.
  • -p, --pattern [pattern name] - Shows the available patterns.
  • --sort-by-bundle - Sort packages by bundle, not by name. Default sorting is by package name.
  • --show-nevra - Shows the NEVRA details of the packages.
update (up) [options] [bundle name|service name] […]

Updates the installed packages. You can specify a single bundle or service name, or multiple bundles or service names, for which to update the packages. If no bundle or service name is specified, all the packages are updated.

If there are installed packages that have the same name and architecture but different versions, only packages with the higher version are upgraded.

Accepts the following options:

  • -d, --download-only - Only downloads packages.
  • -N, --dry-run - Tests and displays but does not actually perform the requested actions.
  • -y, ---no-confirm - Does not prompt for confirmation.
  • -t, --type [service-type] - Updates packages from the specified external service type.
what-provides (wp) pattern

Displays packages that provide the library, program, or package that matches the specified pattern. Only the * wildcard pattern is supported.

Example to display the packages ending with a:

zac wp *a

what-requires (wr) pattern

Lists packages that require the library, program, or package that matches the specified pattern.

An example to display packages starting with a:

zac wr a*

Patch Management Commands

patch-scan (ps)

Scans the device for patches that are not applied, using the device's current patch signature (DAU) file. The results are then uploaded to the server.

An example to run a patch scan:

zac ps

patch-scan --quick (ps --quick)

Uploads the last scan results to the server; it does not run a new detection scan.

An example to run a quick patch scan:

zac ps --quick

patch-apply-policy (pap)

Updates devices with the latest version of all patch policies.

An example to run a patch apply policy:

zac pap

patch-quarantine-release (pqr)

Releases any quarantined patches on the device where the command is run from quarantine so that a one-time installation attempt can occur, either from a patch policy schedule or a remediation schedule.

An example to run a patch quarantine release:

zac pqr

Policy Commands

policy-list (pl)

Lists the policies that are currently being enforced on the device (effective policies). To list all policies (effective and non-effective), use the --all option.

Examples:

zac pl

zac pl --all

policy-refresh (pr)

Applies all of the policies assigned to the device and user.

Example:

zac pr

Registration Commands

add-reg-key (ark) <registration key>

Registers the device by using the specified key. Registration with keys is additive. If the device has previously been registered with a key and you register it with a new key, the device receives all group assignments associated with both keys.

Example:

zac ark key12

register (reg) [-k <key>] [-u <username> -p <password] <ZENworks Server address:port>

Registers the device in a Management Zone. To execute this command you must have Create/Delete device rights for the folder on which the device you are attempting to register.

Examples:

zac reg -k key1 https://123.456.78.90

zac reg -k key1 -u administrator -p novell https://zenserver.novell.com:8080

The port number is required only if the ZENworks Server is not using the standard HTTP port (80). If a username and password are not supplied, you are prompted for them.

NOTE:The -k option will not be honored if the corresponding device object is already present on the server and reconciliation takes place with that device object.

reregister (rereg)[-u <username> -p <password>] <new guid>

Registers a device in the current zone and assigns it the GUID of an existing device object. The currently associated device object is deleted. To execute this command you must have Create/Delete device rights for the folder on which the device you are attempting to reregister.

For example, if you image a device after replacing the hard drive, the device might get a new GUID. However, by using the reregister command, you can assign the same GUID that it had before you replaced the hard drive.

Examples:

To reregister, specify a username and password:

zac reregister -u myuser -p mypassword eaa6a76814d650439c648d597280d5d4

To reregister and be prompted for a username and password:

zac reregister eaa6a76814d650439c648d597280d5d4

unregister (unr) [-f] [-s] [-a] [-u <username> -p <password>]

Removes the device’s registration from the Management Zone. To execute this command you must have Create/Delete device rights for the folder on which the device you are attempting to unregister.

Example:

To force a device to unregister locally when a server cannot be contacted:

zac unr -f -u myuser -p mypassword

To unregister locally and suppress prompting for a user name and password:

zac unr -s

Use -a option to unregister asynchronously. With this option server deletes the device asynchronously.

The -a, -f, -u, and -p parameters are optional. If you don’t use the -u and -p parameters, you are prompted to enter a username and password. The -f parameter ignores the ZENworks database and forces the device to be unregistered locally; this option is necessary only if the device object has already been deleted from the ZENworks database or if the device cannot connect to the database. If -a option is specified, ZENworks server returns the unregister call quickly, but deletes the device object asynchronously from the database at a later point of time. If your device deletion is not complete and tries to register the device again, then ZENworks server displays an error. If there is large amount of data associated with the device in the database, it might take long time to delete the device. Ensure that -a option is used when actual device deletion on server takes long time and causes the agent unregister command to timeout.

NOTE:Running UNR command might cause high utilization of the database. This might be due to any of the following reasons:

  • The UNR command is running on the server.

  • The zone contains large number of managed devices.

  • The managed devices have a huge history.

  • The Patch Management is enabled.

reestablish-trust (retr) [-u <username> -p <password>]

Reestablishes trust with the current Management Zone. The username and password used must be of the Zone Administrator.

Example:

zac retr -u myuser -p mypassword

The -u and -p parameters are optional. If you don’t use the -u and -p parameters, you are prompted to enter a username and password.

Satellite Role Commands

remint-satellite-cert (rsc)

Remints the SSL certificate for Satellite.

Example: zac rsc

satellite-cachecfg (satcfg)

Reads Satellite roles from cache.

Example:

zac satcfg

satellite-clearcache (satcc)

Clears Satellite configuration information from cache.

Example:

zac satcc

satellite-refreshcfg (satrc)

Refreshes Satellite roles.

Example:

zac satrc

satellite-roles (satr)

Reports on current Satellite roles and their state.

Example:

zac satr

imgsatserver status (iss status)

Displays the device’s imaging role properties, including its current status, PXE service status, image files, and imaging statistics.

Current Status: Displays whether your device is currently configured to perform Imaging operations. The current status is Active when the device is promoted to a satellite with the Imaging role.

PXE Service Status: Displays whether the Proxy DHCP service is enabled on the device.

PXE Requests: The number of imaging requests of any kind that have been received by the Imaging Server since it was last started. This includes requests that failed, were denied, or were referred to other Imaging Servers. Information about each of these requests, such as the source, type, date/time, and results, is logged on the Imaging Server.

Images Sent: The number of images that the Imaging Server has sent to imaging clients since the Imaging Server was last started. This includes only images that were retrieved from this Imaging Server.

Images Received: The number of new images that have been received and stored on the Imaging Server since it was last started. This includes images that were received through client referrals.

Example:

zac iss status

Status Commands

agent-properties (agp)

Provides information about the ZENworks Agent. The following fields provide information about the ZENworks Agent:

Device Address. The IP address of your device.

Device Name. The computer name for your device.

Device State. The state of the device - Managed, Unmanaged, Retired, or Unknown. The Unknown state is displayed only if there is an error.

Last Contact With Server. The last time the ZENworks Agent contacted the ZENworks Server.

Next Contact With Server. The time scheduled for the ZENworks Agent to contact the ZENworks Server.

Primary User. The currently logged in user.

Example:

zac agp

zac agent-properties

cache-clear (cc)

Clears the ZENworks cache on the device. This removes all entries in the cache database and deletes any cache files associated with those entries.

Example:

zac cc

refresh (ref)[general [bypasscache] | partial [bypasscache] | bypasscache]

Initiates a general refresh to refresh all registration and configuration settings; or initiates a partial refresh to refresh all registration and configuration settings.

Use bypasscache to avoid using data from the server cache during the refresh. This option is useful for testing or troubleshooting.

Examples:

zac ref general bypasscache

zac ref partial bypasscache

zac ref bypasscache

zenhttp-status(zhs)

Lists port and tags for registered handlers.

Example:

zac zhs

zone-config (zc)

Displays information about the ZENworks Server that the device is accessing for configuration information (the Configuration server) or lists the information for the Configuration server.

Examples:

zac zc

get-settings (gs) <key>

Lists the settings associated with the specified key.

Example:

zac gs key1

All valid ZENworks settings keys are stored in the /var/opt/novell/zenworks/cache/zmd/settings directory.

Example to list the Remote Management settings:

zac gs RemoteManagement