"Count Hard-links in file" doesn't work?

The best solution for finding and removing duplicate files.
Post Reply
jackThom
Posts: 16
Joined: Tue May 27, 2014 7:21 am

"Count Hard-links in file" doesn't work?

Post by jackThom » Tue Feb 12, 2019 5:04 am

I brought this up a while back in this post, but the issue still persists in 4.1.1.

I can scan a folder, and deduplicate by creating hardlinks...
Then I scan the same folder and the "Count Hard-links in file" is not ticked. Yet the hard links I just created end up in the list anyway.

As I said in the old post, the only way I have ever able to have hardlinks not show up in the list is to tick that box to have them get counted, and then tick the "Exclude Hard-linked files" option. This accomplishes the objective of having them not show in the list, but would seem to defeat the purpose of having a supposed option to count them or not. (Also it would seem to take more time and CPU cycles to count them and then exclude them from the list than to simply avoid counting them in the first place.)

I assume since this has been the case on several versions, I'm not the only one with this issue...am I?

Or am I missing something?
User avatar
DigitalVolcano
Site Admin
Posts: 1107
Joined: Thu Jun 09, 2011 10:04 am

Re: "Count Hard-links in file" doesn't work?

Post by DigitalVolcano » Tue Feb 12, 2019 1:25 pm

It has to perform the count of hard-links in order to know which files to exclude - that is why the 'Exclude hard linked files' option is greyed out when 'Count' is not checked.
jackThom
Posts: 16
Joined: Tue May 27, 2014 7:21 am

Re: "Count Hard-links in file" doesn't work?

Post by jackThom » Tue Feb 12, 2019 2:05 pm

I'm not sure you understand (or maybe I don't).

To my mind, having an option whether to "Count Hard-links in file" would mean that the user can select whether they are counted at all, or not...no?

So it would seem to reason that if that box is not ticked, then hard links should not be counted, and should therefore definitely not show up in the duplicate list, correct?

It sounds like you're saying that hard links are counted regardless of whether the "Count Hard-links" option is ticked or not. If the behavior is the same regardless of whether it is activated or not, it would seem to be a switch that does nothing and has no use ...Which would beg the question, what is the point of that tickbox?
User avatar
DigitalVolcano
Site Admin
Posts: 1107
Joined: Thu Jun 09, 2011 10:04 am

Re: "Count Hard-links in file" doesn't work?

Post by DigitalVolcano » Tue Feb 12, 2019 3:26 pm

"Count" in this case means taking a file, and counting how many files are hard linked to it. Not count as in "This file counts as a duplicate- Include this file in the list"

Without doing this, we can't determine whether the file has any hard-links or not. If we don't count how many hard links it has, we can't exclude it (the second option). Hope this makes sense!
jackThom
Posts: 16
Joined: Tue May 27, 2014 7:21 am

Re: "Count Hard-links in file" doesn't work?

Post by jackThom » Wed Feb 13, 2019 1:03 am

Thanks for sticking with me on this and the prompt replies. I understand the point of excluding hardlinked files from the list and that they have to be counted before they could be excluded.

My question is simply what is the point of having that first tickbox?

I get that counting the hardlinks needs to be done if they are to be excluded, which is why the Count option needs to be ticked in order for the exclusion option to become tickable. But why not just have a single option to exclude (and therefore count) the hardlinks?

Or put another way, so far you've said the the Count tickbox needs to be ticked so that the Exclude option is no longer greyed out and can be used. Is that the only function the Count tickbox serves? To ungrey the Exclude option? Does the scan perform any differently, or does it produce any different results, or any more information viewable/usable to the user if only the Count tickbox is ticked, versus if it is not ticked?
User avatar
DigitalVolcano
Site Admin
Posts: 1107
Joined: Thu Jun 09, 2011 10:04 am

Re: "Count Hard-links in file" doesn't work?

Post by DigitalVolcano » Wed Feb 13, 2019 11:27 am

The count tickbox adds a hardlink count column to the duplicate file list (you may have to scroll to find it). This shows how many files are in that hardlink 'node'.
So using this you can see how many of the files in your list are hardlinks, without actually excluding them.
jackThom
Posts: 16
Joined: Tue May 27, 2014 7:21 am

Re: "Count Hard-links in file" doesn't work?

Post by jackThom » Thu Feb 14, 2019 3:21 am

Wow, never noticed that before. So does that just toggle the display of the number of hardlinks, or does it actually change the behavior of the scan? Would the scan theoretically be faster if count is disabled?
Post Reply