write dirpath, id; options.rootPath