#!/bin/sh
################################################################################
##                                                                            ##
## Copyright (c) International Business Machines  Corp., 2001                 ##
##                                                                            ##
## This program is free software;  you can redistribute it and#or modify      ##
## it under the terms of the GNU General Public License as published by       ##
## the Free Software Foundation; either version 2 of the License, or          ##
## (at your option) any later version.                                        ##
##                                                                            ##
## This program is distributed in the hope that it will be useful, but        ##
## WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY ##
## or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License   ##
## for more details.                                                          ##
##                                                                            ##
## You should have received a copy of the GNU General Public License          ##
## along with this program;  if not, write to the Free Software               ##
## Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA    ##
##                                                                            ##
################################################################################
# File: runltp
#
# Description:  This script can be used to the tests in the LTP test suite
#
# Authors:      Manoj Iyer - manjo@mail.utexas.edu
#               Robbe Williamson - robbiew@us.ibm.com
#
# History:      Oct 07 2003 - Modified - Manoj Iyer
#               - use functions
#               - clean up on script exit
#               - error checking etc.
#
#               Oct 08 2003 - Modified - Manoj Iyer
#               - fixed bug in creating results directory
#               - all checks should be enlclosed in " " to avoid bash error
#               - exit with error if ltp-pan is not found in pan directory
#
#               Jul 22 2007 - Modified - Ricardo Salveti de Araujo
#               - added support to put more then one file at CMDLINE (-f)
#               - added a new option, that the user can pass the address of
#               the command file, and it'll use wget to get it (-w)
#               - now -s does the grep at the selected command files (default,
#               -f or -w)
#
#               Jul 23 2007 - Modified - Ricardo Salveti de Araujo
#               - added flag to get the command file that has all failed tests
#
#               Sep 11 2007 - Modified - Subrata Modak
#               - added option to create Failed File if it is not an absolute path
#               - added option to create Output File if it is not an absolute path
#               - added option to create Failed File compulsory, even if user has not mentioned it
#
#               Sep 14 2007 - Modified - Ricardo Salveti de Araujo
#               - cleaning and removing duplicated code
#
#               Oct 27 2007 - Modified - Ricardo Salveti de Araujo and Subrata Modak
#               - better ways to integrate "ltp/tools/genload/stress" with "ltp/runltp"
#               Nov 24 2007 - Modified - Subrata Modak
#               - Added a new option to generate output in HTML format also. Also retaining
#                 the original test format
#               Nov 28 2007 - Modified - Subrata Modak
#               - Added a new option to mail back LTP reports
#               May 19 2008 - Modified - Subrata Modak
#               - Added capability for default Log file generation
#		Aug 17 2009 - Modified - Subrata Modak
#		- Added Fault Injection generation Capability through -F Option
#
#################################################################################



setup()
{
    cd `dirname $0` || \
    {
        echo "FATAL: unable to change directory to $(dirname $0)"
        exit 1
    }
    export LTPROOT=${PWD}
    export TMPBASE="/tmp"
    export PATH="${PATH}:${LTPROOT}/testcases/bin"

    export LTP_DEV_FS_TYPE="ext2"

    [ -d "$LTPROOT/testcases/bin" ] ||
    {
        echo "FATAL: LTP not installed correctly"
        echo "INFO:  Follow directions in INSTALL!"
        exit 1
    }

    [ -e "$LTPROOT/bin/ltp-pan" ] ||
    {
        echo "FATAL: Test suite driver 'ltp-pan' not found"
        echo "INFO:  Follow directions in INSTALL!"
        exit 1
    }
}

version_of_ltp()
{
    cat "$LTPROOT/Version"
    exit 0
}

