{"id":33456,"date":"2021-08-24T15:58:12","date_gmt":"2021-08-24T19:58:12","guid":{"rendered":"https:\/\/mjtsai.com\/blog\/?p=33456"},"modified":"2021-08-24T16:00:35","modified_gmt":"2021-08-24T20:00:35","slug":"high-cpu-use-from-trustd","status":"publish","type":"post","link":"https:\/\/mjtsai.com\/blog\/2021\/08\/24\/high-cpu-use-from-trustd\/","title":{"rendered":"High CPU Use From trustd"},"content":{"rendered":"<p><a href=\"https:\/\/lapcatsoftware.com\/articles\/trustd.html\">Jeff Johnson<\/a> (<a href=\"https:\/\/twitter.com\/lapcatsoftware\/status\/1392100799082336260\">tweet<\/a>, <a href=\"https:\/\/twitter.com\/lapcatsoftware\/status\/1392808263280906247\">2<\/a>):<\/p>\n<blockquote cite=\"https:\/\/lapcatsoftware.com\/articles\/trustd.html\"><p>I&rsquo;ve heard from several other people who started noticing the same issue yesterday too, one of whom helpfully referred me to this <a href=\"https:\/\/www.reddit.com\/r\/mac\/comments\/n6f8ef\/process_trustd_high_cpu_usage\/\">reddit thread<\/a> with even more reports. On investigation, I found that the <code>nsurlsessiond<\/code> process was connecting to the server <code>valid.apple.com<\/code>, and immediately afterward <code>trustd<\/code> CPU jumped from 0% to 100%. It seems that the issue can be temporarily solved by preventing <code>nsurlsessiond<\/code> from connecting to <code>valid.apple.com<\/code>. You may have to reboot or force quit <code>trustd<\/code> to get its CPU usage back to normal. It&rsquo;s important to note that this is only a temporary workaround to the CPU usage problem; <code>trustd<\/code> is an important macOS system process that checks certificate validity and revocation status, so you probably don&rsquo;t want to block <code>valid.apple.com<\/code> forever.<\/p><\/blockquote>\n\n<p>I&rsquo;ve been seeing long periods of high CPU use from <code>trustd<\/code> since Catalina.<\/p>\n<blockquote cite=\"https:\/\/lapcatsoftware.com\/articles\/trustd.html\">\n<p>My postmortem theory is that at some point Apple had some bad data in their Certificate Revocation List online, everyone downloaded the bad data, and then <code>trustd<\/code> got stuck. Anyway, it looks like blocking <code>valid.apple.com<\/code> is no longer necessary after removing and regenerating the <code>valid.sqlite3<\/code> database.<\/p><\/blockquote>\n\n<p>To delete the database you need to reboot into macOS Recovery, and then find the SQLite file on the main boot drive, not at the recovery&rsquo;s <tt>\/private\/var\/protected\/trustd\/<\/tt>.<\/p>\n\n<p>The problem is also seen <a href=\"https:\/\/twitter.com\/lapcatsoftware\/status\/1393681037545312258\">on iOS<\/a>, though it&rsquo;s not clear how to fix it <a href=\"https:\/\/www.reddit.com\/r\/jailbreak\/comments\/ncfprs\/tutorial_a_fix_for_the_trustd_process_constantly\/\">unless your device is jailbroken<\/a>.<\/p>\n\n<p>Previously:<\/p>\n<ul>\n<li><a href=\"https:\/\/mjtsai.com\/blog\/2020\/11\/13\/apple-server-outage-makes-mac-apps-hang-on-launch\/\">Apple Server Outage Makes Mac Apps Hang on Launch<\/a><\/li>\n<\/ul>","protected":false},"excerpt":{"rendered":"<p>Jeff Johnson (tweet, 2): I&rsquo;ve heard from several other people who started noticing the same issue yesterday too, one of whom helpfully referred me to this reddit thread with even more reports. On investigation, I found that the nsurlsessiond process was connecting to the server valid.apple.com, and immediately afterward trustd CPU jumped from 0% to [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"apple_news_api_created_at":"2021-08-24T19:58:17Z","apple_news_api_id":"c3bad337-858a-42b5-ba6e-4fa3c369ab2a","apple_news_api_modified_at":"2021-08-24T20:00:39Z","apple_news_api_revision":"AAAAAAAAAAAAAAAAAAAAAQ==","apple_news_api_share_url":"https:\/\/apple.news\/Aw7rTN4WKQrW6bk-jw2mrKg","apple_news_coverimage":0,"apple_news_coverimage_caption":"","apple_news_is_hidden":false,"apple_news_is_paid":false,"apple_news_is_preview":false,"apple_news_is_sponsored":false,"apple_news_maturity_rating":"","apple_news_metadata":"\"\"","apple_news_pullquote":"","apple_news_pullquote_position":"","apple_news_slug":"","apple_news_sections":"\"\"","apple_news_suppress_video_url":false,"apple_news_use_image_component":false,"footnotes":""},"categories":[2],"tags":[131,31,1837,688,30,1609,1666,1891,48],"class_list":["post-33456","post","type-post","status-publish","format-standard","hentry","category-technology","tag-bug","tag-ios","tag-ios-14","tag-jailbreak","tag-mac","tag-macos-10-14","tag-macos-10-15","tag-macos-11-0","tag-security"],"apple_news_notices":[],"_links":{"self":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/33456","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/comments?post=33456"}],"version-history":[{"count":3,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/33456\/revisions"}],"predecessor-version":[{"id":33466,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/33456\/revisions\/33466"}],"wp:attachment":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/media?parent=33456"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/categories?post=33456"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/tags?post=33456"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}