Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F102911829
parse_output_file
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Tue, Feb 25, 10:38
Size
1 KB
Mime Type
text/x-shellscript
Expires
Thu, Feb 27, 10:38 (1 d, 21 h)
Engine
blob
Format
Raw Data
Handle
24450086
Attached To
R3704 elastic-yarn
parse_output_file
View Options
#!/bin/bash
INFILE=$1
if [ "$$INFILE" == "" ]
then
echo "Give param"
exit
fi
echo "SLS printed runtime: `grep -o 'runTime=[^,]*,' $INFILE | grep -o '[0-9.]*'`"
st_time=`grep 'Registering app' $INFILE | awk '{print $2}'`
echo "Job start: $st_time"
end_time=`grep 'Application Finished - Succeeded' $INFILE | awk '{print $2}'`
echo "Job end: $end_time"
c_002=`grep '000002' $INFILE | head -n 1 | awk '{print $2}'`
echo "First allocated container: $c_002"
echo "End minus Start:" `~/date-diff-ms "$end_time" "$st_time"`
echo "End minus c_002:" `~/date-diff-ms "$end_time" "$c_002"`
for container in `cat $INFILE | grep -o 'container_[0-9_]*' | sort | uniq`
do
c_st=`grep $container $INFILE | grep 'ACQUIRED to RUNNING' | awk '{print $2}'`
c_end=`grep $container $INFILE | grep 'RUNNING to COMPLETED' | awk '{print $2}'`
c_node=`grep $container $INFILE | grep capacity | grep -v release | grep -o 'node[0-9:]*'`
echo $container `~/date-diff-ms "$c_end" "$c_st"` $c_st $c_end $c_node
done
Event Timeline
Log In to Comment