usage()
{
    cat <<-EOF >&2

    usage: ${0##*/} [ -a EMAIL_TO ] [ -c NUM_PROCS ] [ -C FAILCMDFILE ] [ -T TCONFCMDFILE ]
    [ -d TMPDIR ] [ -D NUM_PROCS,NUM_FILES,NUM_BYTES,CLEAN_FLAG ] -e [ -f CMDFILES(,...) ]
    [ -g HTMLFILE] [ -i NUM_PROCS ] [ -l LOGFILE ] [ -m NUM_PROCS,CHUNKS,BYTES,HANGUP_FLAG ]
    -N -n [ -o OUTPUTFILE ] -p -q -Q [ -r LTPROOT ] [ -s PATTERN ] [ -t DURATION ]
    -v [ -w CMDFILEADDR ] [ -x INSTANCES ] [ -b DEVICE ] [-B LTP_DEV_FS_TYPE]
	[ -F LOOPS,PERCENTAGE ] [ -z BIG_DEVICE ] [-Z  LTP_BIG_DEV_FS_TYPE]

    -a EMAIL_TO     EMAIL all your Reports to this E-mail Address
    -c NUM_PROCS    Run LTP under additional background CPU load
                    [NUM_PROCS = no. of processes creating the CPU Load by spinning over sqrt()
                                 (Defaults to 1 when value)]
    -C FAILCMDFILE  Command file with all failed test cases.
    -T TCONFCMDFILE Command file with all test cases that are not fully tested.
    -d TMPDIR       Directory where temporary files will be created.
    -D NUM_PROCS,NUM_FILES,NUM_BYTES,CLEAN_FLAG
                    Run LTP under additional background Load on Secondary Storage (Seperate by comma)
                    [NUM_PROCS   = no. of processes creating Storage Load by spinning over write()]
                    [NUM_FILES   = Write() to these many files (Defaults to 1 when value 0 or undefined)]
                    [NUM_BYTES   = write these many bytes (defaults to 1GB, when value 0 or undefined)]
                    [CLEAN_FLAG  = unlink file to which random data written, when value 1]
    -e              Prints the date of the current LTP release
    -f CMDFILES     Execute user defined list of testcases (separate with ',')
	-F LOOPS,PERCENTAGE Induce PERCENTAGE Fault in the Kernel Subsystems, and, run each test for LOOPS loop
    -g HTMLFILE     Create an additional HTML output format
    -h              Help. Prints all available options.
    -i NUM_PROCS    Run LTP under additional background Load on IO Bus
                    [NUM_PROCS   = no. of processes creating IO Bus Load by spinning over sync()]
    -K DMESG_LOG_DIR
			Log Kernel messages generated for each test cases inside this directory
    -l LOGFILE      Log results of test in a logfile.
    -m NUM_PROCS,CHUNKS,BYTES,HANGUP_FLAG
                    Run LTP under additional background Load on Main memory (Seperate by comma)
                    [NUM_PROCS   = no. of processes creating main Memory Load by spinning over malloc()]
                    [CHUNKS      = malloc these many chunks (default is 1 when value 0 or undefined)]
                    [BYTES       = malloc CHUNKS of BYTES bytes (default is 256MB when value 0 or undefined) ]
                    [HANGUP_FLAG = hang in a sleep loop after memory allocated, when value 1]
	-M CHECK_TYPE
		[CHECK_TYPE=1 => Full Memory Leak Check tracing children as well]
		[CHECK_TYPE=2 => Thread Concurrency Check tracing children as well]
		[CHECK_TYPE=3 => Full Memory Leak & Thread Concurrency Check tracing children as well]
    -N              Run all the networking tests.
    -n              Run LTP with network traffic in background.
    -o OUTPUTFILE   Redirect test output to a file.
    -p              Human readable format logfiles.
    -q              Print less verbose output to screen. This implies
                    not logging start of the test in kernel log.
    -Q              Don't log start of test in kernel log.
    -r LTPROOT      Fully qualified path where testsuite is installed.
    -R              Randomize test order.
    -s PATTERN      Only run test cases which match PATTERN.
    -S SKIPFILE     Skip tests specified in SKIPFILE
    -t DURATION     Execute the testsuite for given duration. Examples:
                      -t 60s = 60 seconds
                      -t 45m = 45 minutes
                      -t 24h = 24 hours
                      -t 2d  = 2 days
    -I ITERATIONS   Execute the testsuite ITERATIONS times.
    -w CMDFILEADDR  Uses wget to get the user's list of testcases.
    -x INSTANCES    Run multiple instances of this testsuite.
    -b DEVICE       Some tests require an unmounted block device
                    to run correctly.
    -B LTP_DEV_FS_TYPE The file system of test block devices.
    -z BIG_DEVICE   Some tests require a big unmounted block device
                    to run correctly.
    -Z  LTP_BIG_DEV_FS_TYPE The file system of the big device



    example: ${0##*/} -c 2 -i 2 -m 2,4,10240,1 -D 2,10,10240,1 -p -q  -l /tmp/result-log.$$ -o /tmp/result-output.$$ -C /tmp/result-failed.$$ -d ${PWD}


	EOF
exit 0
}

main()
{
    local CMDFILES=
    local PRETTY_PRT=
    local ALT_DIR_OUT=0
    local ALT_DIR_RES=0
    local ALT_HTML_OUT=0
    local ALT_EMAIL_OUT=0
    local ALT_DMESG_OUT=0
    local RUN_NETEST=0
    local RUN_REPEATED=0
    local QUIET_MODE=
    local NO_KMSG=
    local NETPIPE=0
    local GENLOAD=0
    local MEMSIZE=0
    local DURATION=
    local CMDFILEADDR=
    local FAILCMDFILE=
    local TCONFCMDFILE=
    local INJECT_KERNEL_FAULT=
    local INJECT_KERNEL_FAULT_PERCENTAGE=
    local INJECT_FAULT_LOOPS_PER_TEST=
    local VALGRIND_CHECK=
    local VALGRIND_CHECK_TYPE=
    local LOGFILE_NAME=
    local LOGFILE=
    local OUTPUTFILE_NAME=
    local OUTPUTFILE=
    local HTMLFILE_NAME=
    local HTMLFILE=
    local DMESG_DIR=
    local EMAIL_TO=
    local TAG_RESTRICT_STRING=
    local PAN_COMMAND=
    local RANDOMRUN=0
    local DEFAULT_FILE_NAME_GENERATION_TIME=`date +"%Y_%m_%d-%Hh_%Mm_%Ss"`
    local scenfile=

    version_date=$(cat "$LTPROOT/Version")

    while getopts a:b:B:c:C:T:d:D:ef:F:g:hi:I:K:l:m:M:No:pqQr:Rs:S:t:T:w:x:z:Z: arg
    do  case $arg in
        a)  EMAIL_TO=$OPTARG
            ALT_EMAIL_OUT=1;;
        c)
            NUM_PROCS=$(($OPTARG))
            if   [ "$NUM_PROCS" -eq 0 ]; then
                # User Did not Define the Value ,or, User Defined Zero,
                # hence, prevent from creating infinite processes
                NUM_PROCS=1
            fi
            $LTPROOT/testcases/bin/genload --cpu $NUM_PROCS >/dev/null 2>&1 &
            GENLOAD=1 ;;

        C)
            case $OPTARG in
            /*)
                FAILCMDFILE="-C $OPTARG" ;;
            *)
                FAILCMDFILE="-C $LTPROOT/output/$OPTARG"
                ALT_DIR_OUT=1 ;;
            esac ;;

        T)
            case $OPTARG in
            /*)
                TCONFCMDFILE="-T $OPTARG" ;;
            *)
                TCONFCMDFILE="-T $LTPROOT/output/$OPTARG"
                ALT_DIR_OUT=1 ;;
            esac ;;

        d)  # convert the user path to absolute path.
            export TMPBASE=$(readlink -f ${OPTARG}) ;;

        D)  NUM_PROCS=1; NUM_FILES=1; NUM_BYTES=$((1024 * 1024 * 1024)); CLEAN_FLAG=0
            ARGUMENT_LIST=$OPTARG
            TOTAL_ARGUMENTS=1
            for ARGUMENT in `echo "$ARGUMENT_LIST" | tr ',' ' '`
            do
                case $TOTAL_ARGUMENTS in
                    1) NUM_PROCS="$ARGUMENT" ;;
                    2) NUM_FILES="$ARGUMENT" ;;
                    3) NUM_BYTES="$ARGUMENT" ;;
                    4) CLEAN_FLAG="$ARGUMENT" ;;
                esac
                TOTAL_ARGUMENTS=`expr $TOTAL_ARGUMENTS + 1`
            done
            # just to get the default values if the user passed 0
            if [ "$NUM_PROCS" -eq 0 ]; then
                NUM_PROCS=1
            fi
            if [ "$NUM_FILES" -eq 0 ]; then
                NUM_FILES=1
            fi
            if [ "$NUM_BYTES" -eq 0 ]; then
                NUM_BYTES=$((1024 * 1024 * 1024))
            fi
            if [ "$CLEAN_FLAG" -ne 1 ]; then
                CLEAN_FLAG=0
            fi
            if [ "$CLEAN_FLAG" -eq 1 ]; then
                # Do not unlink file in this case
                $LTPROOT/testcases/bin/genload --hdd $NUM_PROCS --hdd-files \
                    $NUM_FILES --hdd-bytes $NUM_BYTES >/dev/null 2>&1 &
            else
                # Cleanup otherwise
                $LTPROOT/testcases/bin/genload --hdd $NUM_PROCS --hdd-files \
                    $NUM_FILES --hdd-bytes $NUM_BYTES --hdd-noclean >/dev/null 2>&1 &
            fi
            GENLOAD=1;;

        e)  # Print out the version of LTP
            version_of_ltp
	    ;;
        f)  # Execute user defined set of testcases.
            # Can be more then one file, just separate it with ',', like:
            # -f nfs,commands,/tmp/testfile
            CMDFILES=$OPTARG;;
	F)	INJECT_KERNEL_FAULT=1
		#Seperate out the NO_OF_LOOPS & FAULT_PERCENTAGE
		INJECT_FAULT_LOOPS_PER_TEST=`echo $OPTARG |cut -d',' -f1 | tr -d '\n' | tr -d ' '`
		INJECT_KERNEL_FAULT_PERCENTAGE=`echo $OPTARG |cut -d',' -f2 | tr -d '\n' | tr -d ' '`
		if [ ! $INJECT_FAULT_LOOPS_PER_TEST ]; then
			echo "Loops not properly defined. Resorting to default 5..."
			export INJECT_FAULT_LOOPS_PER_TEST=5
		fi
		if [ ! $INJECT_KERNEL_FAULT_PERCENTAGE ]; then
			echo "Fault Persentage not properly defined. Resorting to default 10..."
			export INJECT_KERNEL_FAULT_PERCENTAGE=10
		fi;;
        g)  HTMLFILE_NAME="$OPTARG"
            case $OPTARG in
            /*)
                HTMLFILE="$OPTARG";;
            *)
                HTMLFILE="$LTPROOT/output/$OPTARG";;
            esac
            ALT_DIR_OUT=1
            ALT_HTML_OUT=1;;
        h)  usage;;

        i)
            NUM_PROCS=$(($OPTARG))
            if   [ "$NUM_PROCS" -eq 0 ]; then
                # User Did not Define the Value ,or, User Defined Zero,
                # hence, prevent from creating infinite processes
                NUM_PROCS=1
            fi
            $LTPROOT/testcases/bin/genload --io $NUM_PROCS >/dev/null 2>&1 &
            GENLOAD=1 ;;

        K)
	    case $OPTARG in
        	   /*)
			DMESG_DIR="$OPTARG-dmesg-output-`echo $$-``date +%X | tr -d ' '`";;
	            *)
		        DMESG_DIR="$LTPROOT/output/$OPTARG-dmesg-output-`echo $$-``date +%X | tr -d ' '`";;
	    esac
            mkdir -p $DMESG_DIR
            ALT_DMESG_OUT=1;;
        l)
            LOGFILE_NAME="$OPTARG"
            case $OPTARG in
            /*)
                LOGFILE="-l $OPTARG" ;;
            *)
                LOGFILE="-l $LTPROOT/results/$OPTARG"
                ALT_DIR_RES=1 ;;
            esac ;;

        m)  NUM_PROCS=1; CHUNKS=1; BYTES=$((256 * 1024 * 1024)); HANGUP_FLAG=0
            ARGUMENT_LIST=$OPTARG
            TOTAL_ARGUMENTS=1
            for ARGUMENT in `echo "$ARGUMENT_LIST" | tr ',' ' '`
            do
                case $TOTAL_ARGUMENTS in
                    1) NUM_PROCS="$ARGUMENT" ;;
                    2) CHUNKS="$ARGUMENT" ;;
                    3) BYTES="$ARGUMENT" ;;
                    4) HANGUP_FLAG="$ARGUMENT" ;;
                esac
                TOTAL_ARGUMENTS=`expr $TOTAL_ARGUMENTS + 1`
            done
            # just to get the default values if the user passed 0
            if [ "$NUM_PROCS" -eq 0 ]; then
                NUM_PROCS=1
            fi
            if [ "$CHUNKS" -eq 0 ]; then
                CHUNKS=1
            fi
            if [ "$BYTES" -eq 0 ]; then
                BYTES=$((256 * 1024 * 1024))
            fi
            if [ "$HANGUP_FLAG" -ne 1 ]; then
                HANGUP_FLAG=0
            fi
            if [ "$HANGUP_FLAG" -eq 1 ]; then
                # Hang in a Sleep loop after memory allocated
                $LTPROOT/testcases/bin/genload --vm $NUM_PROCS --vm-chunks \
                    $CHUNKS --vm-bytes $BYTES --vm-hang >/dev/null 2>&1 &
            else
                # Otherwise Do not Hangup
                $LTPROOT/testcases/bin/genload --vm $NUM_PROCS --vm-chunks \
                    $CHUNKS --vm-bytes $BYTES >/dev/null 2>&1 &
            fi
            GENLOAD=1;;
	M)
		VALGRIND_CHECK=1
		VALGRIND_CHECK_TYPE="$OPTARG";;

        N)  RUN_NETEST=1;;

        o)  OUTPUTFILE_NAME="$OPTARG"
            case $OPTARG in
            /*)
                OUTPUTFILE="-o $OPTARG";;
            *)
                OUTPUTFILE="-o $LTPROOT/output/$OPTARG"
                ALT_DIR_OUT=1 ;;
            esac ;;

        p)  PRETTY_PRT="-p";;

        q)  QUIET_MODE="-q";;

        Q)  NO_KMSG="-Q";;

        r)  LTPROOT=$OPTARG;;

        R)  RANDOMRUN=1;;

        s)  TAG_RESTRICT_STRING=$OPTARG;;

	S)  case $OPTARG in
            /*)
                SKIPFILE=$OPTARG;;
            *)
                SKIPFILE="$LTPROOT/$OPTARG";;
            esac ;;

        t)  # In case you want to specify the time
            # to run from the command line
            # (2m = two minutes, 2h = two hours, etc)
            DURATION="-t $OPTARG" ;;

        I)  # In case you want the testcases to runsequentially RUN_REPEATED times
            RUN_REPEATED=$OPTARG;;

        w)  CMDFILEADDR=$OPTARG;;

        x)  # number of ltp's to run
            cat <<-EOF >&1
            WARNING: The use of -x can cause unpredictable failures, as a
                     result of concurrently running multiple tests designed
                     to be ran exclusively.
                     Pausing for 10 seconds..."
	EOF
            sleep 10
            INSTANCES="-x $OPTARG";;
        b) DEVICE=$OPTARG;;
        B) LTP_DEV_FS_TYPE=$OPTARG;;
        z) BIG_DEVICE=$OPTARG;;
        Z) BIG_DEVICE_FS_TYPE=$OPTARG;;
        \?) usage;;
        esac
    done

    ## It would be nice to create a default log file even if the user has not mentioned
    if [ ! "$LOGFILE" ]; then                                ## User has not mentioned about Log File name
       LOGFILE_NAME="$DEFAULT_FILE_NAME_GENERATION_TIME"
       LOGFILE="-l $LTPROOT/results/LTP_RUN_ON-$LOGFILE_NAME.log"
       ALT_DIR_RES=1
       PRETTY_PRT="-p"
    fi

    ## It would be nice if a Failed File is compulsorily created (gives User better Idea of Tests that failed)

    if [ ! "$FAILCMDFILE" ]; then                            ## User has not mentioned about Failed File name
         ALT_DIR_OUT=1
         if [ ! "$OUTPUTFILE" ]; then		             ## User has not mentioned about Output File name either
            if [ ! "$LOGFILE" ]; then                        ## User has not mentioned about Log File name either
               FAILED_FILE_NAME="$DEFAULT_FILE_NAME_GENERATION_TIME"
               FAILCMDFILE="-C $LTPROOT/output/LTP_RUN_ON-$FAILED_FILE_NAME.failed"
            else					     ## User Fortunately wanted a log file,
               FAILED_FILE_NAME=`basename $LOGFILE_NAME`     ## Extract log file name and use it to construct Failed file name
               FAILCMDFILE="-C $LTPROOT/output/LTP_RUN_ON-$FAILED_FILE_NAME.failed"
            fi
         else                                                ## User Fortunately wanted a Output file
               FAILED_FILE_NAME=`basename $OUTPUTFILE_NAME`  ## Extract output file name and use it to construct Failed file name
               FAILCMDFILE="-C $LTPROOT/output/LTP_RUN_ON-$FAILED_FILE_NAME.failed"
         fi
    fi

    if [ ! "$TCONFCMDFILE" ]; then
         ALT_DIR_OUT=1
         if [ ! "$OUTPUTFILE" ]; then
            if [ ! "$LOGFILE" ]; then
               TCONF_FILE_NAME="$DEFAULT_FILE_NAME_GENERATION_TIME"
               TCONFCMDFILE="-T $LTPROOT/output/LTP_RUN_ON-${TCONF_FILE_NAME}.tconf"
            else
               TCONF_FILE_NAME=`basename $LOGFILE_NAME`
               TCONFCMDFILE="-T $LTPROOT/output/LTP_RUN_ON-${TCONF_FILE_NAME}.tconf"
            fi
         else
               TCONF_FILE_NAME=`basename $OUTPUTFILE_NAME`
               TCONFCMDFILE="-T $LTPROOT/output/LTP_RUN_ON-${TCONF_FILE_NAME}.tconf"
         fi
    fi

    if [ "$ALT_HTML_OUT" -eq 1 ] ; then                      ## User wants the HTML version of the output
       QUIET_MODE=""                                         ## Suppressing this guy as it will prevent generation of proper output
                                                             ## which the HTML parser will require
       if [ ! "$OUTPUTFILE" ]; then                          ## User has not mentioned about the Outputfile name, then we need to definitely generate one
          OUTPUTFILE_NAME="$DEFAULT_FILE_NAME_GENERATION_TIME"
          OUTPUTFILE="-o $LTPROOT/output/LTP_RUN_ON-$OUTPUTFILE_NAME.output"
          ALT_DIR_OUT=1
          if [ ! "$HTMLFILE" ] ; then                        ## User has not mentioned HTML File name, We need to create one
             HTMLFILE_NAME=`basename $OUTPUTFILE_NAME`
             HTMLFILE="$LTPROOT/output/$HTMLFILE_NAME.html"
          fi
       fi
    fi

    # If we need, create the output directory
    [ "$ALT_DIR_OUT" -eq 1 ] && \
    {
        [ ! -d $LTPROOT/output ] && \
        {
           echo "INFO: creating $LTPROOT/output directory"
           mkdir -p $LTPROOT/output || \
           {
               echo "ERROR: failed to create $LTPROOT/output"
               exit 1
            }
        }
    }
    # If we need, create the results directory
    [ "$ALT_DIR_RES" -eq 1 ] && \
    {
        echo "INFO: creating $LTPROOT/results directory"
        [ ! -d $LTPROOT/results ] && \
        {
           mkdir -p $LTPROOT/results || \
           {
               echo "ERROR: failed to create $LTPROOT/results"
               exit 1
            }
        }
    }

    # Added -m 777 for tests that call tst_tmpdir() and try to
    #  write to it as user nobody
    mkdir -m 777 -p $TMPBASE || \
    {
        echo "FATAL: Unable to make temporary directory $TMPBASE"
        exit 1
    }
    # use mktemp to create "safe" temporary directories
    export TMPTEMPLATE="${TMPBASE}/ltp-XXXXXXXXXX"
    TMP=`mktemp -d $TMPTEMPLATE` || \
    {
        echo "FATAL: Unable to make temporary directory: $TMP"
        exit 1
    }
    export TMP
    # To be invoked by tst_tmpdir()
    # write to it as user nobody
    export TMPDIR=$TMP

    chmod 777 $TMP || \
    {
      echo "unable to chmod 777 $TMP ... aborting"
      exit 1
    }

    cd $TMP || \
    {
      echo "could not cd ${TMP} ... exiting"
      exit 1
    }

    [ -n "$INSTANCES" ] && \
    {
      INSTANCES="$INSTANCES -O ${TMP}"
    }

    [ "$RUN_NETEST" -eq 1 ] && \
    {
        [ -z "$RHOST" ] || [ -z "$PASSWD" ] && \
        {
            [ -z "$RHOST" ] && \
            {
                printf "INFO: Enter RHOST = 'name of the remote host machine'"
                printf "\n-> "
                read RHOST
            }

            [ -z "$PASSWD" ] && \
            {
                printf "\nINFO: "
                printf "Enter PASSWD = 'root passwd of the remote host machine'"
                printf "\n-> "
                read PASSWD
            }
            export RHOST=$RHOST
            export PASSWD=$PASSWD
            echo "WARNING: security of $RHOST may be compromised"
        }
    }

    # If user does not provide a command file select a default set of testcases
    # to execute.
    if [ -z "$CMDFILES" ] && [ -z "$CMDFILEADDR" ]
    then
        cat <<-EOF >&1

    INFO: no command files were provided. Will execute the following
          runtest scenario files:

`cat $LTPROOT/scenario_groups/default | tr '\012' ' '`

	EOF

	SCENARIO_LISTS="$LTPROOT/scenario_groups/default"
        if [ "$RUN_NETEST" -eq 1 ]; then
            SCENARIO_LISTS="$SCENARIO_LISTS $LTPROOT/scenario_groups/network"
        fi

    # DO NOT INDENT/DEDENT!
        if [ -n "$SCENARIO_LISTS" ]; then
            # Insurance to make sure that the first element in the pipe
            # completed successfully.
            cat_ok_sentinel=$TMP/cat_ok.$$
	    (cat $SCENARIO_LISTS && touch "$cat_ok_sentinel") | \
                while read scenfile; do

                    scenfile=${LTPROOT}/runtest/$scenfile

                    # Skip over non-existent scenario files; things are
                    # robust enough now that the build will fail if these
                    # files don't exist.
                    [ -f "$scenfile" ] || continue

                    cat $scenfile >> "$TMP/alltests" || {
                        echo "FATAL: unable to append to command file"
                        rm -Rf "$TMP"
                        rm -f "$cat_ok_sentinel"
                        exit 1
                    }

                done

            rm -f "$cat_ok_sentinel"

        fi
    # ^^DO NOT INDENT/DEDENT!^^

    fi

    [ -n "$CMDFILES" ] && \
    {
        for scenfile in `echo "$CMDFILES" | tr ',' ' '`
        do
            [ -f "$scenfile" ] || scenfile="$LTPROOT/runtest/$scenfile"
            cat "$scenfile" >> ${TMP}/alltests || \
            {
                echo "FATAL: unable to create command file"
                rm -Rf "$TMP"
                exit 1
            }
        done
    }

    [ -n "$CMDFILEADDR" ] && \
    {
        wget -q "${CMDFILEADDR}" -O ${TMP}/wgetcmdfile
        if [ $? -ne 0 ]; then
            echo "FATAL: error while getting the command file with wget (address $CMDFILEADDR)"
            exit 1
        fi
        cat "${TMP}/wgetcmdfile" >> ${TMP}/alltests || \
        {
            echo "FATAL: unable to create command file"
            exit 1
        }
    }

    # The fsx-linux tests use the SCRATCHDEV environment variable as a location
    # that can be reformatted and run on.  Set SCRATCHDEV if you want to run
    # these tests.  As a safeguard, this is disabled.
    unset SCRATCHDEV
    [ -n "$SCRATCHDEV" ] && \
    {
         cat ${LTPROOT}/runtest/fsx >> ${TMP}/alltests ||
         {
             echo "FATAL: unable to create  fsx-linux tests command file"
             exit 1
         }
    }

    # If enabled, execute only test cases that match the PATTERN
    if [ -n "$TAG_RESTRICT_STRING" ]
    then
        mv -f ${TMP}/alltests ${TMP}/alltests.orig
	    grep $TAG_RESTRICT_STRING ${TMP}/alltests.orig > ${TMP}/alltests #Not worth checking return codes for this case
    fi

    # Blacklist or skip tests if a SKIPFILE was specified with -S
    if [ -n "${SKIPFILE}" ]; then
        for test_name in $(awk '{print $1}' "${SKIPFILE}"); do
            case "${test_name}" in \#*) continue;; esac
            sed -i "/\<${test_name}\>/c\\${test_name} exit 32;" alltests
        done
    fi

    # check for required users and groups
    ${LTPROOT}/IDcheck.sh || \
    {
        echo "WARNING: required users and groups not present"
        echo "WARNING: some test cases may fail"
    }

    # display versions of installed software
    [ -z "$QUIET_MODE" ] && \
    {
        ${LTPROOT}/ver_linux || \
        {
            echo "WARNING: unable to display versions of software installed"
            exit 1
    }
    }

    set_block_device

    # here even if the user don't specify a big block device, we
    # also don't create the big block device.
    if [ -z "$BIG_DEVICE" ]; then
        echo "no big block device was specified on commandline."
        echo "Tests which require a big block device are disabled."
        echo "You can specify it with option -z"
    else
        export LTP_BIG_DEV=$BIG_DEVICE
        if [ -z "$BIG_DEVICE_FS_TYPE" ]; then
            export LTP_BIG_DEV_FS_TYPE="ext2"
        else
            export LTP_BIG_DEV_FS_TYPE=$BIG_DEVICE_FS_TYPE
        fi
    fi

    if [ $RUN_REPEATED -gt 1 ]; then # You need to specify at least more than 1 sequential run, else it runs default
         echo "PAN will run these test cases $RUN_REPEATED times....."
         echo "Test Tags will be Prepended with ITERATION NO.s....."
         inc=1
         sed -e '/^$/ d' -e 's/^[ ,\t]*//' -e '/^#/ d' < ${TMP}/alltests > ${TMP}/alltests.temp ##This removes all newlines, leading spaces, tabs, #
         sed 's/^[0-9,a-z,A-Z]*/'"$inc"'_ITERATION_&/' < ${TMP}/alltests.temp > ${TMP}/alltests ## .temp is kept as Base file
         while [ $inc -lt $RUN_REPEATED ] ; do
               inc=`expr $inc + 1`
               sed 's/^[0-9,a-z,A-Z]*/'"$inc"'_ITERATION_&/' < ${TMP}/alltests.temp >> ${TMP}/alltests #Keep appending with Iteration No.s
         done
    fi

    if [ "$RANDOMRUN" != "0" ]; then
        sort -R ${TMP}/alltests -o ${TMP}/alltests
    fi

    [ ! -z "$QUIET_MODE" ] && { echo "INFO: Test start time: $(date)" ; }
    PAN_COMMAND="${LTPROOT}/bin/ltp-pan $QUIET_MODE $NO_KMSG -e -S $INSTANCES $DURATION -a $$ \
    -n $$ $PRETTY_PRT -f ${TMP}/alltests $LOGFILE $OUTPUTFILE $FAILCMDFILE $TCONFCMDFILE"
    echo "COMMAND:    $PAN_COMMAND"
    if [ ! -z "$TAG_RESTRICT_STRING" ] ; then
      echo "INFO: Restricted to $TAG_RESTRICT_STRING"
    fi
    #$PAN_COMMAND #Duplicated code here, because otherwise if we fail, only "PAN_COMMAND" gets output

    ## Display the Output/Log/Failed/HTML file names here
    printf "LOG File: "
    echo $LOGFILE | cut -b4-

    if [ "$OUTPUTFILE" ]; then
       printf "OUTPUT File: "
       echo $OUTPUTFILE | cut -b4-
    fi

    printf "FAILED COMMAND File: "
    echo $FAILCMDFILE | cut -b4-

   printf "TCONF COMMAND File: "
   echo $TCONFCMDFILE | cut -b4-

    if [ "$HTMLFILE" ]; then
       echo "HTML File: $HTMLFILE"
    fi

    echo "Running tests......."
    test_start_time=$(date)

	# User wants testing with Kernel Fault Injection
	if [ $INJECT_KERNEL_FAULT ] ; then
		#See if Debugfs is mounted, and
		#Fault Injection Framework available through Debugfs
		use_faultinjection=true
		for debug_subdir in \
			fail_io_timeout \
			fail_make_request \
			fail_page_alloc \
			failslab \
		; do
			if [ -d "/sys/kernel/debug/$debug_subdir" ]
			then
				use_faultinjection=true
				break
			fi
		done
		if $use_faultinjection; then
			#If atleast one of the Framework is available
			#Go ahead to Inject Fault & Create required
			#Command Files for LTP run
			echo Running tests with Fault Injection Enabled in the Kernel...
			awk -v LOOPS=$INJECT_FAULT_LOOPS_PER_TEST \
				-v PERCENTAGE=$INJECT_KERNEL_FAULT_PERCENTAGE \
				-f ${LTPROOT}/bin/create_kernel_faults_in_loops_and_probability.awk \
				${TMP}/alltests > ${TMP}/alltests.tmp
			cp ${TMP}/alltests.tmp ${TMP}/alltests
			rm -rf ${TMP}/alltests.tmp
		else
			echo Fault Injection not enabled in the Kernel..
			echo Running tests normally...
		fi
	fi

	## Valgrind Check will work only when Kernel Fault Injection is not expected,
	## We do not want to test Faults when valgrind is running
	if [ $VALGRIND_CHECK ]; then
		if [ ! $INJECT_KERNEL_FAULT ]; then
			which valgrind || VALGRIND_CHECK_TYPE=XYZ
			case $VALGRIND_CHECK_TYPE in
			[1-3])
				awk -v CHECK_LEVEL=$VALGRIND_CHECK_TYPE \
					-f ${LTPROOT}/bin/create_valgrind_check.awk \
					${TMP}/alltests $VALGRIND_CHECK_TYPE > \
					${TMP}/alltests.tmp
				cp ${TMP}/alltests.tmp ${TMP}/alltests
				rm -rf ${TMP}/alltests.tmp
				;;
			*)
				echo "Invalid Memory Check Type, or, Valgrind is not available"
				;;
			esac
		fi
	fi

	if [ $ALT_DMESG_OUT -eq 1 ] ; then
		#We want to print dmesg output for each test,lets do the trick inside the script
		echo Enabling dmesg output logging for each test...
		awk -v DMESG_DIR=$DMESG_DIR \
			-f ${LTPROOT}/bin/create_dmesg_entries_for_each_test.awk \
			${TMP}/alltests > ${TMP}/alltests.tmp
		cp ${TMP}/alltests.tmp ${TMP}/alltests
		rm -rf ${TMP}/alltests.tmp
	fi
    # Some tests need to run inside the "bin" directory.
    cd "${LTPROOT}/testcases/bin"
    "${LTPROOT}/bin/ltp-pan" $QUIET_MODE $NO_KMSG -e -S $INSTANCES $DURATION -a $$ -n $$ $PRETTY_PRT -f ${TMP}/alltests $LOGFILE $OUTPUTFILE $FAILCMDFILE $TCONFCMDFILE

    if [ $? -eq 0 ]; then
      echo "INFO: ltp-pan reported all tests PASS"
      VALUE=0
      export LTP_EXIT_VALUE=0;
    else
      echo "INFO: ltp-pan reported some tests FAIL"
      VALUE=1
      export LTP_EXIT_VALUE=1;
    fi
    cd ..
    echo "LTP Version: $version_date"

	# $DMESG_DIR is used to cache messages obtained from dmesg after a test run.
	# Proactively reap all of the 0-byte files in $DMESG_DIR as they have zero value
	# and only clutter up the filesystem.

	if [ $ALT_DMESG_OUT -eq 1 ] ; then
		if ! find "$DMESG_DIR" -size 0 -exec rm {} + ; then
			echo "cd to $DMESG_DIR failed: $?"
		fi
		if [ -n "$(ls "$DMESG_DIR")" ] ; then
			echo "Kernel messages were generated for LTP tests $version_date"
		else
			echo "No Kernel messages were generated for LTP tests $version_date"
		fi
	fi

    if [ "$ALT_HTML_OUT" -eq 1 ] ; then        #User wants the HTML output to be created, it then needs to be generated
       export LTP_VERSION=$version_date
       export TEST_START_TIME="$test_start_time"
       export TEST_END_TIME="$(date)"
       OUTPUT_DIRECTORY=`echo $OUTPUTFILE | cut -c4-`
       LOGS_DIRECTORY="$LTPROOT/results"
       export TEST_OUTPUT_DIRECTORY="$LTPROOT/output"
       export TEST_LOGS_DIRECTORY=$LOGS_DIRECTORY
       echo "Generating HTML Output.....!!"
       ( perl $LTPROOT/bin/genhtml.pl $LTPROOT/bin/html_report_header.txt test_start test_end test_output execution_status $OUTPUT_DIRECTORY  > $HTMLFILE; )
       echo "Generated HTML Output.....!!"
       echo "Location: $HTMLFILE";

    fi

    if [ "$ALT_EMAIL_OUT" -eq 1 ] ; then                      ## User wants reports to be e-mailed
       if [ [ ! "$HTMLFILE_NAME" ] -o [ ! "$OUTPUTFILE_NAME" ] -o [ ! "$LOGFILE_NAME" ] ] ; then
          ##User does not have output/logs/html-output, nothing to be mailed in this situation
          echo "Nothing to be mailed here...."
       else
           TAR_FILE_NAME=LTP_RUN_$version_date$DEFAULT_FILE_NAME_GENERATION_TIME.tar
           if [ "$HTMLFILE_NAME" ] ; then                          ## HTML file Exists
              if [ "$ALT_HTML_OUT" -ne 1 ] ; then                  ## The HTML file path is absolute and not $LTPROOT/output
                 mkdir -p $LTPROOT/output                          ## We need to create this Directory
                 cp $HTMLFILE_NAME $LTPROOT/output/
              fi
           fi
           if [ "$OUTPUTFILE_NAME" ] ; then                        ## Output file exists
              if [ "$ALT_DIR_OUT" -ne 1 ] ; then                   ## The Output file path is absolute and not $LTPROOT/output
                 mkdir -p $LTPROOT/output                          ## We need to create this Directory
                 cp $OUTPUTFILE_NAME $LTPROOT/output/
              fi
           fi
           if [ "$LOGFILE_NAME" ] ; then                           ## Log file exists
              if [ "$ALT_DIR_RES" -ne 1 ] ; then                   ## The Log file path is absolute and not $LTPROOT/results
                 mkdir -p $LTPROOT/results                         ## We need to create this Directory
                 cp $LOGFILE_NAME $LTPROOT/results/
              fi
           fi
           if [ -d $LTPROOT/output ] ; then
              tar -cf  ./$TAR_FILE_NAME $LTPROOT/output
              if [ $? -eq 0 ]; then
                 echo "Created TAR File: ./$TAR_FILE_NAME successfully, added $LTPROOT/output"
              else
                 echo "Cannot Create TAR File: ./$TAR_FILE_NAME for adding $LTPROOT/output"
              fi
           fi
           if [ -d $LTPROOT/results ] ; then
              tar -uf ./$TAR_FILE_NAME $LTPROOT/results
              if [ $? -eq 0 ]; then
                 echo "Updated TAR File: ./$TAR_FILE_NAME successfully, added $LTPROOT/results"
              else
                 echo "Cannot Update TAR File: ./$TAR_FILE_NAME for adding $LTPROOT/results"
              fi
           fi
           if [ -e $LTPROOT/nohup.out ] ; then                     ## If User would have Chosen nohup to do ltprun
              tar -uf ./$TAR_FILE_NAME $LTPROOT/nohup.out
              if [ $? -eq 0 ]; then
                 echo "Updated TAR File: ./$TAR_FILE_NAME successfully, added $LTPROOT/nohup.out"
              else
                 echo "Cannot Update TAR File: ./$TAR_FILE_NAME for adding $LTPROOT/nohup.out"
              fi
           fi
           gzip ./$TAR_FILE_NAME                                     ## gzip this guy
           if [ $? -eq 0 ]; then
              echo "Gunzipped TAR File: ./$TAR_FILE_NAME"
           else
              echo "Cannot Gunzip TAR File: ./$TAR_FILE_NAME"
           fi
           if [ -e /usr/bin/mutt ] ; then                          ## This is a better mail client than others
              echo "Starting mailing reports to: $EMAIL_TO, file: ./$TAR_FILE_NAME.gz"
              mutt -a ./$TAR_FILE_NAME.gz -s "LTP Reports on $test_start_time" $EMAIL_TO < /dev/null
              if [ $? -eq 0 ]; then
                 echo "Reports Successfully mailed to: $EMAIL_TO"
              else
                 echo "Reports cannot be mailed to: $EMAIL_TO"
              fi
           else ## Use our Ageold mail program
              echo "Starting mailing reports to: $EMAIL_TO, file: ./$TAR_FILE_NAME.gz"
              uuencode ./$TAR_FILE_NAME.gz $TAR_FILE_NAME.gz | mail  $EMAIL_TO -s "LTP Reports on $test_start_time"
              if [ $? -eq 0 ]; then
                 echo "Reports Successfully mailed to: $EMAIL_TO"
              else
                 echo "Reports cannot be mailed to: $EMAIL_TO"
              fi
           fi
       fi
    fi

    [ ! -z "$QUIET_MODE" ] && { echo "INFO: Test end time: $(date)" ; }

    [ "$GENLOAD" -eq 1 ] && { killall -9 genload  >/dev/null 2>&1; }
    [ "$NETPIPE" -eq 1 ] && { killall -9 NPtcp  >/dev/null 2>&1; }

    [ "$ALT_DIR_OUT" -eq 1 ] || [ "$ALT_DIR_RES" -eq 1 ] && \
    {
    cat <<-EOF >&1

       ###############################################################

            Done executing testcases.
            LTP Version:  $version_date
       ###############################################################

	EOF
    }
    exit $VALUE
}

