rotate files at a given minute or hourly interval