remove some target files
move elastic check before OOM check