I installed a program that cleared my %PATH% (probably this NSIS bug).
I don't want to run System Restore because of other changes I made that I suspect will be reverted (for example, my backup configuration).

Is there a way to recover the PATH from a system restore point or any other good way?

  • Pull it out of your mentioned backup? Jul 7, 2013 at 16:30
  • @techie007 Unfortunately, one of the reasons I had to reconfigure the backup was because it was not backing up the registry.
    – yakatz
    Jul 7, 2013 at 21:36

2 Answers 2


See key

HKEY_LOCAL_MACHINE\SYSTEM\ControlSet00х\Control\Session Manager\Environment

command line, LastKnownGood:

REG Query "HKLM\SYSTEM\Select" /v LastKnownGood

get all ControlSet00х hive list:

REG Query "HKLM\SYSTEM\Select"

get Path at ControlSet002:

REG Query "HKLM\SYSTEM\ControlSet002\Control\Session Manager\Environment" /v Path

One way to do it, which I did just now, is to download a program called Process Hacker and examine the environment of a program that was running before whatever overwrote your PATH. Of course, that only works if you're still running a program that was open before your PATH got overwritten, but I was, so I was able to salvage it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.