in reply to Emptying log file

The tricky part is that if a program is actively writing to the log file, it will keep writing to the same file even after it's renamed. If there are any long-running processes writing, you will need to signal them to close the old log and open a new one (many existing daemons will do this when sent a particular signal).

Another possibility is to use multilog, which deals with a lot of this automatically.