rug (1)

Name

rug - The command line interface for the Novell ZENworks Linux Management Agent.

Syntax

Description

rug is the command-line interface to the ZENworks Linux Management agent. It works with the ZENworks Linux Management daemon to install, update, and remove software according to the commands you give it. The software that it installs can be from ZENworks 7.x Linux Management, ZENworks 6.6.x Linux Management servers, YUM repositories, the ZYPP service, as well as local files.

ZENworks Linux Management servers sort software by category into catalogs, which are groups of similar software. For example, one catalog can contain software from the operating system vendor, and another catalog can contain the SUSE Linux Enterprise Desktop. You can subscribe to individual catalogs to control -i display of available packages and prevent the accidental installation of unwanted software. By default, all operations are performed on software from within catalogs to which you are subscribed, although you may alter this with the --allow-unsubscribed flag. The rug utility also provides other features, such as rollback, locks, history and preferences to easily manage packages and bundles.

Depending on the type of managed device, the location of the rug utility varies.

For SUSE Linux Enterprise Server 10 (SLES 10) and SUSE LINUX Enterprise Desktop 10 (SLED 10) devices, the rug utility is located in the following directory:

/usr/bin

On all other managed devices, the rug utility is installed in the following location:

/opt/novell/zenworks/bin

Guide to Usage

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

Folders

If no folder is specified for commands that take a folder argument, the command targets the root folder. To specify a folder path, list each folder from the root separated by a forward slash (/). For example, if you have a folder named folder1 in the root, containing a subfolder named subfolder1, you would reference this folder as folder1/subfolder1. Each specified folder must already exist.

Ellipsis (...)

An ellipsis indicates that a command accepts multiple entries of the last argument type. For example, the ellipsis in the following command indicates that catalog-add-bundle can accept multiple bundles:

rug bundle-history [options] [search-string] [...]

Option Flags

Commands that do not have command-specific options (they accept only the standard option flags) do not have options listed as an argument in the command reference. For example, the reference entry for the following command does not list options because it accepts only the standard flags:

rug list-updates (lu) [catalog]

However, the following command lists options because the command has a command-specific option (-a):

rug bundle-history [options] [search-string] [...]

Commands

rug provides a number of commands (shown as [command] in the Syntax section). Each command accepts the option flags listed in the Global Options section. In addition, many commands have specific option flags that are listed with the commands.

The most commonly used command is rug update which downloads and installs updates in catalogs to which you are subscribed.

Bundle Management Commands

bundle-history (bhi) [options] [search-string] [...]

Searches the bundle log entries for the strings specified by [search-string]. Accepts the following option flags:

  • -n, --search-name - Searches by bundle name (default)
  • -a, --search-action - Searches by action
  • --search-user - Searches by user
  • --match-all - Requires packages to match all search strings (default)
  • --match-any - Allows packages to match any search string
  • --match-substrings - Matches search strings against any part of text
  • --match-words - Requires packages to match all search strings
  • -d, --days-back - Maximum number of days to look back (default 30)
bundle-install (bin) [options] [bundlename] [...]

Installs the specified bundles. rug attempts to find the specified bundles in catalogs to which you are subscribed. Use bundle-upgrade to upgrade a bundle that you already have installed. Accepts the following option flags:

  • --entire-catalog - Installs all of the bundles from the catalogs specified.
  • -y,--no-confirmation - Does not prompt for confirmation.
  • -p,--prepare-only - Only prepares bundles; does not install.
  • -f,--freshen - Freshens children.
  • -g,--use-guid - Refer bundles by bundle GUIDs.
  • -r, --allow-removals - Removes all conflicting packages.
  • -N,--dryrun - Tests and displays, but does not actually perform the requested actions.

NOTE:The -N and -r options is not applicable for File bundles.

bundle-list (bl) [options] [ [catalog] [catalog] [. . .] ]

Lists available bundles in catalogs to which you are subscribed.

The output for this command is presented in the following columns: Status, Catalog, Name, Version, and Type. The columns provide the details of every bundle assigned or available for the managed device. The Catalog, Name, Version, and Type represent the catalog name, bundle name, bundle version, and bundle type respectively.

