in reply to output issue....

....the data below that is not printing. the log file is
Please explain expected output.
Your regex validates only three lines of your log file, where as only two lines has your input string (cm_child.c).
You are further checking ($input_string eq $c_file), so the output.txt contains only two lines....
. If you remove this condition, then you will get all the data in output.txt file.