{"id":5023,"date":"2020-11-20T08:47:45","date_gmt":"2020-11-20T00:47:45","guid":{"rendered":"https:\/\/ixyzero.com\/blog\/?p=5023"},"modified":"2020-11-20T08:47:45","modified_gmt":"2020-11-20T00:47:45","slug":"macos-%e4%b8%8b%e7%9a%84-configd-%e6%98%af%e4%bb%80%e4%b9%88%ef%bc%9f","status":"publish","type":"post","link":"https:\/\/ixyzero.com\/blog\/archives\/5023.html","title":{"rendered":"macOS \u4e0b\u7684 configd \u662f\u4ec0\u4e48\uff1f"},"content":{"rendered":"\n<p>=Start=<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">\u7f18\u7531\uff1a<\/h4>\n\n\n\n<p>\u5feb\u901f\u7b80\u5355\u8bb0\u5f55\u4e00\u4e0b\u6700\u8fd1\u770b\u5230\u7684\u4e00\u4e9b\u5185\u5bb9\uff0c\u65b9\u4fbf\u4ee5\u540e\u53c2\u8003\u3002<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">\u6b63\u6587\uff1a<\/h4>\n\n\n\n<h5 class=\"wp-block-heading\">\u53c2\u8003\u89e3\u7b54\uff1a<\/h5>\n\n\n\n<p>\u592a\u957f\u4e0d\u770b\u7684\u4e00\u53e5\u8bdd\u603b\u7ed3\uff1a<\/p>\n\n\n\n<p>configd \u662f macOS \u7cfb\u7edf\u4e0a\u8d1f\u8d23\u8bb8\u591a\u672c\u5730\u7cfb\u7edf\u914d\u7f6e\u7684(\u6838\u5fc3)\u5b88\u62a4\u8fdb\u7a0b\u3002<strong><span style=\"color:#a30003\" class=\"has-inline-color\">\u76ee\u524d\uff0cconfigd \u627f\u8f7d\u7684\u5927\u591a\u6570\u914d\u7f6e\u4ee3\u7406\u7528\u4e8e\u5efa\u7acb\u548c\u7ef4\u62a4\u7f51\u7edc\u914d\u7f6e<\/span><\/strong>\uff08\u63a5\u53e3\u540d\u79f0\u3001\u5efa\u7acb\u548c\u7ef4\u62a4IP\u5730\u5740\u3001\u8def\u7531\u3001\u7f51\u7edc\u4ee3\u7406\u7b49\uff09\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>configd is a system configuration daemon that runs behind Mac OS X, most users will never notice or see the core OS X process running in the background of their Macs. With that said, configd can sometimes act up and cause unusual CPU spikes and fan activity making your Mac sound like a wind tunnel. Odd configd behavior is easily diagnosed by launching Activity Monitor, sorting by the \u201c% CPU\u201d option, and seeing the \u2018configd\u2019 root user process sitting at the top taking up somewhere between 20-95% CPU. If that behavior lasts for a minute or so it\u2019s usually not a big deal, temporary spikes can be normal so just let it run and ignore it, but there are times where configd can go inexplicably errant and it\u2019ll sit around 50% CPU utilization or more for hours for no obvious reason \u2013 that is what we\u2019re looking to resolve here.\n\n$ man configd\n...\n# DESCRIPTION\nThe configd daemon is responsible for many configuration aspects of the local system.  configd maintains data reflecting the desired and current state of the system, provides notifications to applications when this data changes, and hosts a number of configuration agents in the form of loadable bundles.\n\nEach configuration agent is responsible for a well-defined aspect of configuration management. The agents look to one or more input sources (preferences, low-level kernel events, configd notifications, etc) and, through a set of policy modules, interacts with the system to establish the desired operational configura-\ntion.\n\nAccess to the data maintained by configd is via the SystemConfiguration.framework SCDynamicStore APIs.\n\n...\n# BUNDLES\nAt the present time, the majority of the configuration agents (or bundles) hosted by configd are used to establish and maintain the network configuration.  These agents include:\n\nKernelEventMonitor\nThis bundle is responsible for monitoring kernel events and conveying changes to the network state (e.g. link status) to other configuration agents and interested applications.\n\nInterfaceNamer\nThis bundle provides a name to each of the system's network interfaces.  The bundle queries the IOKit Registry for a list of network devices attached to the system and gives them BSD style names such as \"en0\".\n\nIPConfiguration\nThis agent is responsible for establishing and maintaining IPv4 and IPv6 addresses on the system.  These addresses may be manually specified in the network preferences or acquired using DHCP (or BOOTP), DHCPv6, and RTADV.\n\nIPMonitor\nThis agent is responsible for establishing and maintaining the primary network service, the default route, the active DNS configuration, and the active network proxies on the system.\n\nLinkConfiguration\nThis agent is responsible for establishing and maintaining the media type, media options, and MTU for ethernet interfaces.\n\nPreferencesMonitor\nThis agent is responsible for conveying the network configuration preferences specified by the administrator to the various configuration agents (IPv4, IPv6, ...).\n\nPPPController\nThis agent is responsible for establishing and maintaining PPP connections on the system.<\/code><\/pre>\n\n\n\n<p>macOS\u4e0a\u4e00\u4e2a\u548cconfigd\u8fdb\u7a0b\u548clog\u547d\u4ee4\u6709\u5173\u7684\u5c0f\u6280\u5de7\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>log show --predicate '(processImagePath contains \"configd\") &amp;&amp; (eventMessage contains \"en0: SSID \")' --style syslog --last 1d<\/code><\/pre>\n\n\n\n<p><\/p>\n\n\n\n<p>\u6839\u636e\u6211\u672c\u673a\u7684\u5b9e\u9645\u6d4b\u8bd5\uff0cmacOS \u4e0b\u7684 log \u547d\u4ee4\u8bb0\u5f55\u4e86\u5927\u69821\u4e2a\u6708\u4ee5\u5185\u7684\u6570\u636e\uff08\u8fd9\u4e2a\u5e94\u8be5\u548c\u4e2a\u4eba\u7684\u5b9e\u9645\u4f7f\u7528\u4ea7\u751f\u7684\u65e5\u5fd7\u91cf\u5927\u5c0f\u6709\u5173\uff0c\u65e5\u5fd7\u8d8a\u591a\uff0c\u8bb0\u5f55\u7684\u65f6\u95f4\u76f8\u5e94\u8d8a\u77ed\uff09\uff0c\u4e00\u822c\u6392\u67e5\u8fd8\u662f\u591f\u7528\u4e86\u7684\u3002<\/p>\n\n\n\n<h5 class=\"wp-block-heading\">\u53c2\u8003\u94fe\u63a5\uff1a<\/h5>\n\n\n\n<p>configd: Fixing High CPU Usage Problems with the configd Process in Mac OS X<br><a href=\"https:\/\/osxdaily.com\/2013\/09\/30\/configd-mac-os-x-fix\/\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/osxdaily.com\/2013\/09\/30\/configd-mac-os-x-fix\/<\/a><\/p>\n\n\n\n<p>What Is configd, and Why Is It Running On My Mac?<br><a href=\"https:\/\/www.howtogeek.com\/338196\/what-is-configd-and-why-is-it-running-on-my-mac\/\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/www.howtogeek.com\/338196\/what-is-configd-and-why-is-it-running-on-my-mac\/<\/a><\/p>\n\n\n\n<p>\u4ec0\u4e48\u5df2\u914d\u7f6e\uff1f\u4e3a\u4ec0\u4e48\u5728Mac\u4e0a\u8fd0\u884c\uff1f<br><a href=\"https:\/\/blog.csdn.net\/culinqian4296\/article\/details\/108781314\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/blog.csdn.net\/culinqian4296\/article\/details\/108781314<\/a><\/p>\n\n\n\n<p>What Is This Process and Why Is It Running on My Mac?<br><a href=\"https:\/\/www.howtogeek.com\/312671\/what-is-this-process-and-why-is-it-running-on-my-mac\/\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/www.howtogeek.com\/312671\/what-is-this-process-and-why-is-it-running-on-my-mac\/<\/a><\/p>\n\n\n\n<p>=END=<\/p>\n","protected":false},"excerpt":{"rendered":"<p>=Start= \u7f18\u7531\uff1a \u5feb\u901f\u7b80\u5355\u8bb0\u5f55\u4e00\u4e0b\u6700\u8fd1\u770b\u5230\u7684\u4e00\u4e9b\u5185\u5bb9\uff0c\u65b9\u4fbf\u4ee5\u540e\u53c2\u8003\u3002 \u6b63\u6587\uff1a \u53c2\u8003\u89e3\u7b54\uff1a \u592a\u957f\u4e0d\u770b\u7684\u4e00\u53e5 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[23,560],"tags":[1692,3,559,19],"class_list":["post-5023","post","type-post","status-publish","format-standard","hentry","category-knowledgebase-2","category-mac","tag-configd","tag-log","tag-mac","tag-tips"],"views":8298,"_links":{"self":[{"href":"https:\/\/ixyzero.com\/blog\/wp-json\/wp\/v2\/posts\/5023","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ixyzero.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ixyzero.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ixyzero.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ixyzero.com\/blog\/wp-json\/wp\/v2\/comments?post=5023"}],"version-history":[{"count":1,"href":"https:\/\/ixyzero.com\/blog\/wp-json\/wp\/v2\/posts\/5023\/revisions"}],"predecessor-version":[{"id":5024,"href":"https:\/\/ixyzero.com\/blog\/wp-json\/wp\/v2\/posts\/5023\/revisions\/5024"}],"wp:attachment":[{"href":"https:\/\/ixyzero.com\/blog\/wp-json\/wp\/v2\/media?parent=5023"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ixyzero.com\/blog\/wp-json\/wp\/v2\/categories?post=5023"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ixyzero.com\/blog\/wp-json\/wp\/v2\/tags?post=5023"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}