DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400 Tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Rational R1000/400 Tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - metrics - download
Index: T d

⟦b1006f831⟧ TextFile

    Length: 2570 (0xa0a)
    Types: TextFile
    Names: »do_add_license_info«

Derivation

└─⟦1e97d88e5⟧ Bits:30000533 8mm tape, Rational 1000, RATIONAL ASIS (AIX) 110.2.4.15
    └─⟦this⟧ »./releases/asis.110.2.4.15/install/do_add_license_info« 

TextFile

#!/bin/sh
# @(#)do_add_license_info  $Revision: 1.16 $  $Date: 1994/01/17 17:44:31 $
# @(#)Copyright(c) 1993,1994 by Rational.
#
#  MODULE SPECIFICATION
#  Name:
#    do_add_license_info
#
#  Subsystem:
#    install
#
#  Description:
#    Take the license key that the customer gets from Rational and
#    add this to the license.dat file.
#

def_home=`dirname $install_dir`

check_and_set_arch

read_prod_desc

license_feature=${license_feature:-$feature}

load_vars

if [ $SV_VERBOSE_MODE -eq $YES ]
then
    silent_flag=0
else
    silent_flag=1
fi

if [ -z "$SV_LIC_FILE_NAME" ]
then
    echo "You must run get_license_info before running add_license_info."
    exit 1
fi

if [ ! -f "$SV_LIC_FILE_NAME" ]
then
    echo "License file '$SV_LIC_FILE_NAME' not found"
    exit 1
fi

if [ ! -w $SV_LIC_FILE_NAME ]
then
    echo "License file '$SV_LIC_FILE_NAME' not writable"
    exit 1
fi

if [ "$SV_NODE_LOCKED" = yes ]
then
    NUM_LICENSES=1
fi

echo "With the year set to 00 the license for $product_name will not expire."
EXP_DATE="01-jan-00"

more=1
while [ $more -eq 1 ]
do
    get_input "Expiration date [dd-mmm-yy, example: 01-jan-93]: " $EXP_DATE
    EXP_DATE=$result

    get_input "Number of $license_feature licenses: " $NUM_LICENSES
    NUM_LICENSES=$result

    get_input "License key: " $LICENSE_KEY
    LICENSE_KEY=$result

    more_cmd <<!
Your answers were:

       Expiration date: $EXP_DATE
    Number of licenses: $NUM_LICENSES
           License key: $LICENSE_KEY
!
    ask_ok
done

if [ -n "$SV_NL_HOSTID" ]
then
    SV_NL_HOSTID=" $SV_NL_HOSTID"
fi


if [ "$SV_VERBOSE_MODE" = yes ]
then
    echo
    if [ "$SV_NODE_LOCKED" = yes ]
    then
        echo "You have selected the node-locked licensing feature."
    else
        echo "You have selected the floating license feature."
    fi
    echo
fi

if grep "^FEATURE $license_feature" $SV_LIC_FILE_NAME >/dev/null
then
    sed -e "s?FEATURE $license_feature rational .*?FEATURE $license_feature rational $license_version $EXP_DATE $NUM_LICENSES $LICENSE_KEY \"$SV_DISPLAY\"$SV_NL_HOSTID?g"\
        $SV_LIC_FILE_NAME > /tmp/license.dat.$$
    cp /tmp/license.dat.$$ $SV_LIC_FILE_NAME
    rm /tmp/license.dat.$$
    echo "Updated FEATURE line in license file:"
else
    echo "FEATURE $license_feature rational $license_version $EXP_DATE $NUM_LICENSES $LICENSE_KEY \"$SV_DISPLAY\"$SV_NL_HOSTID" >> $SV_LIC_FILE_NAME
    echo "Added FEATURE line to license file:"
fi
grep "^FEATURE $license_feature" $SV_LIC_FILE_NAME

fmt_mesg "Now run start_lm as root to (re)start the license manager daemon."