一、背景

在Linux下可以使用 free 命令来方便的查看内存占用情况,如 free -g、free -m等,但MacOS下没有这个命令。

既然如此,那么MacOS里是否有类似的工具呢?

而我们又该如何查看整个PC的内存占用情况,及指定进程的内存占用情况呢?

别急,带着这些疑问请往下看:

二、方案

1、通过 top 命令来替代 free 命令

A). 查看全部进程的内存占用大小

top -l 1 | head -n 10 | grep PhysMemPhysMem: 31G used (2485M wired), 223M unused.

B). 查看指定进程的内存占用大小

top -pid 72267 -l 1 | tail -n 1 | awk '{print $8}' 1039M

2、通过 GUI 工具 “活动监视器” 查看内存

3、使用Python psutil库包工具查看

三、实验

3.1 查看系统总内存占用情况

先总体看看:

➜  libexec git:(stable) top -l 1 | head -n 10   Processes: 643 total, 2 running, 641 sleeping, 4233 threads
2023/06/07 11:03:11
Load Avg: 3.16, 2.53, 2.48
CPU usage: 4.66% user, 10.83% sys, 84.49% idle
SharedLibs: 698M resident, 117M data, 167M linkedit.
MemRegions: 859023 total, 10G resident, 372M private, 3227M shared.
PhysMem: 31G used (2485M wired), 223M unused.
VM: 289T vsize, 3778M framework vsize, 2603873(0) swapins, 4151090(0) swapouts.
Networks: packets: 189125397/149G in, 154096002/51G out.
Disks: 49163482/907G read, 64642095/1086G written.PID    COMMAND          %CPU TIME     #TH    #WQ #PORTS MEM   PURG  CMPRS PGRP  PPID  STATE    BOOSTS       %CPU_ME %CPU_OTHRS UID FAULTS    COW    MSGSENT    MSGRECV    SYSBSD     SYSMACH    CSW        PAGEINS IDLEW     POWER INSTRS CYCLES USER                   #MREGS RPRVT VPRVT VSIZE KPRVT KSHRD
99759  DiskUnmountWatch 0.0  00:00.15 2      1   33     1745K 0B    1488K 99759 1     sleeping  0[0]        0.00000 0.00000    501 2912      78     174        491        4112       1205       1239       2       17        0.0   0      0      xxxxxxxx               N/A    N/A   N/A   N/A   N/A   N/A
98953  zsh              0.0  00:00.82 1      0   21     6449K 0B    6096K 98953 87986 sleeping *0[1]        0.00000 0.00000    501 15809     2691   193        91         252427     201        1058       58      0         0.0   0      0      xxxxxxxx               N/A    N/A   N/A   N/A   N/A   N/A

再过滤出总内存占用这部分数据:

top -l 1 | head -n 10 | grep PhysMemPhysMem: 31G used (2485M wired), 223M unused.

3.2 查看指定进程占用情况

在这个实验中,我们检查一下运行在 MacOS上(通过brew方案安装)的 Hadoop 3.3.1 (伪分布式)各个进程的占用情况。

Hadoop 集群总共包含以下几类进程:

➜  libexec git:(stable) jps -ml72267 org.apache.hadoop.hdfs.server.namenode.NameNode
72369 org.apache.hadoop.hdfs.server.datanode.DataNode
72504 org.apache.hadoop.hdfs.server.namenode.SecondaryNameNode
72779 org.apache.hadoop.yarn.server.resourcemanager.ResourceManager
72878 org.apache.hadoop.yarn.server.nodemanager.NodeManager

根据各自进程ID查询其内存占用大小:

top -pid 72267 -l 1 | tail -n 1 | awk '{print $8}'  #1039M
top -pid 72369 -l 1 | tail -n 1 | awk '{print $8}'  #788M
top -pid 72504 -l 1 | tail -n 1 | awk '{print $8}'  #957M
top -pid 72779 -l 1 | tail -n 1 | awk '{print $8}'  #495M
top -pid 72878 -l 1 | tail -n 1 | awk '{print $8}'  #500M

重要说明:
1、关于命令行参数:

【-l 1】只执行1次
【tail -n 1】取最后一条结果

2、关于内存计算方式在Linux与MacOS上的区别

