国产 无码 综合区,色欲AV无码国产永久播放,无码天堂亚洲国产AV,国产日韩欧美女同一区二区

HadoopYarn常用命令、yarn application查看任務(wù)、yarn logs查看日志、yarn applicationattempt查看嘗試運(yùn)行的任務(wù)、查看容器、Yarn生產(chǎn)環(huán)境核心參數(shù)

這篇具有很好參考價(jià)值的文章主要介紹了HadoopYarn常用命令、yarn application查看任務(wù)、yarn logs查看日志、yarn applicationattempt查看嘗試運(yùn)行的任務(wù)、查看容器、Yarn生產(chǎn)環(huán)境核心參數(shù)。希望對(duì)大家有所幫助。如果存在錯(cuò)誤或未考慮完全的地方,請(qǐng)大家不吝賜教,您也可以點(diǎn)擊"舉報(bào)違法"按鈕提交疑問(wèn)。

16. Yarn資源調(diào)度器

16.5 Yarn常用命令

Yarn狀態(tài)的查詢(xún),除了可以在hadoop103:8088頁(yè)面查看外,還可以通過(guò)命令操作。常見(jiàn)的命令操作如下所示:
需求:執(zhí)行WordCount案例,并用Yarn命令查看任務(wù)運(yùn)行情況。

  • [summer@hadoop102 ~]$ myhadoop.sh start
    yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)這個(gè)是之前寫(xiě)的腳本,想了解的可用看我之前寫(xiě)的文章
    https://blog.csdn.net/Redamancy06/article/details/126234179

  • [summer@hadoop102 hadoop-3.1.3]$ hadoop jar share/hadoop/mapreduce/hadoop-mapreduce-examples-3.1.3.jar wordcount /testinput /testoutput/output1
    yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)

16.5.1 yarn application查看任務(wù)

16.5.1.1 列出所有Application:
[summer@hadoop102 hadoop-3.1.3]$ yarn application -list
2022-10-10 16:57:24,620 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8032
Total number of applications (application-types: [], states: [SUBMITTED, ACCEPTED, RUNNING] and tags: []):0
                Application-Id	    Application-Name	    Application-Type	      User	     Queue	             State	       Final-State	       Progress	                       Tracking-URL

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)這里因?yàn)槿蝿?wù)已經(jīng)執(zhí)行結(jié)束了,所以沒(méi)有顯示出來(lái)。

16.5.1.2 根據(jù)Application狀態(tài)過(guò)濾:yarn application -list -appStates (所有狀態(tài):ALL、NEW、NEW_SAVING、SUBMITTED、ACCEPTED、RUNNING、FINISHED、FAILED、KILLED)
[summer@hadoop102 hadoop-3.1.3]$ yarn application -list -appStates FINISHED
2022-10-10 17:03:48,178 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8032
Total number of applications (application-types: [], states: [FINISHED] and tags: []):1
                Application-Id	    Application-Name	    Application-Type	      User	     Queue	             State	       Final-State	       Progress	                       Tracking-URL
application_1665325770064_0003	          word count	           MAPREDUCE	    summer	   default	          FINISHED	         SUCCEEDED	           100%	http://hadoop102:19888/jobhistory/job/job_1665325770064_0003

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)這里的任務(wù)application_1665325770064_0003就是剛剛我們執(zhí)行的任務(wù)

16.5.1.3 Kill掉Application:
[summer@hadoop102 hadoop-3.1.3]$ yarn application -kill application_1665325770064_0003
2022-10-10 17:05:56,667 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8032
Application application_1665325770064_0003 has already finished 

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)因?yàn)閍pplication_1665325770064_0003這個(gè)任務(wù)已經(jīng)完成了,所以不能再次被kill了

16.5.2 yarn logs查看日志

16.5.2.1 查詢(xún)Application日志:
yarn logs -applicationId <ApplicationId>
[summer@hadoop102 hadoop-3.1.3]$ yarn logs -applicationId application_1665325770064_0003

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)

16.5.2.2 查詢(xún)Container日志:
yarn logs -applicationId <ApplicationId> -containerId <ContainerId> 
[summer@hadoop102 hadoop-3.1.3]$ yarn logs -applicationId application_1665325770064_0003 -containerId container_1665325770064_0003_01_000001

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)

containerId從16.5.3.1里獲取

16.5.3 yarn applicationattempt查看嘗試運(yùn)行的任務(wù)

