#!/bin/sh cd /opt/ltp >/dev/null partitioning_done=false # Perform partitioning, if not already done if [ ! -d /sys/fs/cgroup/cpuset/rt ]; then partrt create 0x$(list2mask --nohz) partitioning_done=true fi logname=`date +"%Y_%m_%d_%H_%M_%S"`".log" ./runltp -n -i 5 -p -d /tmp -l $logname -f partrt_nohz_full if [ ! -d ./results ]; then echo "FAIL: no result found" $partitioning_done && partrt undo exit 1 fi cat ./results/$logname | while read line do resultLine=`echo $line | grep -c -E "PASS|FAIL"` if [ $resultLine -eq 1 ]; then testcase=`echo $line | awk '{print $1}'` result=`echo $line | awk '{print $2}'` echo "$result: $testcase" fi done $partitioning_done && partrt undo