{"id":14356,"date":"2024-08-14T16:07:45","date_gmt":"2024-08-14T08:07:45","guid":{"rendered":"http:\/\/xinyiworld.top\/wordpress_it\/?p=14356"},"modified":"2024-08-21T17:50:14","modified_gmt":"2024-08-21T09:50:14","slug":"netd%e4%bb%8b%e7%bb%8d","status":"publish","type":"post","link":"http:\/\/xinyiworld.top\/wordpress_it\/?p=14356","title":{"rendered":"netd\u4ecb\u7ecd"},"content":{"rendered":"<p><a href=\"https:\/\/lixiaogang03.github.io\/2019\/09\/26\/Android-NetworkControl\/\">https:\/\/lixiaogang03.github.io\/2019\/09\/26\/Android-NetworkControl\/<\/a><\/p>\n<p>\u6e90\u7801\u76ee\u5f55\uff1a<code>system\/netd\/server<\/code><\/p>\n<h1>\u542f\u52a8<\/h1>\n<p>init\u8fdb\u7a0b\u4f1a\u89e3\u6790\/system\/etc\/init\/netd.rc\u6587\u4ef6\uff0c\u7531\u4e8e\u662f<code>class main<\/code>\uff0c\u4f1a\u88abinit\u8fdb\u7a0b\u542f\u52a8\u3002<\/p>\n<pre><code class=\"language-bash\">service netd \/system\/bin\/netd\n    class main\n    socket dnsproxyd stream 0660 root inet\n    socket mdns stream 0660 root system\n    socket fwmarkd stream 0660 root inet\n    onrestart restart zygote\n    onrestart restart zygote_secondary\n    # b\/121354779: netd itself is not updatable, but on startup it dlopen()s the resolver library\n    # from the DNS resolver APEX. Mark it as updatable so init won&#039;t start it until all APEX\n    # packages are ready.\n    updatable<\/code><\/pre>\n<h1>netd\u670d\u52a1\u6ce8\u518c\u6d41\u7a0b<\/h1>\n<p><a href=\"https:\/\/blog.csdn.net\/shijiheike\/article\/details\/116765804\">https:\/\/blog.csdn.net\/shijiheike\/article\/details\/116765804<\/a><\/p>\n<p>\u89c1<code>system\/netd\/server\/main.cpp<\/code><br \/>\nNetdNativeService::start()\u8c03\u7528BinderService<NetdNativeService>::publish()\uff0c\u5373\u4f1a\u628aNetdNativeService\u5b9e\u4f8b\u6ce8\u518c\u5230ServiceManager\u4e2d\u3002<\/p>\n<button class=\"simplefavorite-button\" data-postid=\"14356\" data-siteid=\"1\" data-groupid=\"1\" data-favoritecount=\"0\" style=\"\">\u6536\u85cf <i class=\"sf-icon-star-empty\"><\/i><\/button>","protected":false},"excerpt":{"rendered":"<p>https:\/\/lixiaogang03.github.io\/2019\/09\/26\/Android- [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1096],"tags":[],"_links":{"self":[{"href":"http:\/\/xinyiworld.top\/wordpress_it\/index.php?rest_route=\/wp\/v2\/posts\/14356"}],"collection":[{"href":"http:\/\/xinyiworld.top\/wordpress_it\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/xinyiworld.top\/wordpress_it\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/xinyiworld.top\/wordpress_it\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/xinyiworld.top\/wordpress_it\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=14356"}],"version-history":[{"count":6,"href":"http:\/\/xinyiworld.top\/wordpress_it\/index.php?rest_route=\/wp\/v2\/posts\/14356\/revisions"}],"predecessor-version":[{"id":14416,"href":"http:\/\/xinyiworld.top\/wordpress_it\/index.php?rest_route=\/wp\/v2\/posts\/14356\/revisions\/14416"}],"wp:attachment":[{"href":"http:\/\/xinyiworld.top\/wordpress_it\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=14356"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/xinyiworld.top\/wordpress_it\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=14356"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/xinyiworld.top\/wordpress_it\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=14356"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}