If there is an error with CMD then you can't run CMD to fix the problem

If the issue continues to occur, copy the Autoexec.nt and Config.nt files from the Repair folder in Windows to the System folder. To do so, follow these steps:
1. Click Start, click Run, type c:\windows\repair, and then click OK.
2. Right-click autoexec.nt, and then click Copy.
3. Click Start, click Run, type c:\windows\system32, and then click OK.
4. Right-click anywhere in that folder, and then click Paste.
5. Right-click the Autoexect.nt file that you just copied, and then click Properties.
6. Click to select Read-Only, and then click OK.
7. Repeat steps 1 through 6 to copy the Config.nt file.
Kudos to Microsoft. 8-)