int stripPos = logPattern.lastIndexOf(File.separatorChar);
if (!new File(logPattern).isAbsolute()) logPattern = new File(dataPath, logPattern).getAbsolutePath();
if (stripPos < 0) stripPos = logPattern.lastIndexOf(File.separatorChar);
File log = new File(logPattern.substring(0, stripPos));
if (!log.isAbsolute()) log = new File(dataPath, log.getPath());
if (!log.canRead()) log.mkdir();
// generating the root logger
final Logger logger = Logger.getLogger("");
logger.setUseParentHandlers(false);