MacOS与Linux在计算内存方式上还是不太一样的:
A). 对于Linux系统, 如果要查看某个进程的内存使用情况,通常有两种统计方式:
(1)实际使用内存;
(2)实际使用内存 + cache使用内存。
B). 对于 MacOS系统, 在统计内存使用时,一般还有个交换内存SwSS的概念,即"Swap" Set Size,指交换内存的大小。
虚拟内存指的是一个程序程序运行时,使用的内存空间。
虚拟内存的大小一般使用 VSS(Virtual Set Size)表示。
.
它的大小一般这样计算:
.
VSS = RSS + LSS + SwSS
.

  • RSS 的全称为:Resident Set Size,表示当前程序进程实际使用的内存大小。
  • LSS 的全称为:“Lazy” Set Size,表示系统同意给程序进程分配的,但是还没分配完成的内存大小。
  • SwSS 的全称为:“Swap” Set Size,指交换内存的大小,与 MacOS 不同,iOS 没有交换内存(一般Mobile device的实际存储空间比较有限)。

3.3 通过MacOS内置的GUI工具“活动监视器”查看指定进程占用情况


这里可以看出,GUI工具检测出的内存占用,与命令行里查出来的内存大小,在数据上保持着高度的一致。

3.4 通过Python psutil 库包工具查看

1、查看总内存占用情况

print(psu.virtual_memory())
svmem(total=34359738368, available=9667969024, percent=71.9, used=13218136064, free=350289920, active=9313632256, inactive=9304948736, wired=3904503808)print(psu.swap_memory())
sswap(total=1073741824, used=81264640, free=992477184, percent=7.6, sin=580224942080, sout=4288872448)

2、查看单个进程的内存占用情况

