Sun Update Connection - Automated Baseline Management Service 1.0 User's Guide

Installing the TLP Server Software

The TLP server software installation includes the following tasks:

  1. Installing or upgrade the TLP server software on a dedicated system.

  2. Modifying the tlp.cfg file for your site's specific setup.

  3. Updating the configuration, snapshots, and the metafiles (Applies to TLP software upgrades only)

  4. Configuring the TLP web server script configuration.

This section provides instructions for installing and configuring the TLP server software. Also included in this section are instructions for upgrading the TLP software and installing the TLP baselines.

ProcedureHow to Install the TLP Server Software

This procedure describes how to install the TLP server software. In this procedure, the current working directory is the TLP installation directory, /opt/SUNWtlp.

Before You Begin

Before you begin the installation, ensure that you have the following:

Steps
  1. Log in as superuser to the system where you will install the TLP server software.

  2. Extract the archive SUNWtlp-2.3.tar.gz to the /tmp directory.


    # gzcat SUNWtlp-2.3.tar.gz | tar xvf -
    
  3. Check the README file in /opt/SUNWtlp/README for the latest updates.

  4. Install the TLP software package.


    # pkgadd -a tlp.policy -d SUNWtlp-2.3 
    

    By default, the TLP software is installed in the /opt/SUNWtlp directory. See How to Add Software Packages (pkgadd) in System Administration Guide: Basic Administration for information on how to modify the installation directory.

  5. Create the UNIX user and group for the tlp-user

    Although you can run the TLP tool as the root user, the preferred method is to create a unique user ID. Use the Solaris Management Console to create the new user and group. For more information about creating users and groups with the Solaris Management Console, see Setting Up User Accounts (Task Map) in System Administration Guide: Basic Administration.

  6. Create the TLP data directory and give ownership to the tlp-user.


    # mkdir DataDirectory
    # chown tlp-user DataDirectory
    

    The data directory is used by the TLP tool for storing patches and TLP results. Note the location of this directory, as you will need to add it to the tlp.cfg file later.

  7. Log in to the server as the tlp-user.

    The remaining steps are performed as the tlp-user.

  8. Using a text editor, modify the TLP server conf/tlp.cfg configuration file.

    For more information, see How to Modify the TLP Configuration File.

  9. Configure the CGI script to enable file transfers from the TLP client to the server.

    For more information, see How to Install and Configure the CGI Script.


Example 2–1 Installing the TLP Server Software

This example shows a TLP server software installation. For the sake of brevity, the output in this example has been truncated.


root# gzcat SUNWtlp-2.3.tar.gz | tar xf -

root# ls
README              SUNWtlp-2.3         SUNWtlp-2.3.tar.gz  tlp.policy

root# pkgadd -a tlp.policy -d SUNWtlp-2.3

The following packages are available:
  1  SUNWtlp     Traffic Light Patchtool
                 (sparc) 2.3

Select package(s) you wish to process (or 'all' to process
all packages). (default: all) [?,??,q]: y

Processing package instance <SUNWtlp> from /var/tmp/tlp/SUNWtlp-2.3

Traffic Light Patchtool
(sparc) 2.3
============================================================================
Copyright (c) 2001-2003 Sun Microsystems, Inc. All rights reserved.
Protected by copyright and distributed under licenses restricting its use,
copying, distribution and decompilation. Sun, Sun Microsystems, the Sun
.
.
..
Checking for perl >= 5.005_03 ... yes
Checking for update ... no

Please enter installation directory (default: /opt/SUNWtlp) :  [?] 

TLP requires a data directoy for the baselines,
Explorer and generated patch sets. It is recommended to
put this directory in a separate file system.

Please enter a data directory (default: /opt/SUNWtlp/data) : \
[?] /export2/data

Which user:group should be the owner of tlp installation \
(default: root:other)
?  [?] tlpuser:staff

Create link /opt/sun/bin/tlp -> /opt/SUNWtlp/tlp ? (default: y) [y,n,?] 

Create link /opt/sun/bin/cpc -> /opt/SUNWtlp/tlp ? (default: y) [y,n,?] 

The selected base directory </opt/SUNWtlp> must exist before
installation is attempted.

