close files as they advance
Added partition size setting