import psutil as pp = psu.Process(72267) # 根据NameNode进程 对应的PID获取进程对象# ------------------------------ 该进程内存使用相关信息 ------------------------------
print(p.memory_info())
pmem(rss=150732800, vms=430260076544, pfaults=492147, pageins=22)# ------------------------------ 以下为进程其他相关信息 ------------------------------
print(p.cpu_times())
pcputimes(user=395.442651136, system=296.736718848, children_user=0.0, children_system=0.0)print(p.name)
<bound method Process.name of psutil.Process(pid=72267, name='java', status='running', started='2023-05-20 18:15:29')>print(p.exe())
/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/bin/javaprint(p.cwd())
/Users/xxxxxprint(p.cmdline())
['/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/bin/java', '-Dproc_namenode', '-Djava.net.preferIPv4Stack=true', '-Dhdfs.audit.logger=INFO,NullAppender', '-Dhadoop.security.logger=INFO,RFAS', '-Dyarn.log.dir=/opt/homebrew/Cellar/hadoop/3.3.1/libexec/logs', '-Dyarn.log.file=hadoop-xxxxx-namenode-xxxxx.lan.log', '-Dyarn.home.dir=/opt/homebrew/Cellar/hadoop/3.3.1/libexec', '-Dyarn.root.logger=INFO,console', '-Dhadoop.log.dir=/opt/homebrew/Cellar/hadoop/3.3.1/libexec/logs', '-Dhadoop.log.file=hadoop-xxxxx-namenode-xxxxx.lan.log', '-Dhadoop.home.dir=/opt/homebrew/Cellar/hadoop/3.3.1/libexec', '-Dhadoop.id.str=xxxxx', '-Dhadoop.root.logger=INFO,RFA', '-Dhadoop.policy.file=hadoop-policy.xml', 'org.apache.hadoop.hdfs.server.namenode.NameNode']print(p.ppid)
<bound method Process.ppid of psutil.Process(pid=72267, name='java', status='running', started='2023-05-20 18:15:29')>print(p.parent())
psutil.Process(pid=1, name='launchd', status='running', started='2022-12-29 22:43:40')print(p.children)
<bound method Process.children of psutil.Process(pid=72267, name='java', status='running', started='2023-05-20 18:15:29')>print(p.status())
runningprint(p.username())
xxxxxprint(p.create_time())
1684577729.270895print(p.terminate)
<bound method Process.terminate of psutil.Process(pid=72267, name='java', status='running', started='2023-05-20 18:15:29')>print(p.open_files())
[popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/logs/hadoop-xxx-namenode-xxxxx.lan.out', fd=1), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/logs/hadoop-xxx-namenode-xxxxx.lan.out', fd=2), popenfile(path='/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/jre/lib/rt.jar', fd=3), popenfile(path='/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/jre/lib/jfr.jar', fd=4), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jetty-util-ajax-9.4.40.v20210413.jar', fd=5), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jaxb-impl-2.2.3-1.jar', fd=6), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/hadoop-auth-3.3.1.jar', fd=7), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/curator-framework-4.2.0.jar', fd=8), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jackson-core-2.10.5.jar', fd=9), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-io-2.8.0.jar', fd=10), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/slf4j-log4j12-1.7.30.jar', fd=11), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jetty-webapp-9.4.40.v20210413.jar', fd=12), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/htrace-core4-4.1.0-incubating.jar', fd=13), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerby-xdr-1.0.1.jar', fd=14), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/failureaccess-1.0.jar', fd=15), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/checker-qual-2.5.2.jar', fd=16), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/curator-client-4.2.0.jar', fd=17), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/httpcore-4.4.13.jar', fd=18), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/slf4j-api-1.7.30.jar', fd=19), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/snappy-java-1.1.8.2.jar', fd=20), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jackson-jaxrs-1.9.13.jar', fd=21), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-logging-1.1.3.jar', fd=22), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/hadoop-annotations-3.3.1.jar', fd=23), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerby-pkix-1.0.1.jar', fd=24), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/woodstox-core-5.3.0.jar', fd=25), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/avro-1.7.7.jar', fd=26), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/dnsjava-2.1.7.jar', fd=27), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jetty-io-9.4.40.v20210413.jar', fd=28), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/javax.servlet-api-3.1.0.jar', fd=29), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerb-server-1.0.1.jar', fd=30), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/hadoop-shaded-guava-1.1.1.jar', fd=31), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/log4j-1.2.17.jar', fd=32), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-cli-1.2.jar', fd=33), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/guava-27.0-jre.jar', fd=34), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/protobuf-java-2.5.0.jar', fd=35), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jcip-annotations-1.0-1.jar', fd=36), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerby-asn1-1.0.1.jar', fd=37), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jsr311-api-1.1.1.jar', fd=38), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/stax2-api-4.2.1.jar', fd=39), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jackson-xc-1.9.13.jar', fd=40), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerb-identity-1.0.1.jar', fd=41), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerby-config-1.0.1.jar', fd=42), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jetty-server-9.4.40.v20210413.jar', fd=43), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jetty-util-9.4.40.v20210413.jar', fd=44), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerb-util-1.0.1.jar', fd=45), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jersey-json-1.19.jar', fd=46), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jersey-servlet-1.19.jar', fd=47), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jul-to-slf4j-1.7.30.jar', fd=48), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/zookeeper-jute-3.5.6.jar', fd=49), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jetty-servlet-9.4.40.v20210413.jar', fd=50), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jaxb-api-2.2.11.jar', fd=51), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-configuration2-2.1.1.jar', fd=52), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jakarta.activation-api-1.2.1.jar', fd=53), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jackson-core-asl-1.9.13.jar', fd=54), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/curator-recipes-4.2.0.jar', fd=55), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar', fd=56), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/metrics-core-3.2.4.jar', fd=57), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/accessors-smart-2.4.2.jar', fd=58), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jsp-api-2.1.jar', fd=59), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerb-crypto-1.0.1.jar', fd=60), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-codec-1.11.jar', fd=61), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/asm-5.0.4.jar', fd=62), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerb-admin-1.0.1.jar', fd=63), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/audience-annotations-0.5.0.jar', fd=64), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/j2objc-annotations-1.1.jar', fd=65), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/paranamer-2.3.jar', fd=66), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerb-client-1.0.1.jar', fd=67), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-collections-3.2.2.jar', fd=68), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jettison-1.1.jar', fd=69), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/netty-3.10.6.Final.jar', fd=70), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-compress-1.19.jar', fd=71), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jackson-databind-2.10.5.1.jar', fd=72), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/token-provider-1.0.1.jar', fd=73), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jetty-http-9.4.40.v20210413.jar', fd=74), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jersey-core-1.19.jar', fd=75), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-beanutils-1.9.4.jar', fd=76), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerb-common-1.0.1.jar', fd=77), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-text-1.4.jar', fd=78), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerb-simplekdc-1.0.1.jar', fd=79), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jackson-annotations-2.10.5.jar', fd=80), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jersey-server-1.19.jar', fd=81), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jsch-0.1.55.jar', fd=82), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/re2j-1.1.jar', fd=83), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/gson-2.2.4.jar', fd=84), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jetty-xml-9.4.40.v20210413.jar', fd=85), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerb-core-1.0.1.jar', fd=86), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/nimbus-jose-jwt-9.8.1.jar', fd=87), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/httpclient-4.5.13.jar', fd=88), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/animal-sniffer-annotations-1.17.jar', fd=89), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-net-3.6.jar', fd=90), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-lang3-3.7.jar', fd=91), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/kerby-util-1.0.1.jar', fd=92), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jsr305-3.0.2.jar', fd=93), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jackson-mapper-asl-1.9.13.jar', fd=94), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-math3-3.1.1.jar', fd=95), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/jetty-security-9.4.40.v20210413.jar', fd=96), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/commons-daemon-1.0.13.jar', fd=97), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/json-smart-2.4.2.jar', fd=98), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/hadoop-shaded-protobuf_3_7-1.1.1.jar', fd=99), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/zookeeper-3.5.6.jar', fd=100), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/hadoop-nfs-3.3.1.jar', fd=101), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/hadoop-common-3.3.1-tests.jar', fd=102), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/hadoop-common-3.3.1.jar', fd=103), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/hadoop-registry-3.3.1.jar', fd=104), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/hadoop-kms-3.3.1.jar', fd=105), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jetty-util-ajax-9.4.40.v20210413.jar', fd=106), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jaxb-impl-2.2.3-1.jar', fd=107), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/hadoop-auth-3.3.1.jar', fd=108), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/curator-framework-4.2.0.jar', fd=109), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jackson-core-2.10.5.jar', fd=110), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-io-2.8.0.jar', fd=111), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jetty-webapp-9.4.40.v20210413.jar', fd=112), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/htrace-core4-4.1.0-incubating.jar', fd=113), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerby-xdr-1.0.1.jar', fd=114), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/failureaccess-1.0.jar', fd=115), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/checker-qual-2.5.2.jar', fd=116), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/curator-client-4.2.0.jar', fd=117), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/httpcore-4.4.13.jar', fd=118), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/snappy-java-1.1.8.2.jar', fd=119), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jackson-jaxrs-1.9.13.jar', fd=120), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-logging-1.1.3.jar', fd=121), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/hadoop-annotations-3.3.1.jar', fd=122), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerby-pkix-1.0.1.jar', fd=123), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/woodstox-core-5.3.0.jar', fd=124), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/avro-1.7.7.jar', fd=125), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/dnsjava-2.1.7.jar', fd=126), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jetty-io-9.4.40.v20210413.jar', fd=127), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/javax.servlet-api-3.1.0.jar', fd=128), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerb-server-1.0.1.jar', fd=129), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/hadoop-shaded-guava-1.1.1.jar', fd=130), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/log4j-1.2.17.jar', fd=131), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-cli-1.2.jar', fd=132), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/guava-27.0-jre.jar', fd=133), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/protobuf-java-2.5.0.jar', fd=134), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jcip-annotations-1.0-1.jar', fd=135), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerby-asn1-1.0.1.jar', fd=136), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jsr311-api-1.1.1.jar', fd=137), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/stax2-api-4.2.1.jar', fd=138), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jackson-xc-1.9.13.jar', fd=139), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerb-identity-1.0.1.jar', fd=140), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerby-config-1.0.1.jar', fd=141), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jetty-server-9.4.40.v20210413.jar', fd=142), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jetty-util-9.4.40.v20210413.jar', fd=143), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerb-util-1.0.1.jar', fd=144), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/okio-1.6.0.jar', fd=145), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jersey-json-1.19.jar', fd=146), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jersey-servlet-1.19.jar', fd=147), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/zookeeper-jute-3.5.6.jar', fd=148), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jetty-servlet-9.4.40.v20210413.jar', fd=149), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jaxb-api-2.2.11.jar', fd=150), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/json-simple-1.1.1.jar', fd=151), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-configuration2-2.1.1.jar', fd=152), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jakarta.activation-api-1.2.1.jar', fd=153), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jackson-core-asl-1.9.13.jar', fd=154), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/curator-recipes-4.2.0.jar', fd=155), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar', fd=156), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/accessors-smart-2.4.2.jar', fd=157), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/okhttp-2.7.5.jar', fd=158), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerb-crypto-1.0.1.jar', fd=159), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-codec-1.11.jar', fd=160), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/asm-5.0.4.jar', fd=161), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerb-admin-1.0.1.jar', fd=162), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/audience-annotations-0.5.0.jar', fd=163), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/j2objc-annotations-1.1.jar', fd=164), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/paranamer-2.3.jar', fd=165), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerb-client-1.0.1.jar', fd=166), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-collections-3.2.2.jar', fd=167), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jettison-1.1.jar', fd=168), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/netty-3.10.6.Final.jar', fd=169), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-compress-1.19.jar', fd=170), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jackson-databind-2.10.5.1.jar', fd=171), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/token-provider-1.0.1.jar', fd=172), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jetty-http-9.4.40.v20210413.jar', fd=173), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jersey-core-1.19.jar', fd=174), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-beanutils-1.9.4.jar', fd=175), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerb-common-1.0.1.jar', fd=176), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-text-1.4.jar', fd=177), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerb-simplekdc-1.0.1.jar', fd=178), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jackson-annotations-2.10.5.jar', fd=179), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jersey-server-1.19.jar', fd=180), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jsch-0.1.55.jar', fd=181), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/re2j-1.1.jar', fd=182), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/gson-2.2.4.jar', fd=183), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jetty-xml-9.4.40.v20210413.jar', fd=184), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerb-core-1.0.1.jar', fd=185), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/nimbus-jose-jwt-9.8.1.jar', fd=186), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/httpclient-4.5.13.jar', fd=187), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/netty-all-4.1.61.Final.jar', fd=188), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/animal-sniffer-annotations-1.17.jar', fd=189), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/leveldbjni-all-1.8.jar', fd=190), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-net-3.6.jar', fd=191), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-lang3-3.7.jar', fd=192), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/kerby-util-1.0.1.jar', fd=193), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jsr305-3.0.2.jar', fd=194), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jackson-mapper-asl-1.9.13.jar', fd=195), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-math3-3.1.1.jar', fd=196), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/jetty-security-9.4.40.v20210413.jar', fd=197), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/commons-daemon-1.0.13.jar', fd=198), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/json-smart-2.4.2.jar', fd=199), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/hadoop-shaded-protobuf_3_7-1.1.1.jar', fd=200), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/zookeeper-3.5.6.jar', fd=201), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/hadoop-hdfs-3.3.1.jar', fd=202), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/hadoop-hdfs-client-3.3.1.jar', fd=203), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/hadoop-hdfs-3.3.1-tests.jar', fd=204), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/hadoop-hdfs-rbf-3.3.1.jar', fd=205), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/hadoop-hdfs-native-client-3.3.1.jar', fd=206), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/hadoop-hdfs-httpfs-3.3.1.jar', fd=207), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/hadoop-hdfs-client-3.3.1-tests.jar', fd=208), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/hadoop-hdfs-nfs-3.3.1.jar', fd=209), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/hadoop-hdfs-rbf-3.3.1-tests.jar', fd=210), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/hadoop-hdfs-native-client-3.3.1-tests.jar', fd=211), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/hadoop-mapreduce-client-jobclient-3.3.1.jar', fd=212), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/hadoop-mapreduce-client-common-3.3.1.jar', fd=213), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/hadoop-mapreduce-client-shuffle-3.3.1.jar', fd=214), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/hadoop-mapreduce-examples-3.3.1.jar', fd=215), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/hadoop-mapreduce-client-core-3.3.1.jar', fd=216), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/hadoop-mapreduce-client-uploader-3.3.1.jar', fd=217), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/hadoop-mapreduce-client-hs-3.3.1.jar', fd=218), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/hadoop-mapreduce-client-hs-plugins-3.3.1.jar', fd=219), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/hadoop-mapreduce-client-jobclient-3.3.1-tests.jar', fd=220), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/hadoop-mapreduce-client-app-3.3.1.jar', fd=221), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/hadoop-mapreduce-client-nativetask-3.3.1.jar', fd=222), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/javax.websocket-api-1.0.jar', fd=223), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jakarta.xml.bind-api-2.3.2.jar', fd=224), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jackson-jaxrs-base-2.10.5.jar', fd=225), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jersey-guice-1.19.jar', fd=226), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/aopalliance-1.0.jar', fd=227), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/asm-analysis-9.0.jar', fd=228), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/java-util-1.9.0.jar', fd=229), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/websocket-servlet-9.4.40.v20210413.jar', fd=230), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/websocket-api-9.4.40.v20210413.jar', fd=231), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/asm-tree-9.0.jar', fd=232), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jersey-client-1.19.jar', fd=233), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/geronimo-jcache_1.0_spec-1.0-alpha-1.jar', fd=234), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/objenesis-2.6.jar', fd=235), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jackson-jaxrs-json-provider-2.10.5.jar', fd=236), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jline-3.9.0.jar', fd=237), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jetty-annotations-9.4.40.v20210413.jar', fd=238), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/websocket-client-9.4.40.v20210413.jar', fd=239), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/asm-commons-9.0.jar', fd=240), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/fst-2.50.jar', fd=241), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/guice-servlet-4.0.jar', fd=242), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/snakeyaml-1.26.jar', fd=243), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/mssql-jdbc-6.2.1.jre7.jar', fd=244), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/websocket-common-9.4.40.v20210413.jar', fd=245), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jetty-plus-9.4.40.v20210413.jar', fd=246), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/metrics-core-3.2.4.jar', fd=247), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jetty-jndi-9.4.40.v20210413.jar', fd=248), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/javax-websocket-server-impl-9.4.40.v20210413.jar', fd=249), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/javax.websocket-client-api-1.0.jar', fd=250), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/javax-websocket-client-impl-9.4.40.v20210413.jar', fd=251), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/ehcache-3.3.1.jar', fd=252), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jetty-client-9.4.40.v20210413.jar', fd=253), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/bcprov-jdk15on-1.60.jar', fd=254), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/HikariCP-java7-2.4.12.jar', fd=255), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jna-5.2.0.jar', fd=256), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/json-io-2.5.1.jar', fd=257), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/guice-4.0.jar', fd=258), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/javax.inject-1.jar', fd=259), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/jackson-module-jaxb-annotations-2.10.5.jar', fd=260), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/bcpkix-jdk15on-1.60.jar', fd=261), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/swagger-annotations-1.5.4.jar', fd=262), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/websocket-server-9.4.40.v20210413.jar', fd=263), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-client-3.3.1.jar', fd=264), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-services-api-3.3.1.jar', fd=265), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-server-router-3.3.1.jar', fd=266), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-applications-mawo-core-3.3.1.jar', fd=267), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-services-core-3.3.1.jar', fd=268), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-server-resourcemanager-3.3.1.jar', fd=269), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-server-common-3.3.1.jar', fd=270), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-server-web-proxy-3.3.1.jar', fd=271), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-server-nodemanager-3.3.1.jar', fd=272), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-common-3.3.1.jar', fd=273), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-api-3.3.1.jar', fd=274), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-server-tests-3.3.1.jar', fd=275), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-server-applicationhistoryservice-3.3.1.jar', fd=276), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-applications-unmanaged-am-launcher-3.3.1.jar', fd=277), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-server-sharedcachemanager-3.3.1.jar', fd=278), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-registry-3.3.1.jar', fd=279), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-server-timeline-pluginstorage-3.3.1.jar', fd=280), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/hadoop-yarn-applications-distributedshell-3.3.1.jar', fd=281), popenfile(path='/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/jre/lib/ext/cldrdata.jar', fd=282), popenfile(path='/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/jre/lib/ext/localedata.jar', fd=283), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/logs/hadoop-xxx-namenode-xxxxx.lan.log', fd=284), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/logs/SecurityAuth-xxx.audit', fd=285), popenfile(path='/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/jre/lib/jsse.jar', fd=288), popenfile(path='/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/jre/lib/jce.jar', fd=313), popenfile(path='/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/jre/lib/ext/sunec.jar', fd=314), popenfile(path='/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/jre/lib/ext/sunjce_provider.jar', fd=315), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/tmp/dfs/name/in_use.lock', fd=316), popenfile(path='/opt/homebrew/Cellar/hadoop/3.3.1/libexec/tmp/dfs/name/current/edits_inprogress_0000000000000000443', fd=317), popenfile(path='/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/jre/lib/resources.jar', fd=335), popenfile(path='/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/jre/lib/charsets.jar', fd=346)]print(p.connections())
[pconn(fd=295, family=<AddressFamily.AF_INET: 2>, type=<SocketKind.SOCK_STREAM: 1>, laddr=addr(ip='0.0.0.0', port=9870), raddr=(), status='LISTEN'), pconn(fd=318, family=<AddressFamily.AF_INET: 2>, type=<SocketKind.SOCK_STREAM: 1>, laddr=addr(ip='127.0.0.1', port=8020), raddr=(), status='LISTEN'), pconn(fd=328, family=<AddressFamily.AF_INET: 2>, type=<SocketKind.SOCK_STREAM: 1>, laddr=addr(ip='127.0.0.1', port=8020), raddr=addr(ip='127.0.0.1', port=60487), status='ESTABLISHED')]print(p.num_threads())
67print(p.environ())
{'SHELL': '/bin/zsh', 'HADOOP_HOME': '/opt/homebrew/Cellar/hadoop/3.3.1/libexec', 'TMPDIR': '/var/folders/5h/m9864cxd4hg9qr469_wgt2q40000gn/T/', 'SSH_CLIENT': '::1 60471 22', 'HDFS_NFS3_SECURE_EXTRA_OPTS': '-jvm server', 'HDFS_DATANODE_SECURE_EXTRA_OPTS': '-jvm server', 'HDFS_DATANODE_OPTS': '-Dhadoop.security.logger=ERROR,RFAS', 'HDFS_PORTMAP_OPTS': '-Xmx512m', 'USER': 'xxxx', 'HDFS_SECONDARYNAMENODE_OPTS': '-Dhadoop.security.logger=INFO,RFAS', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'HADOOP_ENV_PROCESSED': 'true', 'HADOOP_HDFS_HOME': '/opt/homebrew/Cellar/hadoop/3.3.1/libexec', 'HADOOP_COMMON_HOME': '/opt/homebrew/Cellar/hadoop/3.3.1/libexec', 'PWD': '/Users/xxx', 'HADOOP_YARN_HOME': '/opt/homebrew/Cellar/hadoop/3.3.1/libexec', 'JAVA_HOME': '/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home', 'HADOOP_OS_TYPE': 'Darwin', 'HADOOP_CONF_DIR': '/opt/homebrew/Cellar/hadoop/3.3.1/libexec/etc/hadoop', 'LANG': 'zh_CN.UTF-8', 'HADOOP_OPTS': '-Djava.net.preferIPv4Stack=true -Dhdfs.audit.logger=INFO,NullAppender -Dhadoop.security.logger=INFO,RFAS -Dyarn.log.dir=/opt/homebrew/Cellar/hadoop/3.3.1/libexec/logs -Dyarn.log.file=hadoop-xxx-namenode-xxxxx.lan.log -Dyarn.home.dir=/opt/homebrew/Cellar/hadoop/3.3.1/libexec -Dyarn.root.logger=INFO,console -Dhadoop.log.dir=/opt/homebrew/Cellar/hadoop/3.3.1/libexec/logs -Dhadoop.log.file=hadoop-xxx-namenode-xxxxx.lan.log -Dhadoop.home.dir=/opt/homebrew/Cellar/hadoop/3.3.1/libexec -Dhadoop.id.str=xxx -Dhadoop.root.logger=INFO,RFA -Dhadoop.policy.file=hadoop-policy.xml', 'SHLVL': '0', 'HOME': '/Users/xxx', 'HADOOP_MAPRED_HOME': '/opt/homebrew/Cellar/hadoop/3.3.1/libexec', 'LOGNAME': 'xxx', 'CLASSPATH': '/opt/homebrew/Cellar/hadoop/3.3.1/libexec/etc/hadoop:/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/lib/*:/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/common/*:/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs:/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/lib/*:/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/hdfs/*:/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/mapreduce/*:/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn:/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/lib/*:/opt/homebrew/Cellar/hadoop/3.3.1/libexec/share/hadoop/yarn/*', 'SSH_CONNECTION': '::1 60471 ::1 22', 'HDFS_NAMENODE_OPTS': '-Dhadoop.security.logger=INFO,RFAS', 'HDFS_AUDIT_LOGGER': 'INFO,NullAppender'}

