Softpanorama
(slightly skeptical) Open Source Software Educational Society

May the source be with you, but remember the KISS principle ;-)

Google   


Troubleshooting endpoints

News

Endpoints

Recommended Links Gateway Troubleshooting TEC Documentation Using Log Files to Troubleshoot Tivoli Environment Etc

Key commands:

Tivoli endpoints like Tivoli Framework itself have complex, very convoluted directory structure with path to some some components so deeply nested in a maze of directories that this depth of nesting itself defies any developer logic and might suggest problems with architectural thinking within IBM.  The good thing is that at least it is similar for all operating systems be it NetWare, OS/2, UNIX, or Windows.

The main endpoint directory structure (there is also supplementary /etc/Tivoli directory structure) contains two important subtrees: one leading to   cache directory where all downloaded from the gateway executables reside and the second to mrt directory where the platform specific lcfd binary resides:

Variable
This is just an operating system dependent prefix in the base path to Tivoli directory, Depends on the platform where the endpoint is installed:

Tivoli/lcf/dat/ep_dir
 
ep_dir is just the endpoint number, typically 1, as there is usually only one endpoint installed on the server, but it can be more if there are several independent TMF servers in the environment and each has endpoint installed on particular machine.   For example on Solaris the directory is /opt/tivoli/lcf/dat/1 and it contains the following files and directories (directories are in green)
 
cache last.cfg lcf.id lcf_env.sh lcfd.pid lcfd.st
codeset lcf.dat lcf_env.csh lcfd.log lcfd.sh

Among important endpoint working directory subdirectories and files:
 

Tivoli/lcf/bin/interpr/bin
 
What is called interpr is actually not interpreter but the name of platform on which endpoint is deployed. For example for Solaris directory is be named Solaris2 and that full path is:  /opt/tivoli/lcf/bin/solaris2/bin .

