Should I use Windows' hardlinks for backups?

2

I'm not exactly backing up but its a similar idea.

I have a few archives on my computer. They have exact copies of certain files (mostly 300k to 1.5MB). It's enough to take up a gigabyte. I am using Duplicate Cleaner. It has an option to use hardlinks. I plan on never modifying the file and they are all on the same disk (external 1 partition).

Should I use hardlinks or is there a problem I don‘t foresee?

user3109

Posted 2011-08-15T21:59:09.957

Reputation:

Have you looked into using version control software such as SVN? Even if it's not source code, it sounds like a good use of version control depending on the type of data – Earlz – 2011-08-15T22:11:06.093

@Earlz: They are all bin images.and i need the files to be in a specific folder. Its not exactly backup. The files are not related to eachother and there are thousands of folders – None – 2011-08-15T23:22:27.623

Answers

0

You shouldn't use hard links for backups. Hardlinks are just a reference to the 'real' file so you can't use them to create multiple copies. However, I think that, in your case, we are not talking about backups.

If you want to maintain just one copy of each file (in order to save disk space), but you need to access that file from different folders, then you should use hardlinks. Just keep in mind that if something happens to the original file, you will not have another copy.

nmat

Posted 2011-08-15T21:59:09.957

Reputation: 1 513

Your statement "You shouldn't use hard links for backups" isn't technically correct. Apple Time Machine uses hard links (or symlinks) as part of its backup process. I think what you mean is that creating a hard link from the original file does not in itself produce a backup - that is true. But hard links can come in handy when you want to store multiple backups from different time periods and not have to store multiple backup copies of an identical file (saving disk space). Time Machine does this beautifully! – Simon East – 2019-09-12T09:59:14.587

2

No because hardlinks only give you an alternative NAME for the file, not a different copy. If you modify the file from any of the file name, the old content will be lost.

What you need is a copy-on-write behaviour. If you want an file system-level solution., you may use "previous versions", a.k.a. "system protection/restore" for this purpose; however, you don't have much control over it. You maybe better off using a backup/version control solution that can do delta backup.

billc.cn

Posted 2011-08-15T21:59:09.957

Reputation: 6 821

I mentioned i plan on never writing/changing the file. Its a bunch of media/bins – None – 2011-08-15T23:23:02.460

1Still, in this case, you only have one copy of the file, so there's no backup at all. You only get a different name, which is only useful if the threat pattern is accidental deletion or renaming. – billc.cn – 2011-08-15T23:26:04.343

If they're all on the same partition, there's no backup anyway, so hardlinks can be useful anyway. – afrazier – 2011-08-16T00:02:34.253