MacOS怎么查看进程占用内存是多少相关推荐

  1. ps aux排序 (查看进程占用内存和cpu)

    查看进程占用内存和cpu: ps aux排序 按内存升序排列: ps aux --sort=+rss 按内存降序排列: ps aux --sort=-rss 按cpu升序排列: ps aux --so ...

  2. linux查看进程占用的内存大小,查看进程占用内存大小的几种方法,占用内存几种方法...

    查看进程占用内存大小的几种方法,占用内存几种方法 1. pmap -x pid 2. ps -aux | grep 进程名 ps -e -o 'pid,comm,args,pcpu,rsz,vsz,s ...

  3. 如何查看进程占用内存的大小以及物理内存和虚拟内存的区别

    概述 想必在linux上写过程序的同学都有分析进程占用多少内存的经历,或者被问到这样的问题--你的程序在运行时占用了多少内存(物理内存)?通常我们可以通过top命令查看进程占用了多少内存.这里我们可以 ...

  4. 查看进程占用内存cpu信息,Linux命令—TOP

    我们使用top命令来查看CPU使用状况. top不会产生输出,屏幕内容保持不变.它刷新屏幕以显示新信息.因此,如果您只执行top并保持屏幕一直开启,则屏幕始终显示最新信息.退出top的命令为q,或者按 ...

  5. centos7查看进程ps_Linux/Centos查看进程占用内存大小的几种方法总结

    1.命令行输入top回车,然后按下大写M按照memory排序,按下大写P按照CPU排序. 2. ps -ef | grep "进程名" ps -e -o 'pid,comm,arg ...

  6. aix查看oracle进程内存,Aix 查看进程占用内存大小(按从大小排列)

    主要通过以下两条命令进行观察,单位为K RSS表示the amount of real memory size of the process (in 1KB units). # ps aux | he ...

  7. 查看linux每个进程占用内存多少,Linux下如何查看哪个进程占用内存多?

    1.top top命令是Linux下常用的性能分析工具,能够实时显示系统中各个进程的资源占用状况,类似于Windows的任务管理器 可以直接使用top命令后,查看%MEM的内容.可以选择按进程查看或者 ...

  8. linux:进程占用的端口,在linux中查看进程占用的端口号

    在Linux 上的 /etc/services 文件可以查看到更多关于保留端口的信息. 可以使用以下六种方法查看端口信息. ss:可以用于转储套接字统计信息. netstat:可以显示打开的套接字列表 ...

  9. linux查看进程的内存使用情况,[转]linux下查看进程内存使用情况

    动态查看一个进程的内存使用 1.top命令 top -d 1 -p pid [,pid ...] //设置为delay 1s,默认是delay 3s 如果想根据内存使用量进行排序,可以shift + ...