The directory contains the platform-specific binaries  for the following utilities:
  • wpostemsg
  • wpostzmsg
  • wstoptecgw
  • Tivoli/lcf/bin/interpr/mrt

                 Contains platform specific lcfd binary used to manage endpoint.

    The following system startup files are added or modified during the installation of a UNIX endpoint.

    Operating system Files modified
    AIX
    /etc/rc.tma1
    /etc/inittab.before.tma1
     
    HP-UX
    /sbin/init.d/lcf1.sh
    /sbin/rc0.d/K100Tivoli_lcf1
    /sbin/rc1.d/K100Tivoli_lcf1
    /sbin/rc2.d/K100Tivoli_lcf1
    /sbin/rc3.d/S500Tivoli_lcf1
     
    Solaris
    /etc/init.d/lcf1.rc
    /etc/rc0.d/K50Tivoli_lcf1
    /etc/rc1.d/K50Tivoli_lcf1
    /etc/rc2.d/K50Tivoli_lcf1
    /etc/rc3.d/S99Tivoli_lcf1
     
    SuSE Linux
    /etc/rc.d/rc2.d/S99Tivoli_lcf1
    /etc/rc.d/rc3.d/S99Tivoli_lcf1
    /etc/rc.d/rc4.d/S99Tivoli_lcf1
    /etc/rc.d/rc5.d/S99Tivoli_lcf1
    /etc/rc.d/rc2.d/K10Tivoli_lcf1
    /etc/rc.d/rc3.d/K10Tivoli_lcf1
    /etc/rc.d/rc4.d/K10Tivoli_lcf1
    /etc/rc.d/rc5.d/K10Tivoli_lcf1
     
    Other types of Linux
    /etc/rc.d/rc2.d/S99Tivoli_lcf1
    /etc/rc.d/rc3.d/S99Tivoli_lcf1
    /etc/rc.d/rc4.d/S99Tivoli_lcf1
    /etc/rc.d/rc5.d/S99Tivoli_lcf1
    /etc/rc.d/rc0.d/K10Tivoli_lcf1
    /etc/rc.d/rc1.d/K10Tivoli_lcf1
    /etc/rc.d/rc6.d/K10Tivoli_lcf1
     

    System variables

    The following system variables can be set after you install an endpoint.

    System variable Default setting
    LCFROOT Endpoint working directory
    LCF_DATDIR $LCFROOT/dat/ep_dir
    TISDIR $LCFROOT/dat/ep_dir
    INTERP interp_type

    To use these system variables, you must run the environment setup scripts for the endpoint from either of the two scripts created during the installation:

    You can change your login initialization procedure to use the appropriate setup file so that the necessary environment variables and search paths are set to allow you to start the endpoint.

    For example, for Bourne or Korn shell (sh or ksh) you can add the following to your profile:

    if [ -f /opt/Tivoli/lcf/1/lcf_env.sh ]; then
       . /opt/Tivoli/lcf/1/lcf_env.sh
    fi

    For Windows the installation process creates the following setup scripts:

    TMA Login Process

    By default TMA will automatically attempt the initial login to a Management Gateway as soon as lcdf process is launched on newly installed endpoint.  This is done by UDP broadcast using port 9494. All gateways that receive this broadcast forward the request to Tivoli Server Endpoint Manager. The gateway whose request reaches server first handles the communication during login process.  Endpoint manager executes endpoint policies:

    Assignment information is passed to TMA which stores it in LCF.DAT file. After this point all TMA communications go through the assigned Management Gateway.

    After the initial login, the TMA connects directly to its assigned management gateway for subsequent logins. Only if  Management gateway does not respond TMA repeats UDP broadcast to find a new gateway, if any.

    By default TMA listens on port 9495, the Tivoli Gateway uses 9494

    Old News ;-)

    [Feb 22, 2006] Building an Endpoint Image Gulf Breeze Software Partners Tivoli Consulting Training We are Tivoli experts by martinc

    Posted by: martinc on Feb 22, 2006 - 04:27 PM
    BlogArticle 
    Sometimes there are situations that require an image of the endpoint code to be made. In this entry I will demonstrate how to make this work.
    You will need to have the following
    1. one endpoint build and one test install workstation
    2. access to deploy a software package
    3. access to run an inventory scan.

    Preparing the image
    To create the image we will first need to
    1. install the endpoint onto a clean workstation
    2. install a software package onto the workstation (any package, a small one that copies a file to temp would work fine)
    3. execute an inventory scan on the workstation
    Note: This is based on the install going to the root of the C drive. You will need to make the various adjustments if the directory is somewhere else

    Creating the image
    Now that all the files are down for endpoint, software distribution and inventory, we can create the image. To create this image we need to do the following steps
    1. Copy all the files in \Tivoli to a working directory like Temp.
    2. Create a directory in Temp called Windows and copy the file swdis.ini file from \Windows\. Edit this file and remove the header and keys for the workstation.
    3. Copy the directory \Windows\Tivoli to \Temp\Windows. These are the Tivoli Endpoint environment setup files.
    4. remove all the workstation specific files such as:
    \Tivoli\lcf\dat\1\lcfd.log
    \Tivoli\lcf\dat\1\lcfd.bk
    \Tivoli\lcf\dat\1\lcfd.st
    \Tivoli\lcf\dat\1\lcf.dat
    \Tivoli\lcf\dat\1\lcf.id
    files in the \Tivoli\swdis\1
    if it exists \Tivoli\lcf\bin\w32-ix86\mrt\upgrade
    if it exists \Tivoli\lcf\dat\1\cache\out-of-date
    \Tivoli\lcf\scan\*.bk1 or *.bk2
    \Tivoli\lcf\scan\*.nfo

    4. Edit the last.cfg and remove the workstation identifier from the line lcs.machine_name (you could also set some desired values in here for the other workstations). This will get set after the endpoint is installed on the new workstation.
    5. Create a new file called \Temp\Tivoli\Temp\uninst_lcfd.reg and add the lines
    REGEDIT4

    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\LCF]

    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\LCF]
    "UninstallString"="C:\\Windows\\uninst.exe -fC:\\Tivoli\\lcf\\DeIsL1.isu"
    6. Use WinZip to zip all these files with the keep directory names option. Depending on how you save this, it might include the \Temp as the beginning of the path, we want it to only have \Tivoli. The easiest way to do this is to right click on the Tivoli directory in \Temp and select WinZip|Add to tivoli.zip

    Installing the endpoint
    To install the endpoint we will create a batch file to make some various calls. We will also need the utility UNZIP.EXE (can be downloaded from <a href=http://www.info-zip.org/pub/infozip/UnZip.html>http://www.info-zip.org/pub/infozip/UnZip.html or use any other desired CLI unzip utility) The batch file will contain the following entries:
    =================BOF=======================
    REM Added reg delete to remove a new key added from FW 4.1.1 that stored the GUID for
    REM each endpoint. This was causing problems with inventory.
    reg delete hklm\software\tivoli\guid /v tqGUID /f

    REM Extract the files from the Zip file.
    %SYSTEMDRIVE%\temp\unzip.exe -o %SYSTEMDRIVE%\temp\tivoli.zip -d %SYSTEMDRIVE%\

    REM Setting the environment variables
    call %SYSTEMROOT%\tivoli\lcf\1\lcf_env.cmd

    REM Install the endpoint service.
    REM the -im means to install the service but do not start. This is important to avoid issues with
    REM TAP not being loaded for an inventory scan or distribution.
    REM the -w 1 means to enable Wake On Lan (WOL)
    REM the -d 3 means to set the debug level to 3
    REM the -C C:\Tivoli\lcf\dat\1 specifies the endpoint's working directory
    call "%LCF_BINDIR%\lcfd" -im -D lcs.login_interfaces=severname+9494 -w 1 -d 3 -C "%LCF_DATDIR%"

    REM Set some of the configs just to confirm.
    echo log_threshold=3 >> "%LCF_DATDIR%\last.cfg"
    echo wol_enable=1 >> "%LCF_DATDIR%\last.cfg"
    echo lcs.login_interfaces=servername+9494 >> "%LCF_DATDIR%\last.cfg"
    echo address_notif_interval=43200 >> "%LCF_DATDIR%\last.cfg"
    echo login_interval=1800 >> "%LCF_DATDIR%\last.cfg"

    REM Run the NTCONFIG.EXE to set the tmersrvd id and Tivoli_Admin_Privileges group
    call "%LCF_BINDIR%\ntconfig" -e

    REM Activate TAP. This requires a reboot for it to activate.
    call "%LCF_BINDIR%\wlcftap.exe" -a

    REM Add registry keys
    if exist %SYSTEMDRIVE%\temp\uninst_lcfd.reg regedit /s %SYSTEMDRIVE%\temp\uninst_lcfd.reg
    =================EOF=======================

    Testing the install
    We now have the Zip file, Unzip.exe and the batch file required to do the install of the endpoint. To test this out we need a clean workstation to copy these files to the temp directory on the new workstation. Once the files are copied, execute the batch file to install the endpoint. Then reboot the system so that the TAP is activated.

    Now test an Inventory Scan and Distribution. If you check the lcfd.log file, you will notice that when checking the prereqs in the cache, they will report as Found. If there is a missing file you will see Not Found and that file will be copied to the workstation.

    On a side note, if you are including the Inventory and SD files as part of your image, you will have to rebuild that image again if there are any changes to FW or CM as this would make the creation of this image pointless if the files had to all be updated anyway.

    Also as of FW 4.1.1 there is a new gateway setting called mcache_bwcontrol. This will allow the method cache files to be distributed using MDIST2.

    3.6 Tivoli Endpoint

    Chapter 3. Maintaining the Tivoli Framework environment 237 is no longer in its endpoint list, it contacts the endpoint manager for the new gateway assignment, and communicates this back to the endpoint. The endpoint then performs a normal login to its new primary gateway. 3.6.5.2  Isolation An endpoint is considered isolated when it cannot connect to its primary gateway. In such situations, it attempts to connect the alternate gateways listed in its interfaces file. Once the endpoint contacts an alternate gateway, its login request is forwarded to the endpoint manager. At this point, the endpoint manager runs select_gateway_policy to determine an appropriate list of gateways for the endpoint, and passes this back to the endpoint through the intercepting gateway.

    3.6.5.3  Orphaned An endpoint is considered orphaned if it is functional, but deleted from the endpoint manager.

    In this situation, the endpoint login is performed as an nitial login, in which all the login policies are run.

    The only difference is that the LCF_LOGIN_STATUS environment variable is changed to 7 (for orphaned) and the endpoint maintains its existing OID.

    3.6.6  Endpoint migration scripts

    The endpoint migration scripts referenced in this section are all available in Appendix  A, “Useful Tivoli scripts” on page 377. They are designed to be a starting point. You will have to update them to provide the functionality appropriate for your TMR configuration, topology and general requirements. 3.6.6.1  epm.ksh script This endpoint migration script migrates an endpoint from one gateway to another within one TMR. The script determines if the endpoint has a status of manageable, as described in Section 3.6.1, “Endpoint status” on page 231. If not, the script returns an error. Otherwise, it performs the migration. If the new-gateway parameter passed to the program is the same as the endpoint’s existing gateway (as checked by a wep status command), the script returns the message “No action required.”

     Syntax: epm <endpoint-name> <new-gateway>

    Return codes and messages:   •  Return code 0: “Migration completed”   •  Return code 1: “Endpoint NOT MANAGEABLE”

     
    Chapter 3. Maintaining the Tivoli Framework environment 233

    Figure 130.  Korn shell script for AIX epstatus 3.6.2  Monitoring endpoints You may need to monitor endpoints to assure critical applications are running properly, or, for example, to distribute file packages. The script in Figure  131 on page  234 is an example of a monitor run from the TMR server that pings and runs wep ls  (lists all gateways in a TMR, their assigned endpoints, and the endpoint status) against every endpoint in the TMR. This script assumes a functional DNS environment as well as a text file listing of all endpoints. This file can be generated by issuing the command:

    wep ls | grep -v ^G | awk  ‘{print $2}’  | grep -v gateway > endpoint.txt

     

    Recommended Links


    In case of broken links please try to use Google search. If you find the page please notify us about new location
    Google     

    Maintenance and Troubleshooting Guide / Troubleshooting endpoints

    When determining problems with the endpoint, it is important to remember that the endpoint operates in conjunction with two other components of the Tivoli environment: the endpoint manager and the gateway. Therefore, you need to assess the state of several Tivoli Management Framework components when troubleshooting endpoints: the endpoint itself, the gateways it can connect to, and the endpoint manager that is on the Tivoli server.

    This chapter contains the following sections:


    Copyright © 1996-2008 by Dr. Nikolai Bezroukov. www.softpanorama.org was created as a service to the UN Sustainable Development Networking Programme (SDNP) in the author free time. Submit comments This document is an industrial compilation designed and created exclusively for educational use and is placed under the copyright of the Open Content License(OPL). Original materials copyright belong to respective owners. Quotes are made for educational purposes only in compliance with the fair use doctrine.

    Standard disclaimer: The statements, views and opinions presented on this web page are those of the author and are not endorsed by, nor do they necessarily reflect, the opinions of the author present and former employers, SDNP or any other organization the author may be associated with. We do not warrant the correctness of the information provided or its fitness for any purpose.

    Last modified: June 02, 2008