0

I evaluate backup solution for common linux servers.

What happens if hard links are not preserved?

The only draw back I see: After the restore some MB more space is required. But this is no problem for my case.

1
  • Normally, there are reasons why a hardlink to a file exists, most of them beyond just saving a little bit of storage space. If you say that these reasons are irrelevant when doing a restore in your case, suit yourself, but I wouldn't consider this as generally recommendable.
    – Sven
    Mar 14, 2012 at 16:15

2 Answers 2

1

Leaving aside the space problem....In the past I've come across applications where a single program is accessed via different filenames (and gives different behaviour) based on hard links (a quick look in my /usr/bin, I see enscript, gcc, perl, pyhton, sudo, zipinfo and others with multiple links) which makes we wonder what might happen when I install package upgrades (which may expect the link to already be there).

1
  • Would package systems like apt/rpm get confused?
    – guettli
    Mar 14, 2012 at 19:45
0

If hard links aren't preserved, I imagine you would use excess disk space, because a hard link is a link to an inode, so essentially, you would be copying the data rather than linking to it.

Note that this does have effects on restoring from the backup. If your backup solution unlinks the file before restoring it, then you can wind up with multiple copies of the file:

Suppose File A and File B are hard links to the same file. You recover File A from backup, so the backup software removes File A then restores from backup. You now have File A matching the backed up data and File B living on disk with the data you probably wanted overwritten.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .