Roadtech Administrative Toolkit environment.

History

since the 2002/2003 changes the scripts use setenv.lib in conjunction with a number on configuration files to work out which functions are installed and where.

There are options within both the roadrunner data set menu, and the system administration menu. To display the efective environment as determined by the scripts.

Determine global system, and application environment.

Scripts that use this method start with the following code fragment.

CallName="$0"

#       ----- Pickup main roadtech environment -----

Env=$(RTadmin environment 2>/dev/null)

if test -z "$Env"
then
  echo "Oops Problem locating config :-" >&2
  echo "for $CallName" >&2
  exit 2
else
  RTadmin=$(dirname "$(dirname "$Env")")
  . "$Env"
fi

#
# *****************************************************************
#

They will also in most cases use some variant on the following three bits.

down flag

Check for the global down flag.

if test -r "$flagdir/down.flag"
then
  ${PRINT} " Very sorry you may not user Roadrunner at present.\n"
  cat $flagdir/down.flag
  ${PRINT} "\n\nPress return to continue."
  read get_var
  exit 2
fi

Roadrunner data set specific environment.

If the script is going to access Roadrunner. It must make a call to SetDatapathEnv, after setting a value for DATAPATH and before invoking a program that accesses Roadrunner data. This will set the DATA SET specific environment.


#       ----- Handle DATAPATH specific settings -----
SetDatapathEnv

Check for roadrunner data set specific down flag.

if test -r "${dsflag}_down"
then
  ${PRINT} " Very sorry you may not user Roadrunner at present.\n"
  cat ${dsflag}_down
  ${PRINT} "\n\nPress return to continue."
  read get_var
  exit 2
fi

Environment variables

The following tables document the main variables used in the scripts, and the "Exp" column notes which ones are exported for the benefit of called programs.

System details

VarExpDescription
admYSystem admin files {/usr/adm, /var/adm, ... }
rmlicenceYRMcobol licence
rmverYRMcobol version
rrhomeYDirectory containing users home directories {/u, /home, .... }
sysnameYSystem name got from uname {AIX, UNIX_System_V, ... }
sysrelYuname -r
sysverYuname -v
tmpdirYApplication temporary directory. {/tmp, /var/tmp}

Roadtech {rt.var}

RTadmin is set to the PATH of the base directory containing the administrative programs.
VariableExpPurposeDefault
RTadminNPath to Admin scripts.
rrinst must select install and copy to correct target for machine.
 
RTadmin_defNDefault install directory for RoadTech scripts on current platform/usr/share/rr85/instbits,
/usr/share/Roadtech?,
/usr/share/RTadmin?
RT_OwnerNUser who owns filesrr85
RT_GroupNGroup that uses filesrm85
RT_ClusterYUsed to indicate that this server is part of an AIX HACMP Cluster.FALSE
RT_CSPOCNPATH of CSPOC wrapper. AIX HACMP Cluster. 
RR_ResourceGroupN roadrunner

If it does not exist as you are upgrading from a pre 2003 version, and the option file does not exist. A sample option file ${RTadmin}/rt.var will be created, when the check configuration option is run from the new scripts.


# Roadtech variable initialization
# RT_Owner=${RT_Owner}
# RT_Group=${RT_Group}
# RT_EdiGroup=${RT_EdiGroup}

Additional options may be needed if subsystems have been installed at unusual locations.
RR_Dir
IL_Dir

Roadrunner General

VariableExpPurposeDefault
CallNameNPath name under which script was started. 
ProgNameNActual path name of script. 
RR_DirYRoadrunner install directory /usr/rr85, /usr/share/rr85, /usr/share/roadrunner?
RR_DirDefNDefault install directory for Roadrunner on current platform./usr/rr85, /usr/share/rr85, /usr/share/Roadrunner?
rrdirNRoadrunner install directory Obsolete 
flagdirYFlag directory { $tmpdir/rr_flag, ... }
clonedirYTarget directory for clone.{/rrclone}
libdirYSource directory for script libraries$RTadmin/lib
libYBase library.$libdir/base.lib
LPDESTNDefault printerlpdest()
LogDirN  
PidDirN  
WebDirN  
DATAPATHYPath used to track dataset between sessions$(<$HOME/.rrdatapath)
RR_Prog3NAs far as I am aware this has only been used, on programming and support servers. 
If it does not exist as you are upgrading from a pre 2003 version, and the option file does not exist a sample option file ${RR_Dir}/rr.var will be created. When the check configuration option is run from the new scripts.

# Roadrunner variable initialization 
There is provision for an additional per user option file $HOME/bin/rr.var, as far as I am aware this has only been used on development servers.

There is no template for this file.

Roadrunner Dataset

Variables relating to a particular dataset.

Most are initialized via a call to SetDatapathEnv this function is available to any script, that has loaded setenv.lib.

VariableExpPurposeDefault
RR_DataPathNPath of current dataset$(<$HOME/.rrdatapath)
RR_DataSetNName of current datasetread from $rrdir/.datapaths
RR_Prog1NMain program directory$RR_DataPath/cobs
RR_Prog2NUpdate program directory$RR_DataPath/newcobs
RR_ProgDatNProgram related Data
SCREENS, MENUS, etc
$RR_DataPath/instbits
dsflagYFlag name for current dataset$flagdir/$(echo ${RR_DataPath}|tr -A '/' '_')
RUNPATHYSearch path to programs and program data.${RR_ProgDat}:${RR_Prog3}:${RR_Prog2}:${RR_Prog1}:/usr/rmcobol
RM_ConfigNRM_Cobol configuration file-c $RR_DataPath/terminfo.cfg
RM_ReportNRM_Cobol printer configuration-x $RR_DataPath/report.cfg
N
N

Some variables may be adjusted on a set by set basis, by the use of the dataset dependent configuration file. $RR_DataPath/dataset.var

This file is created during the initial install, or when the menus are used to initialize a new dataset.

Roadrunner Options.

These may be set in the files :-
VariableExpPurposeDefault
RT_MediaNDisplay Media menuTRUE
RT_PrintNDisplay print menuTRUE
RT_MailNDisplay Mail MenuTRUE
MENUNrr displays menu of datasets 
KILLNKill option from backup 
REVEALNUn-hide some options 
N