To elaborate on what JavaFan said, log4perl, to my knowledge, has no built-in mechanism for actually rotating files. While you may have set-up the log4perl config to handle rotation, you will need another script or utility to actually perform the file movement. logrotate is one such utility. You could also write your own shell/perl script to do what you want, and set-up cron directly to run it.
fnord
Comment on Re: How can I roll over my logfiles automatically at midnight?
That's true. Log::Log4perl
doesn't have a builtin method to handle rotation; however, the module's author explicitly recommends Log::Dispatch::FileRotate
in the FAQ.
So the OP was on the right track:).