Mirroring External Sources into ZENworks Linux Management


Patches and updates from various Linux sources are published on the Internet. For large deployments, you also may have several ZENworks Linux Management zones in your environment. Mirroring enables you to have ZENworks retrieve large numbers of packages from an external source hosted outside of your network, such as from the Internet or from outside your local zone.

Using mirroring, you can maintain updated packages for operating systems such as SUSE LINUX and SLES LINUX as well as Red Hat systems. With mirroring you can also share catalogs and bundles between two independent zones.

Mirroring is accomplished through the use of configuration files and a command-line tool called zlmmirror. To schedule mirroring to occur on a regular basis, you need to configure a CRON entry and schedule when the zlmmirror command should run.

The zlmmirror usage process typically works in the following fashion:

1.

The system administrator creates a configuration file (or converts a previously existing ZENworks Linux Management configuration file) called zlmmirrorconf.xml, which details specifics of the remote and local servers, as well as which catalogs, bundles, and packages are to be copied. The zlmmirrorconf.xml file should be located in the /etc/opt/novell/zenworks directory.

2.

System administrators set a cron entry or other scheduled time for zlmmirror to run.

3.

Using the zlmmirrorconf.xml file, zlmmirror determines what catalog data to request from the servers.

4.

zlmmirror authenticates to the remote server and downloads information about selected catalogs.

5.

zlmmirror authenticates to the local server as a standard client, and downloads information about those same catalogs.

6.

Catalog data from the remote and local servers is compared with the package and target filtering information from zlmmirrorconf.xml, to determine which packages need to be downloaded.

7.

Packages are downloaded from the remote server.

8.

zlmmirror authenticates to the local ZENworks Linux Management server as an administrator and adds the packages to the server in the appropriate bundles, creating catalogs as necessary.

Now let's take a closer look into the zlmmirrorconf.xml file.

Looking at the zlmmirrorconf.xml File

The zlmmirrorconf.xml file describes the URL locations of the source servers that will be providing the information to the local primary server running the zlmmirror command. Additionally, the zlmmirrorconf.xml file configures which catalogs or channels should be retrieved and how to place the packages from these sources into ZENworks Linux Management.

For mirroring to function, you must define a single source server (you can have only one) and a single destination server (only one here, too). You can then define any number of catalog configurations that describe how the source server's content should be mapped into your ZENworks Linux Management server.

Because there are times when you want to mirror from many different sites, zlmmirror takes a config file as a parameter. If no parameter is specified, zlmmirror uses the default zlmmirrorconf.xml file. If you want to mirror from multiple sources, create a configuration file for mirroring from each source, and then create a cron job that launches zlmmirror with the desired config file for each source you want to mirror.

SOURCE SERVER DEFINITION

The following template is used to define the source server:

 <SourceServer>    <Base>http://red-carpet.ximian.com/</Base>    <Type>rce</Type>    <User />    <Password /> </SourceServer> 

The Base path to the server you want to mirror must be in one of the following formats, depending on the type:

  • For ZENworks Linux Management sources, use the format of https://server

  • For Red Carpet Enterprise servers, use the format of https://server/path

  • For YAST updates, use the format of http(s)://server/path or ftp://server/path

  • For Red Hat Network updates, use the format of http(s)://server/path

The type of server must be one of the following specifications:

  • ZLM for ZENworks 7 Linux Management Servers

  • RCE for Red Carpet Enterprise or ZENworks 6.x Linux Management systems

  • YAST for YAST Online Update servers

  • RHN for Red Hat Network systems

The user is the name of an account that has rights to read the packages and information from the source server. The Password field is the corresponding password for the user account.

The User is the name of an administrator account that has rights to write and create the bundles and catalogs into the destination server. If no user is specified, zlmmirror reads the identity from the following files, depending on the type:

  • ZENworks 7 Linux Management: /etc/opt/novell/zenworks/zmd/deviceid

  • Red Carpet Enterprise or ZENworks 6.x Linux Management: /etc/ximian/mcookie

  • YAST: /etc/sysconfig/onlineupdate

  • Red Hat Network: Leave the username empty in the form.

zlmmirror reads the following locations for the password portion of the form:

  • ZENworks 7 Linux Management: /etc/opt/novell/zenworks/zmd/secret

  • Red Carpet Enterprise or ZENworks 6.x Linux Management: /etc/ximian/partnernet

  • YAST: /etc/sysconfig/onlineupdate

  • Red Hat Network: Leave the password empty in the form.

DESTINATION SERVER DESCRIPTION

You must use the following format to describe the destination server:

 <DestinationServer>    <Base>https://localhost</Base>    <Type>zlm</Type>    <User>Administrator</User>    <Password>password</Password> </DestinationServer> 

The User is the name of an administrator account that has rights to write and create the bundles and catalogs into the destination server. If no user is specified, zlmmirror reads the identity from the same files as specified in the preceding section.

