# This script first makes a file then appends to a file. The reason it has to append to a file is a sed command is involved # Which will then make the appended to file executable. Then it is executed with dump_eric and it's output is appended to another file # Because without this file being executed the next script "calltrace.awk" can't read the output to draw out a msisdn # Calltrace.awk finds the msisdn (phone number) you are looking for. # Script Written by David M. Hagens #! /usr/bin/ksh echo "Please choose the name corelating to your search:\n"; echo "'calltracedate.abbazabba' for a date search"; echo "'calltracetime.abbazabba' for time search"; echo " or"; echo "'calltracenarrowtime.abbazabba' for a more specific search\n"; echo "Which trace file do you want:>\c " read ANSWER if [ "$ANSWER" = "calltracedate.abbazabba" ]; then sed -e 's/^/\dump_eric /' calltracedate.abbazabba >> calltrace2.abbazabba; chmod 777 calltrace2.abbazabba; ./calltrace2.abbazabba >> output.abbazabba; calltrace.awk; break; elif [ "$ANSWER" = "calltracetime.abbazabba" ]; then sed -e 's/^/\dump_eric /' calltracetime.abbazabba >> calltrace2.abbazabba; chmod 777 calltrace2.abbazabba; ./calltrace2.abbazabba >> output.abbazabba; calltrace.awk; break; else sed -e 's/^/\dump_eric /' calltracenarrowtime.abbazabba >> calltrace2.abbazabba; chmod 777 calltrace2.abbazabba; ./calltrace2.abbazabba >> output.abbazabba; calltrace.awk; break fi