参考:https://blog.csdn.net/sinat_33718563/article/details/97752990
ps -ef | grep iquota-server
使用ps -aux | grep pID号查看
ps -aux | grep 57128
返回
root 54345 0.0 0.0 112712 960 pts/1 S+ 09:12 0:00 grep --color=auto 57128
root 57128 4.6 12.9 7360812 1032748 ? Sl Apr15 129:57 java -Xms1024m -Xmx2048m -XX:-UseGCOverheadLimit -DMYSQL_USERNAME=root -DMYSQL_PASSWORD=mysql@dongri -DREDIS_PASSWORD=redis@dongri! -jar /data/build/dataacquisition/iif-da-service-1.0.0.jar
其中下面的
4.6 cpu占用率
12.9 内存占用率
7360812 系统总内存
1032748 进程占用内存
使用top -p PID查看总体占用资源概况
top -p 57128
top - 09:19:40 up 2 days, 16:32, 2 users, load average: 0.00, 0.01, 0.05
Tasks: 1 total, 0 running, 1 sleeping, 0 stopped, 0 zombie
%Cpu(s): 0.5 us, 0.1 sy, 0.0 ni, 99.3 id, 0.0 wa, 0.0 hi, 0.0 si, 0.1 st
KiB Mem : 7982128 total, 5499464 free, 1569704 used, 912960 buff/cache
KiB Swap: 8257532 total, 8257532 free, 0 used. 6145840 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
57128 root 20 0 7360812 1.0g 14100 S 4.3 12.9 130:16.58 java