Home > OS >  Shell how to collect the current time in the past five minutes this how to write?
Shell how to collect the current time in the past five minutes this how to write?

Time:10-23

The younger brother to ask, how in the shell to automatically take apache log log five minutes before the current time?

CodePudding user response:

Should be easy to

But for I can't write out
Said thoughts
Add the date time to timestamp format and then back again after 300 s

CodePudding user response:

With timing task crontab -e set shell script execution

CodePudding user response:

The date - d '5 minutes line' returns over the last five minutes
  • Related