The Status field is empty if the bundle is not installed, displays “i” if the bundle is installed, “v” if the bundle is installed but is of a different version compared to the one displayed in the list, and “*” if the bundle is partially installed.

By default, the command shows the display bundle name.

Accepts the following option flags:

  • -i, --installed-only - Shows only installed bundles, and their bundle lock status.
  • -u, --uninstalled-only - Shows only uninstalled bundles.
  • -c, --incomplete-only - Shows only incomplete bundles.
  • -s, --show-name - Shows the actual name of the bundle.
  • -g, --show-guid - Shows the GUIDs of the bundle.
  • -t, --type - Shows the bundles of the type you specify. Valid values are package, file, and YOU patch. You can specify the value in one of the following formats:
  • rug bl -t file
  • rug bl -t=file
  • rug bl --type file
  • rug bl --type=file
bundle-lock-add (bla) [options] [bundlename] [version] [...]

Adds a bundle lock rule. This prevents changes to the installation state of the bundle that is not specified in the lock. The bundle name can be specified individually, with wildcard patterns, or even with version number relations. For example, the command rug bla gnome* refuses to remove any bundles beginning with “gnome”. Accepts the following options:

-c, --catalog - Catalog to match in lock.

bundle-lock-delete (bld) [options] [lock-number] [...]

Deletes the bundle lock you specify by its number. You can find the numbers for each bundle lock with the lock-list (bll) command.

bundle-lock-list (bll) [options]

Lists the locks that have been put in place. Locks are sorted by ID number. The bundles that are locked by the administrator on the server are not listed.

bundle-remove (brm) [options] [bundlename] [...]

Removes the specified bundles. Accepts the following option flags:

  • -y,--no-confirmation - Does not prompt for confirmation.
  • -p,--prepare-only - Only prepare bundles, do not install.
  • -f,--freshen - Freshens children.
  • -r,--allow-removals - Removes all conflicting packages.
  • -N,--dryrun - Tests and displays, but does not actually perform the requested actions.

NOTE:The -N and -r options are not applicable for File bundles.

bundle-search (bse) [options] [querystring]

Searches for bundles matching the query string. Accepts the following option flags:

  • -i,--installed-only - Searches only the list of installed bundles.
  • -s, --show-name - Shows the actual name of the bundle.
  • -g, --show-guid - Shows the GUIDs of the bundle.
bundle-types (bt) [options]

Lists the available bundle types.

bundle-upgrade (bup) [options]

Upgrades the bundles. Accepts the following option flags:

  • -y,--no-confirmation - Does not prompt for confirmation.
  • -p,--prepare-only - Only prepares bundles, does not install.
  • -f,--freshen - Freshens children.
  • -r,--allow-removals - Removes all conflicting packages.
  • -N,--dryrun - Tests and displays, but does not actually perform the requested actions.

NOTE:The -N and -r options are not applicable for File bundles.

catalogs (ca) [options]

Lists the catalogs available for the services you have added. Accepts the following option flags:

  • -u, --uri - Show the service uri.
  • -i,--installed-only - Searches only the list of installed bundles.
  • -s, --supercede - Installs the latest version of the bundle.
  • -v, --different - Installs a differenti version of the bundle.
subscribe (sub) [options] [catalogname] [...]

Subscribes to the specified catalogs. Each specified catalog must be available from one of the services you have added. Accepts the following option flags:

  • -s,--strict - Fails if attempting to subscribe to a subscribed catalog.
  • -a,--all - Subscribes to all catalogs.
  • -e, --service - Specifies the service.
unsubscribe (unsub) [options] [catalogname] [...]

Unsubscribes the specified catalogs. Accepts the following option flags:

  • -s,--strict - Fails if attempting to unsubscribe from an unsubscribed catalog.
  • -a,--all - Unsubscribes to all catalogs.
  • -e, --service - Specifies the service.

File Management Commands

bundle-files (bf) [options] [bundle]

Shows the files in a given file bundle. Accepts the following option flag:

  • -g,--use-guid - Refer bundles by bundle GUIDs.

