scripts for log parsing