16.5.3.1 列出所有Application嘗試的列表:
yarn applicationattempt -list <ApplicationId>
[summer@hadoop102 hadoop-3.1.3]$ yarn applicationattempt -list application_1665325770064_0003
2022-10-10 20:01:36,619 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8032
Total number of application attempts :1
         ApplicationAttempt-Id	               State	                    AM-Container-Id	                       Tracking-URL
appattempt_1665325770064_0003_000001	            FINISHED	container_1665325770064_0003_01_000001	http://hadoop103:8088/proxy/application_1665325770064_0003/

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)

16.5.3.2 打印ApplicationAttemp狀態(tài):
yarn applicationattempt -status <ApplicationAttemptId>
[summer@hadoop102 hadoop-3.1.3]$ yarn applicationattempt -status appattempt_1665325770064_0003_000001
2022-10-10 20:11:35,446 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8032
Application Attempt Report : 
	ApplicationAttempt-Id : appattempt_1665325770064_0003_000001
	State : FINISHED
	AMContainer : container_1665325770064_0003_01_000001
	Tracking-URL : http://hadoop103:8088/proxy/application_1665325770064_0003/
	RPC Port : 42572
	AM Host : hadoop103
	Diagnostics : 

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)

ApplicationAttemptId從16.5.3.1里獲取

16.5.4 yarn container查看容器

16.5.4.1 列出所有Application 嘗試的列表
yarn container -list <ApplicationAttemptId>
[summer@hadoop102 hadoop-3.1.3]$ yarn container -list appattempt_1665325770064_0003_000001
2022-10-10 20:15:25,743 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8032
Total number of containers :0
                  Container-Id	          Start Time	         Finish Time	               State	                Host	   Node Http Address	                            LOG-URL

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)
只有在任務(wù)跑的途中才能看到 container 的狀態(tài),因?yàn)檫@個(gè)任務(wù)運(yùn)行完之后,container容器會(huì)立即釋放,我這里就沒(méi)有container容器,因?yàn)槿蝿?wù)已經(jīng)運(yùn)行結(jié)束了

[summer@hadoop102 hadoop-3.1.3]$ yarn applicationattempt -list application_1665325770064_0010
2022-10-10 20:25:08,250 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8032
Total number of application attempts :1
         ApplicationAttempt-Id	               State	                    AM-Container-Id	                       Tracking-URL
appattempt_1665325770064_0010_000001	             RUNNING	container_1665325770064_0010_01_000001	http://hadoop103:8088/proxy/application_1665325770064_0010/

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)這個(gè)靠手速弄出來(lái)一個(gè)結(jié)果,這個(gè)就是有容器的時(shí)候里面顯示的內(nèi)容

16.5.4.2 打印Container狀態(tài):
yarn container -status <ContainerId>

[summer@hadoop102 hadoop-3.1.3]$ yarn container -status container_1665325770064_0003_01_000001
2022-10-10 20:20:13,494 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8032
Container with id ‘container_1665325770064_0003_01_000001’ doesn’t exist in RM or Timeline Server.

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)注:只有在任務(wù)跑的途中才能看到 container 的狀態(tài)

[summer@hadoop102 hadoop-3.1.3]$ yarn container -status container_1665325770064_0010_01_000001
2022-10-10 20:25:14,642 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8032
Container Report : 
	Container-Id : container_1665325770064_0010_01_000001
	Start-Time : 1665404700780
	Finish-Time : 0
	State : RUNNING
	Execution-Type : GUARANTEED
	LOG-URL : http://hadoop104:8042/node/containerlogs/container_1665325770064_0010_01_000001/summer
	Host : hadoop104:36495
	NodeHttpAddress : http://hadoop104:8042
	Diagnostics : null

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)這個(gè)靠手速弄了一個(gè)任務(wù)在運(yùn)行中的顯示結(jié)果

16.5.5 yarn node查看節(jié)點(diǎn)狀態(tài)

列出所有節(jié)點(diǎn):yarn node -list -all

[summer@hadoop102 hadoop-3.1.3]$ yarn node -list -all
2022-10-10 20:33:40,711 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8032
Total Nodes:3
         Node-Id	     Node-State	Node-Http-Address	Number-of-Running-Containers
 hadoop104:36495	        RUNNING	   hadoop104:8042	                           0
 hadoop103:38375	        RUNNING	   hadoop103:8042	                           0
 hadoop102:40891	        RUNNING	   hadoop102:8042	                           0

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)

16.5.6 yarn rmadmin更新配置

加載隊(duì)列配置:yarn rmadmin -refreshQueues

[summer@hadoop102 hadoop-3.1.3]$ yarn rmadmin -refreshQueues
2022-10-10 20:39:09,817 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8033

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)

16.5.7 yarn queue查看隊(duì)列

打印隊(duì)列信息:yarn queue -status

[summer@hadoop102 hadoop-3.1.3]$ yarn queue -status default
2022-10-10 20:43:10,934 INFO client.RMProxy: Connecting to ResourceManager at hadoop103/192.168.159.103:8032
Queue Information : 
Queue Name : default
	State : RUNNING
	Capacity : 100.0%
	Current Capacity : .0%
	Maximum Capacity : 100.0%
	Default Node Label expression : <DEFAULT_PARTITION>
	Accessible Node Labels : *
	Preemption : disabled
	Intra-queue Preemption : disabled

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)
yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)
這里的值更詳細(xì)

16.6 Yarn生產(chǎn)環(huán)境核心參數(shù)

yarn application,# Hadoop,hadoop,mapreduce,大數(shù)據(jù)文章來(lái)源地址http://www.zghlxwxcb.cn/news/detail-799516.html

到了這里,關(guān)于HadoopYarn常用命令、yarn application查看任務(wù)、yarn logs查看日志、yarn applicationattempt查看嘗試運(yùn)行的任務(wù)、查看容器、Yarn生產(chǎn)環(huán)境核心參數(shù)的文章就介紹完了。如果您還想了解更多內(nèi)容,請(qǐng)?jiān)谟疑辖撬阉鱐OY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!

本文來(lái)自互聯(lián)網(wǎng)用戶(hù)投稿,該文觀點(diǎn)僅代表作者本人,不代表本站立場(chǎng)。本站僅提供信息存儲(chǔ)空間服務(wù),不擁有所有權(quán),不承擔(dān)相關(guān)法律責(zé)任。如若轉(zhuǎn)載,請(qǐng)注明出處: 如若內(nèi)容造成侵權(quán)/違法違規(guī)/事實(shí)不符,請(qǐng)點(diǎn)擊違法舉報(bào)進(jìn)行投訴反饋,一經(jīng)查實(shí),立即刪除!

領(lǐng)支付寶紅包贊助服務(wù)器費(fèi)用