The Status column is empty if the file is not installed. It displays “i” if the file is installed,“c” if the file is in the compressed form, or “p” if the file is of a lower version than that installed on the device.

Package Management Commands

bundle-packages (bp) [option] [bundle]

Shows the packages in a given bundle. Accepts the following option flags:

  • --show-nevra - Shows the NEVRA details of the packages.

If the --show-nevra option is not specified, the output for this command is presented in the Status, Catalog, Name, Version, and Arch columns. These provide the details of every package that is part of the given bundle. Catalog, Name, Version, and Arch represent the catalog name, package name, package version, and package architecture respectively.

The Status column is empty if the package is not installed. It displays “i” if the package is installed, “v” if a different version of the package is installed on the device, or “s” if the package in the bundle is of a lower version than that installed on the device.

The description of these columns is the same with other package commands.

If the --show-nevra option is specified, the output for this command is presented in the Status, Catalog, Name, Epoch, Version, Release, and Arch columns.

-g,--use-guid - Refer bundles by bundle GUIDs.

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

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

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

Removes the specified checkpoints.

checkpoints (cp)

Gets a list of saved checkpoints.

dist-upgrade (dup) [options]

Performs a distribution upgrade. Accepts the following option flags:

  • -N, --dry-run - Tests and displays, but does not actually perform the requested actions..
  • -y, --no-confirm - Does not prompt for confirmation.
  • --agree-to-third-party-licences - Automatically agrees to third party licences.
dump [output filename]

Gets a dump of system information as a SQLite database.

file-list (fl) [package name]

Lists files within a package.

history (hi) [options] [search term]

Searches package history for the search term you specify. By default, searches package names for the search term, displaying the package version history. Use the following option flags to perform a different search:

  • -n, --search-name - Searches by package name (default).
  • -a, --search-action - Searches by action.
  • -d, --days-back - Maximum number of days to look back (default 30)
info (if) [options] [package name] [...]

Displays complete information for the specified package. Accepts the following option flags:

  • -i, --uninstalled - Searches for uninstalled packages.
  • -u, --unsubscribed - Searches in unsubscribed catalogs.
info-conflicts (ic) [package name]

Lists all conflicts for the specified package.

info-obsoletes (io) [package name]

Lists all obsoletes for the specified package.

info-provides (ip) [package name]

Lists the information provided by the specified package.

info-requirements (ir) [package name]

Lists package requirements. Accepts the following option flags:

  • -a, --all-providers - Lists all packages that can satisfy a requirement.
  • -v, --show-versions - Displays full version information for packages.
install (in) [options] [-t resolvableType] [-c catalog] resolvable1 [resolvable2]

Installs the specified resolvables. If a user requests a package with a version, ZMD installs the exact version of the package. If the package version is not specified, ZMD installs the best version of the package. On SLES 10 and SLED 10 platforms, the resolvableType can be a package, pattern, product, or patch; by default it is package. Accepts the following option flags:

  • -u, --allow-unsubscribed - Allows unsubscribed catalogs.
  • -d, --download-only - Only downloads packages.
  • --entire-catalog - Installs all of the packages from the catalogs specified.
  • -N, --dry-run - Tests and displays the requested actions, but does not actually perform them
  • -i, --confirm - Prompts for confirmation.
  • -y, --no-confirm - Does not prompt for confirmation.
  • --agree-to-third-party-licences - Automatically agrees to third-party licences.
list-resolvables (lr)

Lists the available resolvable types.

list-updates (lu) [catalog] [ . . . ]

Displays available updates in the specified catalogs. Adding catalogs as arguments limits the list to those catalogs you specify. If you are not subscribed to a catalog, no updates will be available, even if you name the catalog as an argument; you must subscribe to list updates.

If the output from this command does not match the pending updates listed on the server, it is because the pending updates list on the server shows updates for all available catalogs, not just catalogs to which the client is subscribed. For the lists to match, the client must be subscribed to all available catalogs.

Accept the following option flags:

-t, --type - Specify the type of updates.

lock-add (la) [options] [name or pattern] [version] [...]

Adds a package lock rule. This prevents changes to the installation state of the package that is specified in the lock. The package name can be specified individually, with wildcard patterns, or even with version number relations.