create_block()
{
    #create a block device
    dd if=/dev/zero of=${TMP}/test.img bs=1024 count=262144 >/dev/null 2>&1
    if [ $? -ne 0 ]; then
        echo "Failed to create loopback device image, please check disk space and re-run"
        return 1
    else
        ##search for an unused loop dev
        LOOP_DEV=$(losetup -f)
        if [ $? -ne 0 ]; then
            echo "no unused loop device is found"
            return 1
        else
            ##attach the created file to loop dev.
            losetup $LOOP_DEV ${TMP}/test.img
            if [ $? -ne 0 ]; then
                echo "losetup failed to create block device"
                return 1
            fi
            DEVICE=$LOOP_DEV
            return 0
        fi
    fi
}

set_block_device()
{
    if [ -z "$DEVICE" ]; then
        create_block
        if [ $? -ne 0 ]; then
            echo "no block device was specified on commandline."
            echo "Block device could not be created using loopback device"
            echo "Tests which require block device are disabled."
            echo "You can specify it with option -b"
	else
            export LTP_DEV=$DEVICE
        fi
    else
        export LTP_DEV=$DEVICE
    fi
}

cleanup()
{
    [ "$LOOP_DEV" ] && losetup -d $LOOP_DEV
    rm -rf ${TMP}
}


LTP_SCRIPT="$(basename $0)"

if [ "$LTP_SCRIPT" = "runltp" ]; then
    trap "cleanup" 0
    setup
    main "$@"
fi