最新文章

  1. Android如何防止apk程序被反编译
  2. 在JSP页面中显示动态时间
  3. ArduinoYun教程之Arduino环境与Linux环境的桥梁Bridge
  4. php 数组插入键和值,php数组中键和值的关系
  5. Qt-在控件上绘图的方式
  6. 【DRP】【SQL】-悲观锁-防止多用户同时操作时出现脏数据
  7. 为什么越有钱的人越轻松
  8. poj 2406 Power Strings(KMP)
  9. javascript 正则
  10. 网络---NAT技术与代理服务器调研
  11. java 获取linux 服务器字体_Java获得本地字体列表
  12. 「镁客·请讲」中科云创周北川:从数据到云端,我们要上下打通工业物联网产业链...
  13. 0045-量化第十天:QMT-以DMA指标为例调用系统指标
  14. 分类计数原理与分步计数原理_分类加法计数原理与分步乘法计数原理的解题策略之一...
  15. 解决 撤销键 Ctrl+Z 不能撤销的问题
  16. Python写接口api
  17. 英文文献翻译的APP
  18. LSTM长短期记忆网络
  19. 基于OpenCV的二维码和条形码识别
  20. JS-写一个函数,返回参数的平方和

热门文章

  1. axios的使用和封装(九)
  2. linux中的tar打包、压缩多个文件、磁盘查看和分区类、du查看文件和目录占用的磁盘空间
  3. 640小时印尼语手机采集语音数据
  4. 大二项目实战:使用flutter开发的学生端app【云山印尼语学习辅助平台】
  5. leetcode每日打卡_1646
  6. 猿创征文|计算机类学生必知必会的开发工具
  7. 详细总结流行前端框架Vue重难点概念
  8. Python爬取最近上映的电影评论并生成词云——误杀
  9. 微信小程序1s变黑白
  10. 安全漏洞评分系统(CVSS)