You are writing roughly the same amount of data to disk whether you wait to do it in batches or do it right away. So I don't really know how valid of a concern you really have here. It seems like you are solving a problem that doesn't really need to be solved.
Also what happens when something goes wrong 4 seconds into a 5 second log cycle? Do you lose all the log data for that 4 seconds (as well as your ability to trace the problem)? Do you lose timestamp granularity for the actual items being logged?
This seems like a step backwards in making your application easy to maintain.
If you are this worried about writing log files to disk, then perhaps consider a central log store that you can log to over UDP or similar.
You also must consider that this approach would require more memory utilization within your application to store the continually growing (until logged) log string. Depending on the amount of data being logged, this could potentially be a much more important consideration. Having to add application nodes because your code is not efficient with memory usage is likely MUCH more expensive than incremental cost of replacing hard drives at some theoretically more frequent rate would be.
Bottom line - memory is typically more expensive than storage.