Welcome to WebmasterWorld Guest from 18.104.22.168
Forum Moderators: bakedjake
I need to create a command for crontab containing this:
'cp access.log xxxxxx.log' where xxxxxx represents the output from date
in any format, preferably YYMMDD or YYYYMMDD.
I will set crontab to execute this daily at 23:59:59 saving the day's
access log before it is replaced at 00:00:00
Think you could steer me the right way here?
Now, I could do this with a perl/shell combo, but how would one write a script to do this in straight shell?
To use it in a shell script to set a variable, enclose it in backticks ( ` ) - ie:
cp access.log $DATE.log