whatis hard-link
Hard Link
Also known as: ln
An additional directory entry pointing at the same inode as an existing file, so one set of data has two equal names.
What Is a Hard Link in Linux?
Unlike a symlink, a hard link is not a pointer to another name; both names are equally real. Deleting one leaves the data intact until the last link is removed. The link count appears in the second column of ls -l.
Hard links cannot span filesystems or point to directories. Backup tools like rsync with --link-dest use them to make snapshots where unchanged files take no extra space.
Example
ln report.txt report-copy.txt
ls -li report* Learn more about Hard Link
- Symlinks vs Hard Links Explained: The ln Command and How Links Actually Work Symbolic links point to a path; hard links point to the data itself. Understanding the difference explains why one survives renames, why the other breaks, and what ln -s actually creates.
- rsync Explained: Flags, Trailing Slashes, and Not Deleting Your Data How the delta algorithm works, what the trailing slash actually changes, why --delete needs --dry-run first, and the flag combinations for backups, mirrors, and migrations.