Skip to content

Eliminate Duplicate SDK Files #52182

Open
9 of 11 issues completed
Open

Description

@MichaelSimons

Eliminate duplicated files within the .NET SDK by utilizing hard links to reduce installation size and improve disk footprint.
By removing duplicate assemblies, we can reduce the SDK size by 35% (53 MB compressed, 140 MB on disk) on Linux x64.

Design: #51886

Current size status:

Platform SDK Artifact 10.0.105 Size (MB) 11.0 preview2 Size (MB) 11.0 preview3 Size (MB) 11.0 preview4 Size (MB) Current % Gain Notes
linux-x64 tarball 230 189 186 166 27.8%
linux-x64 deb 164 122 125 106 35.3% SDK package only
linux-x64 rpm 165 122 129 109 33.9% SDK package only
osx-x64 tarball 228 N/A 184 165 27.6%
osx-x64 pkg 223 N/A 184 165 26.0%
windows-x64 zip/tarball 289 (zip) N/A 226 (tarball) 208 (tarball) 28.0%

Sub-issues

Sub-issues

9 of 11 Issues completed
Loading 11 sub-issues

Activity

  1. added
    Epic
    on Dec 16, 2025
  2. added
    untriaged
    on Dec 16, 2025
  3. 3 remaining items

  4. tmds commented on Dec 16, 2025

    @tmds
    Member

    We're already replacing some files with symlinks.

    We tried hard links first and some tool in our build pipeline struggled with that: dotnet/source-build#3535 (comment).

    cc @omajid

  5. richlander commented on Feb 20, 2026

    @richlander
    Member

    It would be good to understand the expected MCR benefit.

  6. KirillOsenkov commented on Mar 11, 2026

    @KirillOsenkov
    Member

    I might be naive, but can we test this scenario: a build uses hardlinks, hardlinked file gets copied to output, then overwritten there by a file with the different contents, it changes the contents of the originals.

    If I'm right, this will be a disaster.

  7. KirillOsenkov commented on Mar 11, 2026

    @KirillOsenkov
    Member

    hmm, upon further thinking, hardlinks + double-writes would already wreak the same havoc, so this PR wouldn't make anything worse, actually.

  8. removed
    Epic
    on Aug 12, 2026
  9. changed the issue type fromtoon Aug 12, 2026
  10. MichaelSimons commented on Oct 16, 2026

    @MichaelSimons
    MemberAuthor

    Assigning to @marcpopMSFT to follow up on last two open items - decision on removing zip support and getting Azure DevOps to uptake tarballs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Area-acquisitionuntriaged

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions