Score:0

Windows hardlinks - why it consumes same space as original file

gb flag

Im using finddupe tool to de-duplicate files and save some space on HDD. But checking before and after operation I cant see any free space released - see below.

Can somebody advise what is wrong here ?

D:\TEMP\1>dir
30.09.2021  12:50        89 028 146 polycom-410-copy.zip
30.09.2021  12:50        89 028 146 polycom-410.zip
               2 File(s)    178 056 292 bytes
               2 Dir(s)  117 821 751 296 bytes free

D:\TEMP\1>finddupe -hardlink d:\temp\1 Duplicate: 'd:\temp\1\polycom-410-copy.zip' With:      'd:\temp\1\polycom-410.zip'
    Created hardlink

Files:   178056 kBytes in     2 files Dupes:    89028 kBytes in     1 files

D:\TEMP\1>dir  Volume in drive D is BACKUP  Volume Serial Number is B66C-A894

 Directory of D:\TEMP\1
30.09.2021  12:50        89 028 146 polycom-410-copy.zip
30.09.2021  12:50        89 028 146 polycom-410.zip
               2 File(s)    178 056 292 bytes
               2 Dir(s)  117 910 781 952 bytes free


D:\TEMP\1>finddupe -listlink d:\temp\1


Hardlink group, 2 of 2 hardlinked instances found in search tree:   "d:\temp\1\polycom-410-copy.zip"   "d:\temp\1\polycom-410.zip"

Number of hardlink groups found: 1
in flag
Total size of files, and used spaced is different things, As mentioned in answer(s), used space did shrink (seen by looking at free space change)
Score:4
in flag

What makes you think there was no space released?

# Before:
117 821 751 296 bytes free
# After:
117 910 781 952 bytes free
# Difference:
     89 030 656
# Your file size:
     89 028 146

You released pretty exactly the space of one file.

Tilman Schmidt avatar
bd flag
To expand, the total size reported by `dir` does not account for hardlinks, so it doesn't really report the *consumed* space.
gb flag
Gosh I'm blind! I've looked wrong numbers!
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.