{"id":1964,"date":"2021-01-22T13:52:28","date_gmt":"2021-01-22T05:52:28","guid":{"rendered":"https:\/\/nj.transwarp.cn:8180\/?p=1964"},"modified":"2022-01-14T14:26:36","modified_gmt":"2022-01-14T06:26:36","slug":"%e5%9f%ba%e4%ba%8e-spark-ui-%e6%80%a7%e8%83%bd%e6%8e%92%e6%9f%a5%e5%8f%8a%e8%b0%83%e4%bc%98","status":"publish","type":"post","link":"https:\/\/kbwp.transwarp.cn\/?p=1964","title":{"rendered":"\u57fa\u4e8e Spark UI \u6027\u80fd\u6392\u67e5\u53ca\u8c03\u4f18"},"content":{"rendered":"<h3>\u6982\u8981\u63cf\u8ff0<\/h3>\n<hr \/>\n<p>Inceptor \u6027\u80fd\u95ee\u9898\u9664\u4e86\u901a\u8fc7 Log \u8fdb\u884c\u6570\u636e\u5206\u6790\uff0c\u8fd8\u53ef\u4ee5\u5229\u7528 Spark UI \u505a\u6027\u80fd\u8c03\u6574\u548c\u4f18\u5316\u3002<br \/>\n\u90a3\u4e48\u672c\u7bc7\u5c31\u4ecb\u7ecd\u4e00\u4e0b Spark UI \u7684\u4fe1\u606f\uff0c\u4ee5\u53ca\u5982\u4f55\u5229\u7528 Spark UI \u8fdb\u884c\u6027\u80fd\u95ee\u9898\u7684\u6392\u67e5\u3002<\/p>\n<h3>\u8be6\u7ec6\u8bf4\u660e<\/h3>\n<hr \/>\n<p>\u5927\u81f4\u4f1a\u6309\u7167\u4ee5\u4e0b\u51e0\u4e2a\u90e8\u5206\u505a\u7b80\u5355\u4ecb\u7ecd\uff1a<\/p>\n<ul>\n<li>Spark UI \u9875\u9762\u4fe1\u606f\u7684\u57fa\u672c\u6982\u5ff5\uff1b<\/li>\n<li>Spark UI \u9875\u9762\u4fe1\u606f\u7684\u4f5c\u7528\uff1b<\/li>\n<li>Spark UI \u9875\u9762\u5e38\u89c1\u95ee\u9898\u7684\u603b\u7ed3\uff1b<\/li>\n<\/ul>\n<h4>Spark UI \u9875\u9762\u4fe1\u606f\u57fa\u672c\u6982\u5ff5<\/h4>\n<p>Spark UI \u5165\u53e3\uff0c\u5728\u8fd0\u884c\u4e86 Inceptor server \u89d2\u8272\u7684\u8282\u70b9\u7684 4040 \u7aef\u53e3\u5373\u53ef\u8bbf\u95ee\uff1b\u53ef\u4ee5\u76f4\u63a5\u767b\u9646\uff1a<a href=\"http:\/\/Inceptor-server-ip:4040\">http:\/\/Inceptor-server-ip:4040<\/a> \u3002<br \/>\n\u5982\u679c\u662f\u65b0\u7248\u672c\u7684 TDH \uff0c\u53ef\u80fd\u5df2\u7ecf\u5b89\u88c5\u4e86 dbaservice \u5e0c\u671b\u5207\u6362\u56de\u65e7\u7248\u672c\u7684 Spark UI \u53ef\u4ee5\u53c2\u8003\u8fd9\u4e2a\u8fde\u63a5\uff1a<a href=\"https:\/\/nj.transwarp.cn:8180\/?p=3855\" title=\"\u5173\u95edDBAService\uff0c\u4f7f\u7528\u65e7\u7248Spark UI\">\u5173\u95edDBAService\uff0c\u4f7f\u7528\u65e7\u7248Spark UI<\/a><\/p>\n<h5>\u4e3b\u9875\u4ecb\u7ecd<\/h5>\n<p>\u6b64\u6587\u6863\u53ea\u4ecb\u7ecd\u6027\u80fd\u76f8\u5173\u7684\u4fe1\u606f\uff0c\u5176\u4ed6\u5185\u5bb9\u4e0d\u505a\u4ecb\u7ecd\uff1b<\/p>\n<p><img decoding=\"async\" src=\"\/wp-content\/uploads\/2021\/01\/image-1611283103087.png\" alt=\"file\" \/><\/p>\n<ol>\n<li>Jobs \u6807\u7b7e\uff0c\u53ef\u4ee5\u770b\u5230\u5f53\u524d\u6240\u6709\u4efb\u52a1\uff0c\u4ee5\u53ca Job \u7684\u6267\u884c\u65f6\u95f4\uff1b<\/li>\n<li>Stages \u9875\u9762\uff0c\u53ef\u4ee5\u770b\u5230\u5e94\u7528\u7684\u6240\u6709 stage\uff0c\u4ee5\u53ca\u8be6\u7ec6\u7684 task \u6267\u884c\u60c5\u51b5\uff1b<\/li>\n<li>Executors \u9875\u9762\uff0c\u8fd9\u91cc\u53ef\u4ee5\u770b\u5230 executor \u4f7f\u7528\u7684\u5185\u5b58\u3001\u5e76\u53d1\u7684 task \u6570\u91cf\uff0c\u8fd8\u53ef\u4ee5\u641c\u96c6\u4e00\u4e9bjvm \u76f8\u5173\u4fe1\u606f\uff08jstack\u3001jmap\u7b49\uff09\uff1b<\/li>\n<\/ol>\n<h5>1\u3001Jobs \u6807\u7b7e<\/h5>\n<p>Jobs \u9875\u9762\u53ef\u4ee5\u663e\u793a\u603b\u4f53\u7684\u8fd0\u884c\u60c5\u51b5\uff0c\u5305\u62ec\u8c03\u5ea6\u6a21\u5f0f\uff08Scheduling Mode\uff09\uff0c\u8fd0\u884c\u6a21\u5f0f\uff08Cluster \u6216\u8005 local\uff09\uff1b<br \/>\nJobs Event timeline \u4e0b\u9762\u663e\u793a\u5177\u4f53\u7684 sql \u5185\u5bb9\u3001\u63d0\u4ea4\u7528\u6237\u3001\u63d0\u4ea4\u65f6\u95f4\u3001\u6267\u884c\u65f6\u95f4\uff1b\u4ee5\u53ca\u8fd9\u4e00\u4e2a sql \u88ab\u5206\u6210\u4e86\u51e0\u4e2a stage\u3001\u51e0\u4e2a task \uff1b\u4ee5\u53ca task \u6267\u884c\u7684\u60c5\u51b5\u7b49\u4fe1\u606f\uff1b<\/p>\n<p><img decoding=\"async\" src=\"\/wp-content\/uploads\/2021\/01\/image-1611283209388.png\" alt=\"file\" \/><\/p>\n<ul>\n<li>\n<p>Stages:Succeeded\/Total \u4e0b\u9762\u7684 0\/1 \u4ee3\u8868\u5f53\u524d job \u88ab\u5206\u6210\u4e86 1 \u4e2a stage\uff0c\u5b8c\u6210\u4e86 0 \u4e2a\uff1b<\/p>\n<\/li>\n<li>\n<p>Tasks:Succeeded\/Total \u4e0b\u9762\u7684 0\/15 \u4ee3\u8868\u5f53\u524d job \u88ab\u5206\u6210\u4e86 15 \u4e2a task\uff0c\u5b8c\u6210\u4e86 0 \u4e2a\uff1b<br \/>\n<strong>PS\uff1a\u6df1\u84dd\u8272\u90e8\u5206\u4ee3\u8868\u5df2\u7ecf\u5b8c\u6210\u7684\uff0c\u6d45\u84dd\u8272\u90e8\u5206\u4ee3\u8868\u5206\u914d\u4e86 CPU core \u6b63\u5728\u8fd0\u884c\u7684\uff0c\u7a7a\u767d\u90e8\u95e8\u4ee3\u8868 executor \u6ca1\u6709\u53ef\u7528 CPU core \u8d44\u6e90\uff0c\u672a\u6267\u884c\u7684\u4efb\u52a1<\/strong><br \/>\n<img decoding=\"async\" src=\"\/wp-content\/uploads\/2021\/01\/image-1624418043044.png\" alt=\"file\" \/><\/p>\n<\/li>\n<li>\n<p>Duration \u53ef\u4ee5\u6309\u7167\u5347\u5e8f\u3001\u964d\u5e8f\u6392\u5217\uff0c\u53ef\u4ee5\u901a\u8fc7\u8fd9\u4e2a\u67e5\u770b\u5f53\u524d\u8fd0\u884c\u65f6\u95f4\u6700\u4e45\u7684 job \u662f\u54ea\u4e00\u4e2a\uff0c\u662f\u5426\u5f02\u5e38\u7684 job\uff1b<\/p>\n<\/li>\n<\/ul>\n<p>\u901a\u8fc7 job \u7684 description \u7684 link \u80fd\u70b9\u51fb\u8fdb\u53bb\u770b\u5230 job \u7684\u66f4\u8be6\u7ec6\u7684\u6267\u884c\u60c5\u51b5\uff1b<\/p>\n<p><img decoding=\"async\" src=\"\/wp-content\/uploads\/2021\/01\/image-1611283411139.png\" alt=\"file\" \/><\/p>\n<h5>2\u3001Detail for Job<\/h5>\n<p>Group id \u540e\u9762\u7684\u90e8\u5206\u5c31\u662f \u5f53\u524d Job \u7684\u552f\u4e00\u6807\u8bc6\u7b26\uff0c\u8fd9\u4e2a\u9875\u9762\u53ef\u4ee5\u770b\u5230 Job \u7684\u5f53\u524d\u6267\u884c\u60c5\u51b5\uff1b<\/p>\n<p><img decoding=\"async\" src=\"\/wp-content\/uploads\/2021\/01\/image-1611283727212.png\" alt=\"file\" \/><\/p>\n<h5>3\u3001Detail for Stage<\/h5>\n<ul>\n<li>\n<p>Summary Metrics for 18 Completed Tasks\uff1a\u5df2\u5b8c\u6210task \u7684\u6027\u80fd\u6307\u6807\u603b\u7ed3\uff0c\u662ftask \u7ea7\u522b\u7684\uff1a<\/p>\n<ul>\n<li>\u6211\u4eec\u9700\u8981\u5173\u6ce8\u7684\uff0c25%\u7684\uff0c50%\u7684\uff0c75%\u7684\uff0c\u6bd4\u5982\u6700\u77ed\u76841s \uff0c25% \u7684\u90fd\u662f60s\uff0c\u90a3\u5c31\u8bf4\u660e 1s \u7684\u8fd9\u4e2a\u6ca1\u6709\u4ec0\u4e48\u53c2\u8003\u4ef7\u503c\uff0c\u540c\u6837\u9053\u7406\u6700\u5927\u7684\u4e5f\u662f\u4e00\u6837<\/li>\n<\/ul>\n<\/li>\n<li>\n<p>Aggregated Metrics by Executor\uff0cexecutor \u7ea7\u522b\u7684\u6027\u80fd\u6307\u6807\uff1a<\/p>\n<ul>\n<li>\u67d0\u4e2a\u8282\u70b9\u4e0a\u6267\u884c\u7684\u65f6\u95f4\u5dee\u5f02\uff0c\u4ee5\u53ca\u67d0\u4e2a\u8282\u70b9\u4e0a\u7684executor \u7684\u6267\u884c\u60c5\u51b5\uff0c\u548cexecutor \u9875\u9762\u5f88\u7c7b\u4f3c\uff1b<\/li>\n<\/ul>\n<\/li>\n<li>\n<p>Tasks\uff0c\u66f4\u8be6\u7ec6\u7684\u6bcf\u4e2a task \u7684\u6027\u80fd\u6307\u6807\u7edf\u8ba1\uff0c\u5305\u62ec\uff1a<\/p>\n<ul>\n<li>task id<\/li>\n<li>attempt\uff1a\u4efb\u52a1\u91cd\u8bd5\u6b21\u6570<\/li>\n<li>status\uff1a\u4efb\u52a1\u72b6\u6001<\/li>\n<li>locality Level\uff1a\u6570\u636e\u672c\u5730\u5316\u7ea7\u522b<\/li>\n<li>Executor\uff1a\u5728\u54ea\u4e2a\u8282\u70b9\u6267\u884c<\/li>\n<li>launch time\uff1a\u542f\u52a8\u65f6\u95f4<\/li>\n<li>scheduler delay\uff1a\u8c03\u5ea6\u5ef6\u8fdf<\/li>\n<li>duration\uff1a\u8fd0\u884c\u65f6\u957f<\/li>\n<li>Gctime\uff1a\u4efb\u52a1 Gctime<\/li>\n<li>errors\uff1a\u62a5\u9519\u4fe1\u606f<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p><img decoding=\"async\" src=\"\/wp-content\/uploads\/2021\/01\/image-1611283793063.png\" alt=\"file\" \/><\/p>\n<p>\u9700\u8981\u91cd\u70b9\u5173\u6ce8\u7684\u662f\u51e0\u4e2a\u65f6\u95f4\u6307\u6807\uff1a<\/p>\n<ol>\n<li>scheduler delay \u8d85\u8fc7 3s \u65f6\uff1b<\/li>\n<li>\u5f53 GCTime \u8d85\u8fc7 Duration \u7684 10% \u65f6\uff0c\u5c31\u6709\u53ef\u80fd\u662f\u56e0\u4e3a\u51fa\u73b0\u4e86 FGC\uff0c\u9700\u8981\u8c03\u6574 executor \u7684\u5185\u5b58\uff0c\u6216\u8005\u4f18\u5316 sql\uff1b<\/li>\n<\/ol>\n<h5>4\u3001Executors<\/h5>\n<p>Executors \u9875\u9762\u53ef\u4ee5\u770b\u5230\u6709\u591a\u5c11\u4e2a executor\uff0c\u5e76\u4e14\u53ef\u4ee5\u70b9\u51fb\u7279\u5b9a\u7684 executor \u540e\u9762\u7684 Thread Dump \u83b7\u53d6 jstack \u4fe1\u606f\uff1b<br \/>\n\u5176\u4e2d driver \u4ee3\u8868\u7684\u662f Inceptor-server \u7684\u4fe1\u606f\uff0c\u70b9\u51fb driver \u540e\u9762\u7684 Thread Dump \u53ef\u4ee5\u83b7\u53d6 server \u7684jstack\uff0c\u70b9\u51fb Heap Histogram \u53ef\u4ee5\u83b7\u53d6 server \u7684 jmap \u4fe1\u606f\uff1b<\/p>\n<p><img decoding=\"async\" src=\"\/wp-content\/uploads\/2021\/01\/image-1624418891117.png\" alt=\"file\" \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6982\u8981\u63cf\u8ff0 Inceptor \u6027\u80fd\u95ee\u9898\u9664\u4e86\u901a\u8fc7 Log \u8fdb\u884c\u6570\u636e\u5206\u6790\uff0c\u8fd8\u53ef\u4ee5\u5229\u7528 Spark UI \u505a\u6027\u80fd\u8c03\u6574\u548c ..<\/p>\n<div class=\"clear-fix\"><\/div>\n<p><a href=\"https:\/\/kbwp.transwarp.cn\/?p=1964\" title=\"read more...\">Read more<\/a><\/p>\n","protected":false},"author":11,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-1964","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"acf":[],"_links":{"self":[{"href":"https:\/\/kbwp.transwarp.cn\/index.php?rest_route=\/wp\/v2\/posts\/1964","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kbwp.transwarp.cn\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kbwp.transwarp.cn\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kbwp.transwarp.cn\/index.php?rest_route=\/wp\/v2\/users\/11"}],"replies":[{"embeddable":true,"href":"https:\/\/kbwp.transwarp.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1964"}],"version-history":[{"count":1,"href":"https:\/\/kbwp.transwarp.cn\/index.php?rest_route=\/wp\/v2\/posts\/1964\/revisions"}],"predecessor-version":[{"id":5160,"href":"https:\/\/kbwp.transwarp.cn\/index.php?rest_route=\/wp\/v2\/posts\/1964\/revisions\/5160"}],"wp:attachment":[{"href":"https:\/\/kbwp.transwarp.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1964"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kbwp.transwarp.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1964"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kbwp.transwarp.cn\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1964"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}