我的机器出现了一个神秘问题。我发现 Windows 7 机器上的路径定期被设置为
%SystemRoot%\system32\WindowsPowerShell\v1.0\;C:\Chocolatey\bin;C:\GnuWin\bin;C:\sysinternals;C:\Program Files (x86)\CVSNT\
我必须重新启动 explorer.exe 并重新打开控制台窗口才能解决此问题。我的系统路径HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment
是
C:\Perl64\site\bin;C:\Perl64\bin;C:\Program Files\NirSoft;c:\Program Files (x86)\bind9;C:\Program Files (x86)\CollabNet\Subversion Client;C:\Program Files (x86)\PHP;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Program Files (x86)\Common Files\Roxio Shared\DLLShared;C:\Program Files (x86)\Common Files\Roxio Shared\9.0\DLLShared;C:\Program Files\7-Zip;C:\Program Files (x86)\KDiff3;C:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\;C:\Program Files\Microsoft SQL Server\100\Tools\Binn\;C:\Program Files\Microsoft SQL服务器\100\DTS\Binn\;c:\Program Files (x86)\CollabNet\Subversion Client\;C:\Program Files\Dell\DW WLAN 卡;C:\Program Files (x86)\GnuWin32\bin;C:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\;C:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files\Apache Software Foundation\apache-ant-1.8.2\bin;C:\Program Files (x86)\WinMerge;C:\Program Files (x86)\PHP\wsf_c\lib\;c:\Program Files (x86)\p-nand-q.com\GTools;c:\springsource\maven-2.2.1.RELEASE\bin;c:\Program Files\Apache Software Foundation\axis2-1.5.4\bin;c:\Program Files\TortoiseHg;C:\Program Files (x86)\NuGet;C:\NuGet\bin;C:\Program Files\Microsoft SQL Server\90\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\90\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\80\Tools\Binn\;C:\Program Files\Microsoft SQL Server\100\Tools\Binn\Redist\;C:\Program Files\Dependency Walker;C:\Program Files (x86)\Nmap;C:\Program Files\Oracle\VirtualBox;c:\Python27\Scripts;C:\Program Files\ILSpy2;C:\Program Files (x86)\Microsoft Team Foundation Server 2010 Power Tools\;C:\Program Files (x86)\Microsoft Team Foundation Server 2010 Power Tools\Best Practices Analyzer\;C:\Program Files (x86)\Windows Installer XML v3.5\bin;c:\Program Files (x86)\Microsoft SQL Server\110\Tools\Binn\;c:\Program Files\Microsoft SQL Server\110\Tools\Binn\;c:\Program Files\Microsoft SQL Server\110\DTS\Binn\;C:\Program Files (x86)\Microsoft Visual Studio 9.0\Common7\IDE\PrivateAssemblies\;C:\Program Files (x86)\Git\cmd;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Mercurial\;C:\Program Files (x86)\nant-0.92\bin;C:\Program Files\10Gen\mongodb-win32-x86_64-2008plus-2.2.0\bin;C:\Program Files (x86)\Git\bin
我的用户级别路径HKEY_CURRENT_USER\Environment
是
C:\Chocolatey\bin;C:\GnuWin\bin;C:\sysinternals;C:\Program Files (x86)\CVSNT\
似乎有一些东西正在用%SystemRoot%\system32\WindowsPowerShell\v1.0\;
加上的内容替换我的环境路径HKEY_CURRENT_USER\Environment
,而不使用的内容HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment
有什么想法可能导致这种情况发生或者我该如何记录它?