protected FileChannel nextFile(String folder) throws IOException {
String fileName = folder + "/" + xlogNameFormat.format(lsn + 1L) + ".xlog";
new File(fileName).createNewFile();
FileChannel channel = new FileOutputStream(fileName, true).getChannel();
writer = new XLogWriter(channel);
return channel;
}