; Generally, it is currently impossible to use hard links for directories. Once used, messages such as operation ; not permitted will appear. ; ; Directories are not allowed to use hard links. The reason is generally that hard links are required in directories ; If used, it means that all files and subdirectories in the directory must be processed. Hard link action, ; The result level has been separated from the hard link situation of simple general file projects. ; ; Next, once hard link is allowed in the directory, if you create a file ; and directory in the directory, this means that the files in these two directories must be processed as hard link situation, then the entire ; environment will become very complicated.
http://askubuntu.com/questions/210741/why-are-hard-links-not-allowed-for-directories
http://bbs.chinaunix.net/thread-2212171-1-1.html
http://unix.stackexchange.com/questions/22394/why-are-hard-links-to-directories-not-allowed-in-unix-linux
You have to post the error message, it may be a permissions issue
Because after you ln . xxx, then rm -rf xxx will enter the D state.