The package_name can include wildcard characters. The following table explains the valid relational operators that can be used with the package in the command:

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, ZENworks first checks if the package version has been locked, then installs the package version only if it is not locked. For example, lets assume that all the later versions of the package, “X 1.7” have been locked by using the rug la X > 1.7 command. If you try to install X 1.9 package by using the rug in X (1.9)command, the installation fails.

lock-delete (ld) [options] [lock-number] [...]

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

lock-list (ll) [options] [lock-number] [...]

Lists the package locks that have been put in place. Locks are sorted by ID number.

package-file (pf) [filename]

Gets the package which contains the specified file.

packages (pa) [options] [catalog] [...]

Displays the packages in a given catalog. If no catalog is specified, all packages in all catalogs are listed. Accepts the following option flags:

  • -i, --installed-only - Shows only installed packages.
  • -u, --uninstalled-only - Shows only uninstalled packages.
  • --sort-by-name - Sorts packages by name (default).
  • --sort-by-catalog - Sorts packages by catalog.
  • --show-nevra - Shows the NEVRA details of the packages.

If the --show-nevra option is not specified, the output for this command is presented in the Status, Bundle, Name, Version, and Arch columns. These provide the details of every package that is part of the given bundle. Bundle, Name, Version, and Arch represent the bundle name, package name, package version, and package architecture respectively. The Status field is empty if the package is not installed, and displays “i” if the package is installed, or “v” if the package is installed but is of a different version compared to the one displayed in the list.

The description of these columns is the same with other package commands.

If the --show-nevra option is specified, the output for this command is presented in the Status, Bundle, Name, Epoch, Version, Release, and Arch columns.

patch-search (pse) [options] [querystring]

Searches for patches matching a pattern. Accepts the following option flags:

  • --match-all - Requires patches to match all search strings (default).
  • --match-any - Allows patches to match any search string.
  • --match-substrings - Matches search strings against any part of text.
  • --match-words - Requires search strings to match entire words.
  • -d, --search-descriptions - Searches in patch descriptions, but not patch names.
  • -i, --installed-only - Shows only patches that are already installed.
  • -u, --uninstalled-only - Shows only patches that are not currently installed.
  • -c, --catalog - Shows only the patches from the catalog you specify.
  • --sort-by-name - Sorts patches by name (default).
  • --sort-by-catalog - Sorts patches by catalog, not by name.
remove (rm) [options] [package] [...]

Removes the specified packages. Accepts the following option flags:

  • -N, --dry-run - Tests and displays, but does not actually perform the requested actions.
  • -i, --confirm - Prompts for confirmation.
  • -y, --no-confirm - Does not prompt for confirmation.
rollback (ro) [options] [date or check point]

Rolls back package transactions to the time and date you specify. Sets the rollback preference, which is disable by default. Accept the following option flags:

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

Searches for packages matching a pattern. Accepts the following option flags:

  • --match-all - Requires packages to match all search strings (default).
  • --match-any - Allows packages to match any search string.
  • --match-substrings - Matches search strings against any part of text.
  • --match-words - Requires search strings to match entire words.
  • -d, --search-descriptions - Searches in package descriptions, but not package names.
  • -i, --installed-only - Shows only packages that are already installed.
  • -u, --uninstalled-only - Shows only packages that are not currently installed.
  • -c, --catalog - Shows only the packages from the catalog you specify.
  • --sort-by-name - Sorts packages by name (default).
  • --sort-by-catalog - Sorts packages by catalog, not by name.
  • --show-nevra - Shows the NEVRA details of the packages.
  • --show-duplicates - Shows the duplicate packages available in all catalogs.

If the --show-nevra option is not specified, the output for this command is presented in Status, Catalog, Bundle, Name, Version, and Arch columns. These provide the details of every package that is part of the given bundle. Catalog, Bundle, Name, Version, and Arch represent the catalog name, bundle name, package name, package version, and package architecture respectively. The Status field is empty if the package is not installed, and displays “i” if the package is installed, or “v” if the package is installed but is of a different version compared to the one displayed in the list.

