Click to See Complete Forum and Search --> : How to avoid log fragmentation?


riotw7
August 17th, 2009, 04:02 AM
Hi,

We have a project with N+1 components, each creating a log file in parallel.
On each boot the partition(NTFS) where the logs are created is checked with chkdsk /R.
These logs generate a lot of fragmentation as you can imagine, thus the chkdsk gets really slow.

What's the best method to avoid this fragmentation in your opinion?

TIA,

MrViggy
August 17th, 2009, 01:32 PM
The best way would probably be to create a single, larger, log file, instead of multiple little ones.

Viggy

riotw7
August 19th, 2009, 09:49 AM
Thanks... Thought of that... but this would generate two issues:

1) logs which come from otherwise rather autonomous entities would all be entangled and would require filtering before they would be readable (this is minor issue- we can make grepping a habit :) )

2) we also have a Hypersonic database which writes it's data in a similar manner. And even though having just two files competing for clusters would statistically give a bit better fragmentation, the partition would still become rather fragmented over time...

darwen
August 23rd, 2009, 06:13 AM
How about logging to a dababase? This needn't be a server-based solution - you can use SQL server compact as an embedded database.

Darwen.