Do you want this directory created now [y,n,?,q] y
Using </opt/SUNWtlp> as the package base directory.
## Processing package information.
## Processing system information.
## Verifying disk space requirements.
## Checking for conflicts with packages already installed.
## Checking for setuid/setgid programs.

This package contains scripts which will be executed with super-user
permission during the process of installing this package.

Do you want to continue with the installation of <SUNWtlp> [y,n,?] y

Installing Traffic Light Patchtool as <SUNWtlp>
## Executing preinstall script.
## Installing part 1 of 1.
/opt/SUNWtlp/CHANGES
/opt/SUNWtlp/README
/opt/SUNWtlp/conf/defaults/Patchcluster_README
/opt/SUNWtlp/conf/defaults/WITHDRAWNPATCHES
/opt/SUNWtlp/conf/defaults/black_list.cfg
/opt/SUNWtlp/conf/defaults/cpc.cfg
/opt/SUNWtlp/conf/defaults/log.cfg
.
.
.
## Executing postinstall script.
Installing .... /opt/SUNWtlp/conf/tlp.cfg
Installing .... /opt/SUNWtlp/conf/cpc.cfg
Installing .... /opt/SUNWtlp/conf/log.cfg
Installing .... /opt/SUNWtlp/conf/WITHDRAWNPATCHES
Installing .... /opt/SUNWtlp/conf/white_list.cfg
Installing .... /opt/SUNWtlp/conf/black_list.cfg
Installing .... /opt/SUNWtlp/conf/non-standard-patchids
Installing .... /opt/SUNWtlp/conf/node_group_definition.cfg
Setting DataDirectory in /opt/SUNWtlp/conf/cpc.cfg to /export2/data
Setting DataDirectory in /opt/SUNWtlp/conf/tlp.cfg to /export2/data
Creating link /opt/SUNWtlp/tlp --> /opt/sun/bin/tlp
Creating link /opt/SUNWtlp/tlp --> /opt/sun/bin/cpc
Setting ownership of /opt/SUNWtlp to tlpuser:staff

Installation of <SUNWtlp> was successful.

ProcedureHow to Modify the TLP Configuration File

The TLP configuration file contains default values, parameters, and configuration information for installing, using, and maintaining the TLP tool. This file also contains general instructions for modifying the file. To complete the TLP installation and setup at your site, you might need to modify this file. This section describes how to make changes to the tlp.cfg file.

Steps
  1. To change a default value within the configuration file, use a text editor to edit the file.

  2. Replace the default value with the new value and save the file.

    Note that some of the available options within the file are commented out by default. To set one of these parameters, uncomment the specific line within the file and save the file.


    Note –

    The complete TLP default configuration file, tlp.cfg, is located in the /opt/SUNWtlp/conf directory. Configuration instructions are included in the file. To access the file at this location, you must have installed the TLP software. If you need to restore the original default configuration file, a copy of the original file is always stored in the default subdirectory.



Example 2–2 Changing the DataDirectory Global Variable

This example shows the global variables portion of the TLP configuration file, where the DataDirectory value is set to the $BaseDirectory/data directory. Note that the variable, $BaseDirectory, is referenced here. To use a different DataDirectory value, simply replace the $BaseDirectory/data directory with a different directory, and save the file.


# You can define you own variables here and refer later to it, e.g if
# you define "DataDirectory  /usr/local/tlp" you can later use it like
# in "SnapshotDirectory $DataDirectory/repository"

DataDirectory $BaseDirectory/data

# Helper-Programs
# Tar /usr/bin/tar
# Uncompress /usr/bin/uncompress 

ProcedureHow to Install and Configure the CGI Script

The Common Gateway Interface (CGI) script is used to transfer the Explorer and PatchPro output from the TLP client to the TLP server, by using the HTTP protocol. The TLP client contacts the web server that is running on the TLP server. The client then transfers the data by using a simple file upload over HTTP. The script writes the uploaded file to a directory that is read by the TLP server software. This procedure describes how to install and configure the CGI script.

Before You Begin

To complete this procedure, make sure you have the following:


Note –

This steps in this procedure use a configuration for the Apache Web Server. If you are using a different web server, adjust these steps accordingly.


