A symlink is a “pointer” to another file or directory, often referred to as a “shortcut” in the Windows world. If you delete the link, the target (original file) will not be deleted. If you want to create a symlink of a file or directory to somewhere else, you have to do that with the following command in a terminal:
ln -s <source> <target>
If you have, for example, moved your movies from your
home partition or folder to another partition (that is mounted here at
/mnt/movies), but you want to be able to access the movies-folder in your
home folder, the command would look like that:
ln -s /mnt/movies /home/<user>/movies
<user> would be replaced by your username.
From a user's perspective a hardlink is another copy of the same file in a different location. Technically speaking, that is not correct; in reality they are the same file which just appears to be in 2 places. This is important to know, because if you delete the link, the target will be deleted, too! So be careful with those. Usually a file has only one hardlink, though it is possible to have more.
To create a hardlink use the same syntax as for a symlink without the
ln <source> <target>
The manual page for
ln can be accessed using the command
However, the complete and authoritative documentation is available by: