You didn't really specify how the log was being created. And posting the question in the "Database" forums does serve to confuse us on how the logs are being stored.
If the file is being created by code in the website use [man]filesize[/man] to check the the files size each time a new log is added to the file and once it reaches the limit the code can archive the file and start a new log file.
Now if the error logging is configured by php.ini, as is often the case, you can turn it off and use the Error Handling functions to do custom logging of errors.
Another option is to use Cron Jobs, these are tasks that can be run at regular intervals. So use them to check the logs file size and then archive it as needed.
If you are logging errors in the database and need to archive logs that is as simple as copying the old log records to another table and then deleting the logs from the first table.