Steps
  1. Install the CGI script.

    After you install the TLP software, a cgi subdirectory is placed in the installation BaseDirectory. By default, the tlp_server.pl script is located in the /opt/SUNWtlp/cgi directory.

    You can install the script in one of the following ways:

    • Add a ScriptAlias to the httpd.conf file.

      This method is the preferred method.

      1. Locate the httpd.conf file. Use a text editor to add the following line:


        ScriptAlias /tlp-cgi/ /opt/SUNWtlp/cgi/

        where /opt/SUNWtlp/cgi/ is the default installation directory. If you did not install the TLP software in this directory, replace this information with the appropriate installation directory. Adding this line to the file maps all HTTP requests that are directed to http://server/tlp-cgi/ to the /opt/SUNWtlp/cgi/ directory.

      2. To ensure that the modifications are correct, run a configtest before restarting the web server.

      3. After you edit the httpd.conf file, restart the web server.

    • Copy the tlp_server.pl script and the tlp_server.cfg file to the cgi-bin directory.


      Caution – Caution –

      If you use this method, there is a risk that during a TLP update, the tlp_server.pl script might not be updated in another directory.


      If you are unable to modify the httpd.conf file, copy the tlp_server.pl script and the tlp_server.cfg file to a directory that contains a set of the ExecCGI configuration directives. By default, this is usually the cgi-bin directory. Lastly, copy the tlp_server.pl script and the tlp_server.cfg file to a directory where you can run CGI applications.

  2. Modify the tlp_server.cfg file.

    For more information, see Example 2–3.


Example 2–3 Modifying the tlp_server.cfg file.

All configuration data is stored in the tlp_server.cfg file. The CGI script writes all files that are received from the clients to the TargetDirectory directory. Make sure that your web server has the sufficient write permissions for this directory. In addition, make sure that the TLP tool has sufficient read and write permissions to and from this directory. This example shows the portion of the tlp_server.cfg file where this variable is defined.


tlp_server.cfg
# TargetDirectory is the directory where the TLP
# server will store all files received by the clients

TargetDirectory = /opt/SUNWtlp/data/explorer

ProcedureHow to Upgrade the TLP Server Software

This procedure describes how to upgrade to the latest version of the TLP server software. In this procedure, the current working directory is the TLP installation directory, /opt/SUNWtlp.

Before You Begin

Before you begin the installation, ensure that you have the following:

Steps
  1. Log in as superuser to the system where you will install the TLP server software.

  2. Extract the archive SUNWtlp-2.3.tar.gz to the /tmp directory.


    # gzcat SUNWtlp-2.3.tar.gz | tar xvf -
    
  3. Check the README file in /opt/SUNWtlp/README for the latest updates.

  4. Install the TLP software package.


    # pkgadd -a tlp.policy -d SUNWtlp-2.3 
    

    By default, the TLP software is installed in the /opt/SUNWtlp directory. See How to Add Software Packages (pkgadd) in System Administration Guide: Basic Administration for information on how to modify the installation directory.

  5. Log in to the server as tlp-user.

    The remaining steps are performed as the tlp-user.

  6. Save the old tlp.cfg file.


    $ cd /opt/SUNWtlp/conf
    $ mv tlp.cfg tlp.cfg.bak
    
  7. Copy the default 2.3 tlp.cfg file to /opt/SUNWtlp/conf/tlp.cfg.


    $ cp default/tlp.cfg
    
  8. Modify the tlp.cfg file for your site's setup.

    See How to Modify the TLP Configuration Filefor task-related information.

Next Steps

After you complete the TLP server software upgrade and configure the tlp.cfg file, you will need to perform the following tasks:

ProcedureHow to Update the TLP Configuration, Snapshots and Metafiles After Upgrading the TLP Software

This procedure describes how to update the TLP configuration and rebuild the existing snapshots after you have upgraded to the TLP 2.3 software. Perform the steps in this procedure as the tlp-user.

Steps
  1. Update the TLP metafiles.


    $ tlp download metafiles
    
  2. Rebuild the snapshots.

    This step is required in order to update the snapshot format to the latest TLP release.


    $ tlp snapshot rebuild
    
  3. Fix any inconsistencies between the patchdiag.xref file and the snapshots.


    $ tlp snapshot fix
    
  4. Check and replace any withdrawn patches in the TLP repository.


    $ tlp repo check
    

    For more information about working the WITHDRAWN patches, see How to Update the WITHDRAWN Patches List.