Performance issue with parsing large log files (~5gb) using awk, grep, sed

后端 未结 4 621
孤城傲影
孤城傲影 2021-02-06 04:47

I am currently dealing with log files with sizes approx. 5gb. I\'m quite new to parsing log files and using UNIX bash, so I\'ll try to be as precise as possible. While searchi

4条回答
  •  说谎
    说谎 (楼主)
    2021-02-06 05:12

    As to multi-line programs on the command line,

    $ awk 'BEGIN { print "File\tOwner" }
    > { print $8, "\t", \
    > $3}
    > END { print " - DONE -" }' infile > outfile
    

    Note the single quotes.

提交回复
热议问题