The description of these columns is the same with other package commands.

If the --show-nevra option is specified, the output for this command is presented in the Status, Catalog, Bundle, Name, Epoch, Version, Release, and Arch columns.

summary (sum)

Shows a summary of available updates for each catalog.

update (up) [catalog] [...]

Downloads and installs updates. With no arguments, this installs updates for all subscribed catalogs. Provide the catalog name to keep the updates specific to the mentioned catalogs. For single bundles or packages, use rug install. If you are not subscribed to a catalog, there are no updates available, even if you list the catalog as an argument; you must subscribe to install updates. Accepts the following option flags:

  • -d, --download-only - Only downloads packages.
  • -t, --type - Specifies type of updates.
  • --skip-interactive - Skips interactive updates.
  • -g, --category - Specifies the category of patches to update.
  • -N, --dry-run - Tests and displays, but does not actually perform the requested actions.
  • -y, --no-confirm - Does not prompt for confirmation.
  • --agree-to-third-party-licences - Automatically agree to third party licences.
verify (ve) [options]

Verifies system dependencies. If system dependencies are not satisfied, rug suggests removal or installation of packages necessary to resolve conflicts. Accepts the following option flags:

  • -N, --dry-run - Tests and displays, but does not actually perform the requested actions.
  • -i, --confirm - Prompts for confirmation.
  • -y, --no-confirm - Does not prompt for confirmation.
what-conflicts (wc) [package-dep]

Lists packages that conflict with the item you specify.

what-provides (wp) [querystring]

Displays packages that provide the library, program, or package that you specify as [querystring].

what-requires (wr) [querystring]

Lists packages that require the library, program, or package you specify as [querystring].

Patch Management Commands

patches (pch) [options] [catalog] [catalog] [...]

Shows the patches in a given catalog. Accepts the following option flags:

  • -i, --installed-only - Shows only installed patches.
  • -u, --uninstalled-only - Shows only uninstalled patches.
patch-info [patch]

Shows detailed information for a patch.

Pattern Management Commands

pattern-info [pattern]

Shows detailed information for a pattern.

patterns (pt) [options] [catalog] [catalog] [...]

Shows the patterns in a given catalog. Accepts the following option flags:

  • -i, --installed-only - Shows only installed patterns.
  • -u, --uninstalled-only - Shows only uninstalled patterns.

Policy Management Commands

policy-list (pl) [options]

Lists the effective policies assigned to the devices along with their schedule details.

Preference Management Commands

get-prefs (get) [token]

Displays the value of the specified preference token. If no token is provided, all preferences are displayed. Accepts the following option flag:

  • -d, --no-descriptions - Does not show descriptions of the preferences.
set-prefs (set) [token] [value]

Sets a preference variable.

Use rug get to display the preferences and current values.

Product Management Commands

product-info [product]

Shows detailed information for a product.

products (pd) [options] [catalog] [catalog] [...]

Shows the products in a given catalog. Accepts the following option flags:

  • -i, --installed-only - Shows only installed products.
  • -u, --uninstalled-only - Shows only uninstalled products.

Security Management Commands

key-add (ka) [keyname] [keyid]

Adds to the list of whitelisted keys for a service.

key-delete (kd) [keyid]

Removes from the list of whitelisted keys for a service.

key-list (kl) [...]

Displays whitelisted keys for a service.

Service Management Commands

mount [options] [path]

Mounts a directory as a catalog, adding all packages within the directory to the catalog. The platform for the catalog is assumed to be the same as the platform of the server. Accepts the following option flags:

  • -r, --recurse - Recurse into the directory.
  • -a, --alias - Alias for the new channel.
  • -n, --name - Name for the new channel.
refresh (ref) [uri | number | name]

Refreshes the specified services. If no service is specified, all services are refreshed. You must add a service by using the rug service-add command before you can refresh. Use rug service-list to view the current list of services. The service argument can be the service number from the service-list output.

register (reg) [uri | number | name] [key]

Registers the client against the specified server.

service-add (sa) [options] [uri]