相關(guān)文章

  • 解決使用git命令查看的某次提交時(shí)間與git log中顯示的不一致的問(wèn)題

    解決使用git命令查看的某次提交時(shí)間與git log中顯示的不一致的問(wèn)題

    筆者的使用環(huán)境: Git 2.37.0.windows.1 TortoiseGit 2.11.0.0 IntelliJ IDEA 2022.3.1 (Ultimate Edition) ??筆者遇到一個(gè)問(wèn)題,需要查看 Git 某個(gè)提交(commit)的時(shí)間,但是發(fā)現(xiàn)使用 Git 命令查看的時(shí)間與命令 git log 、TortoiseGit、IntelliJ IDEA 中顯示的不一致。而后三者顯示的是一致的。 ??筆者查

    2024年02月02日
    瀏覽(112)
  • 服務(wù)器硬件規(guī)格常用查看命令——通用命令

    服務(wù)器硬件規(guī)格常用查看命令——通用命令

    使用lshw命令可以查看服務(wù)器硬件配置的詳細(xì)信息。使用它可以在支持DMI的x86或IA-64系統(tǒng)以及某些PowerPC機(jī)器上打印內(nèi)存配置、固件版本、主板配置、CPU版本、G4可以工作)。目前該命令支持 CPU頻率、緩存、總線速度等信息(已知PowerMac DMI(僅限x86和IA-64)、OpenFimware設(shè)備樹(shù)(僅

    2024年02月05日
    瀏覽(30)
  • docker 容器日志查看常用命令

    查看最新日志: 將 container_name_or_id 替換為容器的名稱(chēng)或容器ID。這將顯示容器的最新日志輸出。 實(shí)時(shí)查看日志: 使用 -f 參數(shù),你可以實(shí)時(shí)跟蹤容器的日志輸出,類(lèi)似于 tail -f 命令。 查看指定行數(shù)的日志: 使用 --tail 參數(shù),可以指定查看的日志行數(shù)。將 number_of_lines 替換為你

    2024年02月05日
    瀏覽(31)
  • es查看集群狀態(tài)常用命令

    1.查看集群數(shù)據(jù)的正確率 active_shards_percent_as_number這個(gè)值如果低于100說(shuō)明集群數(shù)據(jù)正確性存在問(wèn)題,集群狀態(tài)為yellow或者red都會(huì)使這個(gè)值低于100 2.查看集群索引的狀態(tài)

    2024年02月11日
    瀏覽(28)
  • webassembly查看幫助以及常用命令

    emcc --help Emscripten Compiler Frontend (emcc) — Emscripten 3.1.42-git (dev) documentation emcc [options] files options有如下選擇: 優(yōu)化,n表示不同優(yōu)化等級(jí)和選項(xiàng) emscripten的構(gòu)建選項(xiàng),-s和OPTION中間的空格可以省略,=value也可以省略表示使能。 所有的OPTION都在src/settings.js中,常用的OPTION有: WASM

    2024年02月11日
    瀏覽(26)
  • 【科普】集群基礎(chǔ)和PBS任務(wù)管理常用命令

    【科普】集群基礎(chǔ)和PBS任務(wù)管理常用命令

    最近需要用到集群做實(shí)驗(yàn),學(xué)習(xí)下集群相關(guān)的內(nèi)容。 什么是服務(wù)器集群 服務(wù)器集群其實(shí)就是將很多服務(wù)器(或者簡(jiǎn)單理解為主機(jī))集中起來(lái)一起進(jìn)行同一種服務(wù),在客戶(hù)端看來(lái)就像是只有一個(gè)服務(wù)器。集群可以利用多個(gè)計(jì)算機(jī)進(jìn)行并行計(jì)算從而獲得很高的計(jì)算速度,也可以用多

    2024年02月08日
    瀏覽(18)
  • linux下常用命令查看端口占用

    在linux使用過(guò)程中,有時(shí)候需要了解當(dāng)前系統(tǒng)開(kāi)放了哪些端口,并且還需要查看開(kāi)放這些端口的具體進(jìn)程和用戶(hù),可以使用netstat命令, netstat命令是一個(gè)監(jiān)控TCP/IP網(wǎng)絡(luò)的非常有用的工具,它可以顯示路由表、實(shí)際的網(wǎng)絡(luò)連接以及每一個(gè)網(wǎng)絡(luò)接口設(shè)備的狀態(tài)信息 語(yǔ)法 netstat [選項(xiàng)

    2024年02月04日
    瀏覽(30)
  • Ubuntu 中常用的查看日志命令

    要查看Ubuntu的日志,可以使用以下命令: 1. 查看系統(tǒng)日志: 2. 查看應(yīng)用程序日志: 3. 查看登錄日志: 4. 查看內(nèi)核日志: 5. 查看系統(tǒng)啟動(dòng)日志: 您可以使用 tail 命令來(lái)查看最新的日志條目,例如: 這將顯示最新的日志條目,并在新條目添加到日志文件時(shí)自動(dòng)更新。

    2024年02月04日
    瀏覽(24)
  • Linux查看日志文件的常用命令

    1、查看文件最后1000行內(nèi)容 tail -n 1000 filename 2、實(shí)時(shí)查看文件最后1000行內(nèi)容,動(dòng)態(tài)刷新 tailf -n 1000 filename tail -f -n 1000 filename 3、按照搜索日志 cat filename | grep \\\'\\\' 4、按照搜索并包含前(后)多少行 【(A前B后C前后)幾行】 cat filename | grep \\\'\\\' -A 2 5、將查詢(xún)

    2024年02月07日
    瀏覽(21)
  • ElasticSearch常用查詢(xún)命令查看基本信息

    查看es的集群狀態(tài) http://IP:9200/_cat/healthv 注: IP指es集群某個(gè)ip地址, v表示格式化輸出 查看es集群節(jié)點(diǎn)列表 http://IP:9200/_cat/nodesv 查看es集群所有索引及數(shù)據(jù)大小 http://IP:9200/_cat/indicesv 查看單個(gè)索引結(jié)構(gòu)信息 http://IP:9200/indexNamepretty=true 注: indexName是索引名字, pretty=true表示格式化輸出

    2024年02月03日
    瀏覽(23)

覺(jué)得文章有用就打賞一下文章作者

支付寶掃一掃打賞

博客贊助

微信掃一掃打賞

請(qǐng)作者喝杯咖啡吧~博客贊助

支付寶掃一掃領(lǐng)取紅包,優(yōu)惠每天領(lǐng)

二維碼1

領(lǐng)取紅包

二維碼2

領(lǐng)紅包