hi guys,
i understand the link command or ln can create hard links (though not to directories) and there are also symbolic links.
but i dont understand the practicallity of this...when would you use a link, why would you...please help
j0n1n
Printable View
hi guys,
i understand the link command or ln can create hard links (though not to directories) and there are also symbolic links.
but i dont understand the practicallity of this...when would you use a link, why would you...please help
j0n1n
Here are a couple of real examples.
Symbolic links:
I have a bash script which is used by one of my conky scripts to get the alliteritive name of the kernel from the mskefile in the Linux source tree. Currently that is on my machine "linux-headers-3.7-5.towo.1-siduction-amd64". It would be a pain to update my script every time the kernel updates (and on Siduction it happens a lot!) so I use a symbolic link called linux which I update instead.
Hard Links
I use a piece of software called back-in-time to dump my data to an external drive every hour. Even with a 1.5TB drive it wouldn't take long to fill up and the drive would be constantly busy if it always copied everything. Instead what it does it copy everything the first time and then only actually copy files that are new or changed. It uses hard links to replicate the structure from the previous backup for files that haven't changed and still exist.