Adds the specified server as a service. In most cases, the URI is the URL of your ZENworks Linux Management server, for example https://zlmserver. Accepts the following option flags:

  • -t, --type - Type of service. The default is zenworks. Use rug service-types to view the available services.
  • -d, --device-type - The type of device you are registering.
  • -k, --key - Registration key.
  • -f, --ignore-failure - Retries the service if it fails. By default, the retry interval is 5 minutes and the number of retry attempts is 3. If you do not use the -f option, the service is not added if the ZENworks Management Daemon (ZMD) cannot resolve the service and register it.
  • -r, --rebuild - Registers a managed device with the ZENworks server by performing a point-in-time replacement of the old agent. The point-in-time replacement of the managed device lets you replace the older device object on the ZENworks Server with the current device object that is requesting the rebuild. The rebuild operation ensures that all the bundle and policy associations are retained. The replacement of the device object is based on the alias name (display name) and the primary IP address of the managed device. This option is not supported for ZENworks Primary Server and ZENworks Secondary Server.
  • -o, --option - Set an option. Accepts the following options:
  • --normal-output - Normal output (default)
  • --terse - Terse output
  • --no-abbrev - No abbreviation
  • --debug - Debug output, prints full exception traces
  • --quiet - Quiet output, prints only error messages
service-delete (sd) [uri | number | name] [...]

Deletes the specified services. Accepts the following option flag:

  • --all - Deletes all the services.
  • -y, --no-confirm - Does not prompt for confirmation.
service-list (sl)

Lists the available services.

service-types (st)

Lists the available service types.

System Commands

clean-cache (cc) [...]

Cleans the HTTP cache.

load-modules (lm) [...]

Loads ZENworks Management Daemon (ZMD) modules.

ping

Pings the ZMD deamon running on the client.

restart

Restarts the ZLM daemon. Accepts the following option flags:

  • -f, --force - Forces the shutdown.
  • -n, --no-wait - Does not wait for confirmation that the daemon has restarted.
  • --clean - Cleans up at restart
schedule (sch)

Shows scheduled items.

shutdown [options] [...]

Halts the ZLM daemon. Accepts the following option flags:

  • -f, --force - Force the shutdown.
  • -n, --no-wait - Don’t wait for confirmation that the daemon was shut down.
sleep [options] [...]

Put the daemon to sleep. Accept the following option flags:

  • -f, --force - Force the restart.
you-clean-cache (yc) [options]

Cleans the YOU cache directory, /var/lib/YaST2/mnt on SLES 9, Novell Linux Desktop, and OES.

User Management Commands

user-add (ua) [username] [privilege] [...]

Adds a new user with the specified username and privileges. The following privileges can be granted: install, lock, remove, subscribe, trusted, upgrade, view, superuser. If you do not provide arguments, you are prompted for them. After the user is added, rug user-update is launched automatically. Use this tool to grant additional privileges. Accept the following option flags:

  • -r, --replace - Replaces the user if that user already exists.
user-delete (ud) [username] [...]

Deletes the specified users.

user-edit (ue) [username]

Edits an existing user. This command is interactive: it first lists privileges, then offers you a prompt. Enter the plus (+) or minus (-) symbol and then the name of the privilege, then press Enter. For example, to permit the user to install software, you would type +install. To save and quit, press Enter on a blank line. The following privileges can be granted or revoked: install, lock, remove, subscribe, trusted, upgrade, view, superuser.

user-list (ul)

Lists users. To view the list of users, you need to have either the readonly or the superuser privilege. The readonly privilege can be enabled by using either the user-add or user-edit command.

Global Options

The following options can be applied to any rug transaction:

--normal-output

Normal output (the default mode). This is somewhere between debug output and terse output.

--terse

Terse output.

--no-abbrev

No abbreviation.

--quiet

Quiet output; prints only error messages.

--debug

Debug output, prints full exception traces.

--version

Prints the rug version and exits.

Authors

Copyright 2005-2010, Novell, Inc.. All rights reserved.

See Also

zlman (1) Novell, zmd (8) Novell, zrmservice (1) Novell, zlm-debug (1) Novell, zlmmirror (1) Novell

To report problems with this software or its documentation, visit Novell Bugzilla.