.netgarbage-collection

Where Is Machine.Config?


I want to apply a change so That I can use Server GC settings for my C# 3.5 app - I can do that by editing the machine.config file.

The only problem is I do not know where that is.

How can I find the path of this file in a repeatable way across a number of different machines


Solution

  • 32-bit

    %windir%\Microsoft.NET\Framework\[version]\config\machine.config
    

    64-bit

    %windir%\Microsoft.NET\Framework64\[version]\config\machine.config 
    

    [version] should be equal to v1.0.3705, v1.1.4322, v2.0.50727 or v4.0.30319.

    v3.0 and v3.5 just contain additional assemblies to v2.0.50727 so there should be no config\machine.config. v4.5.x and v4.6.x are stored inside v4.0.30319.