当前位置:网站首页>The time difference between IIS7 log and system time is 8 hours. Use logparser to solve the problem

The time difference between IIS7 log and system time is 8 hours. Use logparser to solve the problem

2022-06-22 09:34:00 ootw

I won't say much about installation , Baidu on a lot of .

Just give an example , For example, now you want to check   today 2019 year 3 month 17 Japan   In the morning 8 Point to 9 Records between points , Results generated to  a.csv in , So the command says :

 

LogParser -o:csv "SELECT TO_LOCALTIME(TO_TIMESTAMP(date, time)) AS local-timestamp, s-port,cs-uri-stem,time-taken into a.csv FROM iislogs\u_ex*.log WHERE  TO_LOCALTIME(TO_TIMESTAMP(date, time))>TIMESTAMP('2019-03-17 08:00:00','yyyy-MM-dd hh:mm:ss' ) AND   TO_LOCALTIME(TO_TIMESTAMP(date, time))<TIMESTAMP('2019-03-17 09:00:00','yyyy-MM-dd hh:mm:ss' )   "

 

Then the result is all system time , No more human flesh 8 Hour , I didn't know before that this tool is hard calculated by the human brain , Every time I check IIS Logs all want to die .

If you have any questions, you are welcome to ask , I always do .

原网站

版权声明
本文为[ootw]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/02/202202220523181528.html