I have a directory and a symlink to it:
mkdir dir ln -s dir dir_symlink
I want to replace the symlink with the directory and the directory with the symlink. Is there a way to do that atomically (or very fast)? The directory is large.
dir should now be a symlink to the
dir_symlink directory (which is no longer a symlink, and contains the former contents of