A typical application of shell script - filter out specific content and judge the time difference and locate the abnormal part

Let’s look at our scenario first:
After a large number of startups, we found that the number of startups of one of the boards was inconsistent with the number of startups of the power supply. Looking for it, the delay is too long, because my saved log has about 10 million lines. So what should we do at this time? Fix that today. Welcome to join the discussion.

run script

if [ -e /root/runcount.log ]
then
	runcount=`cat /root/runcount.log | wc -l`
	runcount=`

Guess you like

Origin blog.csdn.net/mainmaster/article/details/130846996