The Base path in the form needs to be of the format of https://server for ZENworks 7 Linux Management and /path/on/filesystem for STATIC types, where the mirroring just copies the packages to the file system.

CATALOG AND BUNDLE CONFIGURATION

You need to provide details on the catalogs and bundles you want mirrored to the ZENworks Linux Management server. This is defined in the catalog configuration form. Each catalog you want to mirror must have a separate CatalogConf section, as follows:

 <CatalogConf>    <Name>Red Carpet 2</Name>    <LocalName>Red Carpet 2</LocalName>    <Target>sles-9-i586</Target>    <ExcludeTarget></ExcludeTarget>    <Bundle></Bundle>    <ExcludeBundle></ExcludeBundle>    <Package>lib.*</Package>    <ExcludePackage></ExcludePackage> </CatalogConf> 

The Name field is the name of the catalog or channel you want to mirror from this source server. This is the only required parameter. If it is not specified, zlmmirror creates or places the packages in a catalog with the same name.

Local Name field is the name of the catalog in which you want the mirrored software placed. If no local name is specified, the catalog name from the source server is used.

Folder specifies the object database folder (for example, /folder1/folder2) where bundles and catalogs are created and updated. If not specified, the catalogs and bundles will be created and updated in a /zlmmirror folder.

Target restricts the mirroring operation on this catalog to packages and patches that support the specified target platform(s). If no target is specified, packages for all platforms are mirrored. This element can be specified multiple times, and can contain either a target name or a regular expression string for wildcard matching of target names.

ExcludeTarget is the same as Target, except packages and patches supporting the specified target platform(s) are excluded.

ExcludeBundle is performed after Target, so platforms appearing in a Target and ExcludeTarget are ultimately excluded.

Bundle restricts the mirroring operation on this catalog to the specified bundle(s). If not specified, all bundles are mirrored. This option is valid only for ZENworks Linux Management and YAST source servers. It can be specified multiple times and can contain either a bundle name or a regular expression string for wildcard matching of bundle names.

ExcludeBundle is the same as Bundle, except packages and patches contained in the specified bundle(s) are excluded. This option is valid only for ZENworks Linux Management and YAST source servers. It can be specified multiple times and can contain either a bundle name or a regular expression string for wildcard matching of bundle names. ExcludeBundle is performed after Bundle, so bundles appearing in a Bundle and ExcludeBundle are ultimately excluded.

Package restricts the mirroring operation on this catalog to the specified package(s). If not specified, all package(s) are mirrored. This option is valid only for ZENworks Linux Management and YAST source servers. It can be specified multiple times and can contain either a bundle name or a regular expression string for wildcard matching of bundle names.

ExcludePackage is the same as Package, except specified package(s) are excluded. This option is valid only for ZENworks Linux Management and YAST source servers. It can be specified multiple times and can contain either a bundle name or a regular expression string for wildcard matching of bundle names. ExcludePackage is performed after Package, so packages appearing in a Package and ExcludePackage are ultimately excluded.

EXAMPLE CONFIGURATION

The following displays a typical configuration file to mirror an NLD catalog from zone1 to zone2.

 <ZLMMirrorConf>   <SourceServer>   <Base>https://sourceprimary.zone1.com</Base>   <Proxy />   <Type>zlm</Type>   <User>Administrator</User>   <Password>source</Password> </SourceServer> <DestinationServer>   <Base>https://localhost</Base>   <Type>zlm</Type>   <User>Administrator</User>   <Password>target</Password> </DestinationServer> <CatalogConf>   <Name nld-9-i586/>   <LocalName nld-9-i586/>   <Folder Mirror/>   <Target />   <ExcludeTarget />   <Bundle />   <ExcludeBundle />   <Package />   <ExcludePackage /> </CatalogConf> </ZLMMirrorConf> 

This configuration file causes the nld-9-i586 catalog to be copied and updated on the local primary server. The local catalog name will also be nld-9-586 and will exist in the /Bundles/Mirror folder of the ZENworks Control Center.

Finishing Up the Configuration

You should test your configuration file to see whether it is formed properly and will perform the intended actions.

After you have created the configuration file for a source server, run the following command to perform a dry run of the mirroring operation, and optionally add the verbose flag to see detailed messages:

 zlmmirror mirror -c zlmmirror-config.xml --dryrun verbose 

If this operation provides the intended results, run the mirror command without the dry run flag to complete the operation:

 zlmmirror mirror -c zlmmirror-config.xml 

After you have configured your system and created your cron entries, zlmmirror continually refreshes your local catalogs with the latest updates.

See Appendix A, "Commands," for all the options that are available for the zlmmirror command.




Novell ZENworks 7 Linux Management Administrator's Handbook
Novell ZENworks 7 Linux Management Administrators Handbook
ISBN: 0672327848
EAN: 2147483647
Year: 2005
Pages: 147

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net