성태의 닷넷 이야기
홈 주인
모아 놓은 자료
프로그래밍
질문/답변
사용자 관리
사용자
메뉴
아티클
외부 아티클
유용한 코드
온라인 기능
MathJax 입력기
최근 덧글
[정성태] 그냥 RSS Reader 기능과 약간의 UI 편의성 때문에 사용...
[이종효] 오래된 소프트웨어는 보안 위협이 되기도 합니다. 혹시 어떤 기능...
[정성태] @Keystroke IEEE의 문서를 소개해 주시다니... +_...
[손민수 (Keystroke)] 괜히 듀얼채널 구성할 때 한번에 같은 제품 사라고 하는 것이 아...
[정성태] 전각(Full-width)/반각(Half-width) 기능을 토...
[정성태] Vector에 대한 내용은 없습니다. Vector가 닷넷 BCL...
[orion] 글 읽고 찾아보니 디자인 타임에는 InitializeCompon...
[orion] 연휴 전에 재현 프로젝트 올리자 생각해 놓고 여의치 않아서 못 ...
[정성태] 아래의 글에 정리했으니 참고하세요. C# - Typed D...
[정성태] 간단한 재현 프로젝트라도 있을까요? 저런 식으로 설명만 해...
글쓰기
제목
이름
암호
전자우편
HTML
홈페이지
유형
제니퍼 .NET
닷넷
COM 개체 관련
스크립트
VC++
VS.NET IDE
Windows
Team Foundation Server
디버깅 기술
오류 유형
개발 환경 구성
웹
기타
Linux
Java
DDK
Math
Phone
Graphics
사물인터넷
부모글 보이기/감추기
내용
<div style='display: inline'> <h1 style='font-family: Malgun Gothic, Consolas; font-size: 20pt; color: #006699; text-align: center; font-weight: bold'>svchost.exe 프로세스(IP Helper: IPHLPSVC)의 CPU 100% 현상</h1> <p> 웬일인지 알 수 없지만, svchost.exe 프로세스에서 CPU high 현상이 발생하고 있습니다.<br /> <br /> <img alt='svchost_cpu_100_0.png' src='/SysWebRes/bbs/svchost_cpu_100_0.png' /><br /> <br /> 아시는 분도 계시겠지만, svchost.exe는 윈도우 운영체제에 필요한 "NT Service"를 호스팅하는 특별한 프로세스입니다. 그리고, Process Explorer의 Threads 기능으로 보면 CPU를 소비하는 스레드와 그 스레드가 관여하고 있는 NT 서비스 이름을 확인할 수 있습니다. 이렇게!<br /> <br /> <img alt='svchost_cpu_100_1.png' src='/SysWebRes/bbs/svchost_cpu_100_1.png' /><br /> <br /> 그렇군요. 이렇게 되면 '서비스 관리자'에서 "IP Helper" 서비스만 재시작하면 해결될 거란 생각이 듭니다.<br /> <br /> <img alt='svchost_cpu_100_2.png' src='/SysWebRes/bbs/svchost_cpu_100_2.png' /><br /> <br /> 오호~~~ 그런데, 재시작해도 CPU High 현상이 사라지지 않습니다. (물론, 서비스를 멈추면 됩니다.)<br /> <br /> 이쯤 되면 이제 검색을 해봐야 합니다. ^^<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > IPHLPSVC High CPU in Windows 8 x64 ; <a target='tab' href='http://superuser.com/questions/507035/iphlpsvc-high-cpu-in-windows-8-x64'>http://superuser.com/questions/507035/iphlpsvc-high-cpu-in-windows-8-x64</a> </pre> <br /> 위의 글에서 IPv6 관련 기능들을 제어하는 것이 나오는데요.<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > netsh int ipv6 isatap set state disabled netsh int ipv6 6to4 set state disabled netsh int teredo set state disabled </pre> <br /> 테스트 해보니, 제 경우에는 "netsh int ipv6 6to4 set state disabled" 이것만 실행해도 CPU 100% 현상이 없어졌습니다. (컴퓨터를 재시작할 필요는 없었습니다.) 이 명령을 실행하면, 다음의 레지스트리 값이 2에서 3으로 바뀝니다.<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\iphlpsvc\config Name: Enable6to4 Type: REG_DWORD </pre> <br /> 좀 더 문제 분석을 해볼까요? ^^<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > iphlpsvc CPU % ; <a target='tab' href='https://social.technet.microsoft.com/Forums/windowsserver/en-US/ba9f0968-9275-434f-9e40-ec0621c3a35a/iphlpsvc-cpu-?forum=windowsserver2008r2general'>https://social.technet.microsoft.com/Forums/windowsserver/en-US/ba9f0968-9275-434f-9e40-ec0621c3a35a/iphlpsvc-cpu-?forum=windowsserver2008r2general</a> </pre> <br /> 위의 글에 보면 iphlpsvc 서비스에 대한 로그를 남기는 방법이 나옵니다. "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Tracing\IpHlpSvc" 키에 "EnableFileTracing" 이름의 DWORD 타입으로 값을 1로 설정하면 %SystemRoot%\Tracing 폴더에 IpHlpSvc.LOG 파일명으로 로그가 쌓입니다. 로깅 방식이 1MB 내에서 순환적으로 쌓이기 때문에 탐색기에서 보면 파일 크기가 끊임없이 변하게 되는데요. (크기를 변경하는 레지스트리 설정도 있지만) 상관없습니다. 어느 시점에 그냥 열어보면 됩니다. 제 경우에 다음과 같이 로그가 쌓였는데, 보시는 바와 같이 끊임없이 반복 로그가 쌓였습니다.<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > [17772] 14:53:30: DeleteReusableInterfaceGuidFromRegistry: deleted key System\CurrentControlSet\Services\IPHLPSVC\Parameters\6To4\{3375126B-A0AE-405F-8E62-72B8E575EC47}, status: 2 [17772] 14:53:30: Done enumerating interfaces [17772] 14:53:30: InstallSwInterface: Attempting install of device: 6TO4_Adapter with PNP id: *6to4mp [17772] 14:53:30: SwDeviceCreate failed with error: 0x800700b7 [17772] 14:53:30: InstallSwInterface: Failed to install 6TO4_Adapter with error:0xb7 [17772] 14:53:30: Failed to create interface, retry again. Error: 0xb7 [17772] 14:53:30: ReferenceService: ++45 (Process6to4ConfigurationChange) @ net\netio\iphlpsvc\service\6to4svc.c:3785 [17772] 14:53:30: Entered: Queueing worker for Process6to4ConfigurationChange [17772] 14:53:30: ReferenceService: ++46 (QueueWorkItemForProtocolEvent) @ net\netio\iphlpsvc\service\6to4svc.c:392 [17772] 14:53:30: Entered: Queueing Worker for ProtocolEvent [17772] 14:53:30: Leaving: Queued worker for ProtocolEvent [17772] 14:53:30: Leaving: Queued worker for Process6to4ConfigurationChange [17772] 14:53:30: DereferenceService: --47 (Process6to4ConfigurationChange) @ net\netio\iphlpsvc\service\6to4svc.c:981 [17772] 14:53:30: Get lock (0000000000002F84) invoked at net\netio\iphlpsvc\service\6to4svc.c : Start6to4InCompartment : 3800 [17772] 14:53:30: Lock (0000000000002F84) acquired at net\netio\iphlpsvc\service\6to4svc.c : Start6to4InCompartment : 3800. Return 0 [17772] 14:53:30: Lock (0000000000002F84) released at net\netio\iphlpsvc\service\6to4svc.c : Start6to4InCompartment : 3890. Return 1 [17772] 14:53:30: Failed to start 6to4 in compartment [17772] 14:53:30: Get lock (0000000000002F84) invoked at net\netio\iphlpsvc\service\6to4svc.c : Start6to4InCompartment : 3944 [17772] 14:53:30: Lock (0000000000002F84) acquired at net\netio\iphlpsvc\service\6to4svc.c : Start6to4InCompartment : 3944. Return 0 [17772] 14:53:30: Leaving: 6to4: Start6to4InCompartment ended in failure [17772] 14:53:30: Leaving: CompartmentRequirementChangeNotification6to4 [17772] 14:53:30: Leaving: Process6to4ConfigurationChange [17772] 14:53:30: Lock (0000000000002F84) released at net\netio\iphlpsvc\service\6to4svc.c : Process6to4ConfigurationHandler : 892. Return 1 [17772] 14:53:30: DereferenceService: --46 (Process6to4ConfigurationChange) @ net\netio\iphlpsvc\service\6to4svc.c:901 [17772] 14:53:30: Get lock (0000000000002F84) invoked at net\netio\iphlpsvc\service\6to4svc.c : Process6to4ConfigurationHandler : 886 [17772] 14:53:30: Lock (0000000000002F84) acquired at net\netio\iphlpsvc\service\6to4svc.c : Process6to4ConfigurationHandler : 886. Return 0 [17772] 14:53:30: Entered: Process6to4ConfigurationChangeUnderLock [17772] 14:53:30: GP: 6to4 state is not configured in GP. [17772] 14:53:30: GP: for ws, no relay/server name configured [17772] 14:53:30: 6to4ConfigChange: Enable6to4 = ENABLED. [17772] 14:53:30: Entered: CompartmentRequirementChangeNotification6to4 [17772] 14:53:30: RequirementChangeNotification6to4: CompartmentId = 1, HaveGlobalIpv6Address = 0, ICSEnabled = FALSE, GlobalIpv4AddressCount = 1, Hence Required = TRUE. [17772] 14:53:30: Entered Start6to4InCompartment, Compartment 1, 6to4 luid is 0 [17772] 14:53:30: Lock (0000000000002F84) released at net\netio\iphlpsvc\service\6to4svc.c : Start6to4InCompartment : 3759. Return 1 [17772] 14:53:30: Enumerating interfaces of PnpId: *6to4mp <span style='color: blue; font-weight: bold'>[17772] 14:53:30: Found match device id: SWD\IP_TUNNEL_VBUS\6TO4_ADAPTER [17772] 14:53:30: Enumerate6to4Interface: Enumerated Microsoft 6to4 Adapter [17772] 14:53:30: RetrieveInterfaceInformationFromRegistry: reg open key System\CurrentControlSet\Services\IPHLPSVC\Parameters\6To4\{3375126B-A0AE-405F-8E62-72B8E575EC47}, status 2 [17772] 14:53:30: Enumerate6to4Interface: Could not retrieve interface information from registry, uninstalling orphaned interface [17772] 14:53:30: Entering UninstallSwInterface for [17772] 14:53:30: Could not find to uninstall [17772] 14:53:30: Leaving UninstallSwInterface [17772] 14:53:30: Uninstall6To4Interface: Uninstall succeeded, deleting interface GUID from registry [17772] 14:53:30: RegDeleteTree returned error 2 [17772] 14:53:30: DeleteReusableInterfaceGuidFromRegistry: deleted key System\CurrentControlSet\Services\IPHLPSVC\Parameters\6To4\{3375126B-A0AE-405F-8E62-72B8E575EC47}, status: 2</span> ...[다시 첫 라인부터 반복]... </pre> <br /> 동시에 "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Network\NetCfgLockHolder" 레지스트리 키도 끊임없이 생성/삭제를 반복합니다. 보아하니, "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\SWD\IP_TUNNEL_VBUS\6TO4_Adapter" 경로에 있는 "*6to4mp" 장치가 검색되어 "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\iphlpsvc\Parameters\6To4" 까지 이어지는 것 같습니다.<br /> <br /> 잘은 모르겠지만, 아마도 장치 드라이버 설치를 하려는데 '무한 실패' 현상을 보이는 것 같습니다. 레지스트리 전체를 {3375126B-A0AE-405F-8E62-72B8E575EC47} 문자열로 검색해 보면 다음과 같은 경로들이 발견되었습니다.<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\{4d36e972-e325-11ce-bfc1-08002be10318}\0002 Name: NetCfgInstanceId Type: REG_SZ Data: <span style='color: blue; font-weight: bold'>{3375126B-A0AE-405F-8E62-72B8E575EC47}</span> </pre> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\{4d36e972-e325-11ce-bfc1-08002be10318}\0002\Linkage Name: Export Type: REG_MULTI_SZ Data: \Device\<span style='color: blue; font-weight: bold'>{3375126B-A0AE-405F-8E62-72B8E575EC47}</span> Name: RootDevice Type: REG_MULTI_SZ Data: <span style='color: blue; font-weight: bold'>{3375126B-A0AE-405F-8E62-72B8E575EC47}</span> </pre> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\DeviceClasses\{ad498944-762f-11d0-8dcb-00c04fc3358c}\##?#SWD#IP_TUNNEL_VBUS#6TO4_Adapter#{ad498944-762f-11d0-8dcb-00c04fc3358c}\#<span style='color: blue; font-weight: bold'>{3375126B-A0AE-405F-8E62-72B8E575EC47}</span> </pre> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Network\{4D36E972-E325-11CE-BFC1-08002BE10318}\<span style='color: blue; font-weight: bold'>{3375126B-A0AE-405F-8E62-72B8E575EC47}</span>\Connection Name: Name Type: REG_SZ Data: Local Area Connection* 11 </pre> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Network\{4d36e975-e325-11ce-bfc1-08002be10318}\{F4C8701D-6740-47A5-AC5E-5A1FC2F0D83D}\Linkage Name: Bind Type: REG_MULTI_SZ Data: ...[생략]... \Device\<span style='color: blue; font-weight: bold'>{3375126B-A0AE-405F-8E62-72B8E575EC47}</span> ...[생략]... Name: Route Type: REG_MULTI_SZ Data: ...[생략]... <span style='color: blue; font-weight: bold'>"{3375126B-A0AE-405F-8E62-72B8E575EC47}"</span> ...[생략]... </pre> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LanmanServer\Linkage HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Linkage HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\NetBIOS\Linkage HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\NetBT\Linkage HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP6\Linkage Name: Bind Type: REG_MULTI_SZ Data: \Device\NetbiosSmb ...[생략]... \Device\NetBT_Tcpip6_<span style='color: blue; font-weight: bold'>{3375126B-A0AE-405F-8E62-72B8E575EC47}</span> ...[생략]... Name: Export Type: REG_MULTI_SZ Data: \Device\LanmanServer_NetbiosSmb ...[생략]... \Device\LanmanServer_NetBT_Tcpip6_<span style='color: blue; font-weight: bold'>{3375126B-A0AE-405F-8E62-72B8E575EC47}</span> ...[생략]... Name: Route Type: REG_MULTI_SZ Data: "NetbiosSmb" ...[생략]... "NetBT" "Tcpip6" "<span style='color: blue; font-weight: bold'>{3375126B-A0AE-405F-8E62-72B8E575EC47}</span>" ...[생략]... </pre> <br /> ipconfig을 실행해 보면 "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Network\{4D36E972-E325-11CE-BFC1-08002BE10318}\{3375126B-A0AE-405F-8E62-72B8E575EC47}\Connection" 경로의 정보를 찾을 수 있습니다.<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > C:\Windows\system32>ipconfig Windows IP Configuration Ethernet adapter vEthernet (Realtek PCIe GBE Family Controller Virtual Switch): Connection-specific DNS Suffix . : kornet Link-local IPv6 Address . . . . . : fe80::7836:3c4a:a047:8fae%26 IPv4 Address. . . . . . . . . . . : 123.221.123.221 Subnet Mask . . . . . . . . . . . : 255.255.255.0 Default Gateway . . . . . . . . . : 123.221.123.254 <span style='color: blue; font-weight: bold'>Tunnel adapter Local Area Connection* 11: Media State . . . . . . . . . . . : Media disconnected Connection-specific DNS Suffix . : </span> Tunnel adapter Teredo Tunneling Pseudo-Interface: Connection-specific DNS Suffix . : IPv6 Address. . . . . . . . . . . : 2001:0:9d32:9037:158:3e25:835c:df27 Link-local IPv6 Address . . . . . : fe80::868:4e15:365c:1f27%33 Default Gateway . . . . . . . . . : :: Tunnel adapter isatap.testnet: Connection-specific DNS Suffix . : testnet Link-local IPv6 Address . . . . . : fe80::200:5efe:123.221.123.221%19 Default Gateway . . . . . . . . . : </pre> <br /> "ipconfig /all" 옵션으로 보면 이것이 "Microsoft 6to4 Adapter"임을 알 수 있습니다.<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > Tunnel adapter Local Area Connection* 11: Media State . . . . . . . . . . . : Media disconnected Connection-specific DNS Suffix . : Description . . . . . . . . . . . : <span style='color: blue; font-weight: bold'>Microsoft 6to4 Adapter</span> Physical Address. . . . . . . . . : 00-00-00-00-00-00-00-E0 DHCP Enabled. . . . . . . . . . . : No Autoconfiguration Enabled . . . . : Yes </pre> <br /> 흥미로운 검색 결과가 하나 있는데,<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > Tunnel Adapter ? Microsoft 6to4 adapter Remover ; <a target='tab' href='http://www.sordum.org/6423/tunnel-adapter-%E2%80%93-microsoft-6to4-adapter-remover/'>http://www.sordum.org/6423/tunnel-adapter-%E2%80%93-microsoft-6to4-adapter-remover/</a> </pre> <br /> 이렇게 "Microsoft 6to4 Adapter" 항목을 삭제하는 유틸리티도 있습니다. 위의 글에 보면, "if you have more than once 6to4 adapter in device manager probably you have the BUG and probably a new Microsoft 6to4 adapter is unexpectedly created after you restart Windows 7 or Windows Server 2008 R2" 라고 나오는데 "Tunnel adapter Local Area Connection* [번호]"와 같이 늘어나는 현상이 한때 발생한 것으로, 제가 겪은 현상과는 다르므로 상관없어 보입니다.<br /> <br /> <a name='show_hidden_device'></a> 어쨌든 "Microsoft 6to4 Adapter" 장치를 삭제하려면 다음 그림과 같이 "장치 관리자"에서 "Show hidden devices" 옵션을 켜서 보이게 한 후 "Uninstall" 시키면 됩니다.<br /> <br /> <img alt='svchost_cpu_100_3.png' src='/SysWebRes/bbs/svchost_cpu_100_3.png' /><br /> <br /> 재미있는 것은? 다시 "Scan for hardware changes" 메뉴를 실행하거나, "IP Helper" 서비스를 재시작하면 다시 "Microsoft 6to4 Adapter" 장치가 재생성된다는 점입니다. 도대체 이 장치를... 확실히 지우는 방법을 모르겠습니다. ^^;<br /> <br /> 따라서, 일단은 이 글에서 쓴 것과 같은 CPU 100% 현상을 해결하려면 "netsh int ipv6 6to4 set state disabled" 시키는 방법이 최선입니다. IPv6 네트워크 망이 아니라면 이것을 비활성화한다고 해서 영향이 있는 것은 아니므로 안심하시고 사용해도 무방합니다. 왜 이 방법만이 해결책인지에 대해서는 아래의 글에 보면,<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > Microsoft 6to4 adapter ; <a target='tab' href='https://social.technet.microsoft.com/Forums/windows/en-US/3a503cdb-e61c-44bc-97c4-0b38b0e5f929/microsoft-6to4-adapter?forum=itprovistahardware'>https://social.technet.microsoft.com/Forums/windows/en-US/3a503cdb-e61c-44bc-97c4-0b38b0e5f929/microsoft-6to4-adapter?forum=itprovistahardware</a> </pre> <br /> "your network adapter is not a supportive one for this component."라고 언급하는 것으로 봐서 네트워크 어댑터가 "IPv6 to IPv4"에 대한 지원을 못하는 경우라고 합니다. (그 이상은 단서를 찾을 수가 없군요. ^^;)<br /> <br /> 참고로, 제가 가지고 있는 또 다른 3대의 물리 PC에서는 "Microsoft 6to4 Adapter" 장치가 아예 없었습니다. 오늘은 일단 여기까지!<br /> </p><br /> <br /><hr /><span style='color: Maroon'>[이 글에 대해서 여러분들과 의견을 공유하고 싶습니다. 틀리거나 미흡한 부분 또는 의문 사항이 있으시면 언제든 댓글 남겨주십시오.]</span> </div>
첨부파일
스팸 방지용 인증 번호
5876
(왼쪽의 숫자를 입력해야 합니다.)