{"id":55748,"date":"2023-06-23T20:19:34","date_gmt":"2023-06-23T14:49:34","guid":{"rendered":"http:\/\/198.58.113.91\/blog\/?p=55748"},"modified":"2024-10-18T22:26:00","modified_gmt":"2024-10-18T16:56:00","slug":"powershell-closes-machine-config-parser-error","status":"publish","type":"post","link":"https:\/\/www.winhelponline.com\/blog\/powershell-closes-machine-config-parser-error\/","title":{"rendered":"PowerShell Closes Immediately When Launched; Machine.Config Parser Error"},"content":{"rendered":"<p>When you run PowerShell.exe, the PowerShell window may open and close immediately before you can read the error message. Running PowerShell.exe from an existing Command Prompt window, or opening PowerShell via <a href=\"https:\/\/www.winhelponline.com\/blog\/set-default-terminal-windows-11\/\">Windows Terminal<\/a> may show the error message:<!--more--><\/p>\n<pre class=\"err\">The shell cannot be started. A failure occurred during initialization:\nThe type initializer for 'System.Net.ServicePointManager' threw an exception.\n\n[process exited with code 4294901760 (0xffff0000)]\nYou can now close this terminal with Ctrl+D, or press Enter to restart.<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-55754\" src=\"https:\/\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/06\/machine.config_parser_error_2.png\" alt=\"The shell cannot be started. The type initializer for 'System.Net.ServicePointManager' threw an exception\" width=\"750\" height=\"276\" \/><\/p>\n<p>Some .NET apps may throw the following error:<\/p>\n<pre class=\"err\">Configuration parser error\n\nError parsing C:\\Windows\\Microsoft.NET\\Framework64\\v4.0.30319\\config\\machine.config\n\nParser returned error 0xC00CE556.<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-55753\" src=\"https:\/\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/06\/machine.config_parser_error_1.png\" alt=\"machine.config parser error 0xC00CE556\" width=\"413\" height=\"172\" \/><\/p>\n<h2>Cause<\/h2>\n<p>The above errors occur if the file <strong>machine.config<\/strong> is corrupt. This configuration file is presumably used by many .NET-based apps.<\/p>\n<div class=\"rp\"><strong>RELATED:<\/strong> <a href=\"https:\/\/www.winhelponline.com\/blog\/internal-powershell-error-80070002\/\">PowerShell closes abruptly. Internal Windows PowerShell error 80070002<\/a><\/div>\n<h2>Resolution<\/h2>\n<p>To resolve the issue of the PowerShell window closing immediately after the launch and the Parser error 0xC00CE556, replace &#8220;Machine.Config&#8221; with a fresh copy using these steps.<\/p>\n<ul>\n<li>Open the following folder:\n<pre>C:\\Windows\\Microsoft.NET\\Framework64\\v4.0.30319\\Config<\/pre>\n<div class=\"qt\"><strong>Note:<\/strong> The folder path is mentioned in the error message above. Alternatively, you can find the correct folder name (version) by reading the &#8220;<code><strong>RuntimeVersion<\/strong><\/code>&#8221; registry value in the following registry key:<\/p>\n<pre>HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\PowerShell\\3\\PowerShellEngine<\/pre>\n<p>-or-<\/p>\n<ol>\n<li>Open the folder &#8220;<code>C:\\Windows\\Microsoft.NET\\<\/code>&#8220;<\/li>\n<li>Open the folder named &#8220;<code>Framework<\/code>&#8221; or &#8220;<code>Framework64<\/code>&#8221; (depending upon your <a href=\"https:\/\/www.winhelponline.com\/blog\/find-windows-10-build-version-edition-bit\/\">OS bitness<\/a>).<\/li>\n<li>Select specific version folder e.g., &#8220;<code>v4.0.30319<\/code>&#8220;<\/li>\n<li>Double-click the &#8220;<code>Config<\/code>&#8221; folder.<\/li>\n<li>The &#8220;<code>Config<\/code>&#8221; folder will contain the files, &#8220;<code>Machine.config<\/code>&#8221; and &#8220;<code>Machine.config.default<\/code>&#8220;.<\/li>\n<\/ol>\n<\/div>\n<\/li>\n<li>In the above folder, delete the file named <code><strong>machine.config<\/strong><\/code>.<\/li>\n<li>There should be another file named <code><strong>machine.config.default<\/strong><\/code> in that folder. Make a copy of <code><strong>machine.config.default<\/strong><\/code>.<\/li>\n<li>Name the copy as <code><strong>machine.config<\/strong><\/code>.<\/li>\n<\/ul>\n<div class=\"qt\">\n<h4>Using Command Prompt<\/h4>\n<p>If you wish to accomplish the above steps using Command Prompt or Batch files, here are the commands:<\/p>\n<pre class=\"cmd\">cd \/d C:\\Windows\\Microsoft.NET\\Framework64\\v4.0.30319\\Config<\/pre>\n<pre class=\"cmd\">del machine.config<\/pre>\n<pre class=\"cmd\">copy machine.config.default machine.config<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-55756\" src=\"https:\/\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/06\/machine.config_parser_error_fix_cmd.png\" alt=\"machine.config fix file\" width=\"747\" height=\"201\" \/>\n<\/div>\n<div class=\"rp\"><strong>RELATED:<\/strong> <a href=\"https:\/\/www.winhelponline.com\/blog\/cant-open-cmd-after-uninstalling-python-anaconda\/\">Can\u2019t Open CMD.exe After Uninstalling Python\/Anaconda; Exit Code 1<\/a><\/div>\n<p>That&#8217;s it! Open PowerShell. You should no longer get the error.<\/p>\n<p>If the above steps don&#8217;t help, see if the following article helps.<\/p>\n<p><a href=\"https:\/\/www.winhelponline.com\/blog\/internal-powershell-error-80070002\/\">PowerShell closes abruptly. Internal Windows PowerShell error 80070002<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>When you run PowerShell.exe, the PowerShell window may open and close immediately before you can read the error message. Running PowerShell.exe from an existing Command Prompt window, or opening PowerShell via Windows Terminal may show the error message:<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_post_was_ever_published":false},"categories":[8,869],"tags":[191,396],"class_list":["post-55748","post","type-post","status-publish","format-standard","hentry","category-windows-10","category-windows-11","tag-error-messages","tag-powershell"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":76808,"url":"https:\/\/www.winhelponline.com\/blog\/internal-powershell-error-80070002\/","url_meta":{"origin":55748,"position":0},"title":"[Fix] Internal Windows PowerShell error 80070002","author":"Ramesh","date":"October 18, 2024","format":false,"excerpt":"When you open Windows Terminal (PowerShell), the following error may occur: Internal Windows PowerShell error. Loading managed Windows PowerShell failed with error 80070002. If you run PowerShell.exe, the window may close abruptly. RELATED: PowerShell Closes Immediately When Launched; Machine.Config Parser Error Cause This happens if the file \"Microsoft.PowerShell.ConsoleHost.dll\" is missing\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":76820,"url":"https:\/\/www.winhelponline.com\/blog\/powershell-error-v4-net-framework-not-installed\/","url_meta":{"origin":55748,"position":1},"title":"PowerShell: Version v4.0.30319 of the .NET Framework is not installed","author":"Ramesh","date":"October 19, 2024","format":false,"excerpt":"When you open Windows Terminal (PowerShell), the following error may occur: Version v4.0.30319 of the .NET Framework is not installed and it is required to run version 3 of Windows PowerShell. If you run PowerShell.exe, the window may close immediately. Running the .NET Framework Repair tool or removing and reinstalling\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":".net installroot fix - powershell closes","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2024\/10\/installroot_registry_fix.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2024\/10\/installroot_registry_fix.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2024\/10\/installroot_registry_fix.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2024\/10\/installroot_registry_fix.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":80414,"url":"https:\/\/www.winhelponline.com\/blog\/powershell-license-ok-message-at-startup\/","url_meta":{"origin":55748,"position":2},"title":"PowerShell &#8220;License OK&#8221; message at Startup","author":"Ramesh","date":"March 9, 2026","format":false,"excerpt":"When you log in to your account, PowerShell may automatically open and display the message \"License OK\" in the console. Here's the full output. Running the environment check. Please wait... License OK Running the environment check. Please wait... License OK IsPublic IsSerial Name BaseType -------- -------- ---- -------- True False\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"powershell license ok error at startup","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2026\/03\/powershell-license-ok-error.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2026\/03\/powershell-license-ok-error.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2026\/03\/powershell-license-ok-error.png?resize=525%2C300&ssl=1 1.5x"},"classes":[]},{"id":28839,"url":"https:\/\/www.winhelponline.com\/blog\/cant-open-cmd-after-uninstalling-python-anaconda\/","url_meta":{"origin":55748,"position":3},"title":"Can&#8217;t Open CMD.exe After Uninstalling Python\/Anaconda; Exit Code 1","author":"Ramesh","date":"September 29, 2022","format":false,"excerpt":"After uninstalling Python\/Anaconda on your Windows computer, Command Prompt may not open. When you run cmd.exe, it flashes on the screen and immediately quits. Also, running DISM and SFC (to repair corrupt system files), repairing Windows installation, and running a thorough malware scan may not fix the issue. Also, when\u2026","rel":"","context":"In &quot;Windows&quot;","block_context":{"text":"Windows","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/"},"img":{"alt_text":"vscode cmd.exe error 1","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2022\/09\/vscode-cmd-error-code-1.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":79729,"url":"https:\/\/www.winhelponline.com\/blog\/netfx3-update-error-0x800f0922\/","url_meta":{"origin":55748,"position":4},"title":"[Fix] .NET Framework 3.5 Installation Error 0x800F0922","author":"Ramesh","date":"October 30, 2025","format":false,"excerpt":"When you install the latest cumulative update or the .NET Framework 3.5 using OptionalFeatures.exe, the installation may rollback with the error code 0x800F0922. When the latest cumulative update fails, the CBS log may contain the following entry: Error CSI 000001f9 (F) Done with generic command 2; CreateProcess returned 0, CPAW\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":10236,"url":"https:\/\/www.winhelponline.com\/blog\/task-scheduler-service-is-not-available-will-attempt-to-reconnect\/","url_meta":{"origin":55748,"position":5},"title":"Task Scheduler service is not available; will attempt to reconnect","author":"Ramesh","date":"July 8, 2019","format":false,"excerpt":"When you launch the Task Scheduler window, or when a specific task is run, the following error may pop up: Task Scheduler service is not available. Task Scheduler will attempt to reconnect to it. This error may occur although the Task Scheduler service is running. Task Scheduler service is not\u2026","rel":"","context":"In &quot;Windows&quot;","block_context":{"text":"Windows","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/"},"img":{"alt_text":"ask scheduler service is not available. Task scheduler will try to reconnect to it","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2019\/07\/task-scheduler-service-not-available-2.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2019\/07\/task-scheduler-service-not-available-2.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2019\/07\/task-scheduler-service-not-available-2.png?resize=525%2C300&ssl=1 1.5x"},"classes":[]}],"_links":{"self":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts\/55748","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/comments?post=55748"}],"version-history":[{"count":0,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts\/55748\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/media?parent=55748"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/categories?post=55748"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/tags?post=55748"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}