Reconstruct the directory to avoid some security problem.