top命令

top命令

显示进程所占的系统资源

每隔3秒变1次。把占用系统资源最高的进程放到最前面。

1[root@localhost ~]# top 2top - 03:56:02 up 3:46, 2 users, load average: 0.05, 0.03, 0.05 3Tasks: 105 total, 1 running, 103 sleeping, 1 stopped, 0 zombie 4%Cpu(s): 0.2 us, 0.0 sy, 0.0 ni, 99.8 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st 5KiB Mem : 1867048 total, 1513124 free, 156416 used, 197508 buff/cache 6KiB Swap: 2097148 total, 2097148 free, 0 used. 1522536 avail Mem 7 8 PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 9 1368 root 20 0 0 0 0 S 0.3 0.0 0:14.74 kworker/0:0 10 1 root 20 0 128164 6828 4056 S 0.0 0.4 0:01.65 systemd 11 2 root 20 0 0 0 0 S 0.0 0.0 0:00.03 kthreadd 12 3 root 20 0 0 0 0 S 0.0 0.0 0:00.07 ksoftirqd/0 13 5 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 kworker/0:0H 14 6 root 20 0 0 0 0 S 0.0 0.0 0:00.24 kworker/u256:0 15 7 root rt 0 0 0 0 S 0.0 0.0 0:00.01 migration/0 16 8 root 20 0 0 0 0 S 0.0 0.0 0:00.00 rcu_bh 17 9 root 20 0 0 0 0 S 0.0 0.0 0:01.95 rcu_sched 18 10 root rt 0 0 0 0 S 0.0 0.0 0:00.10 watchdog/0 19 11 root rt 0 0 0 0 S 0.0 0.0 0:00.10 watchdog/1 20 12 root rt 0 0 0 0 S 0.0 0.0 0:00.01 migration/1 21 13 root 20 0 0 0 0 S 0.0 0.0 0:00.07 ksoftirqd/1 22 15 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 kworker/1:0H 23 17 root 20 0 0 0 0 S 0.0 0.0 0:00.00 kdevtmpfs 24 18 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 netns 25 19 root 20 0 0 0 0 S 0.0 0.0 0:00.00 khungtaskd 26 20 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 writeback 27 21 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 kintegrityd 28 22 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 bioset 29 23 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 kblockd

关注:RES这一项为进程所占内存的大小。

%MEM为使用内存的百分比。

nload 命令  监控网卡流量

出现错误如下所示:

1[root@localhost ~]# yum install -y nload 2已加载插件:fastestmirror 3Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&infra=stock error was 414: curl#7 - "Failed connect to mirrorlist.centos.org:80; 没有到主机的路由" 5 6 7 One of the configured repositories failed (未知), 8 and yum doesn't have enough cached data to continue. At this point the only 9 safe thing yum can do is fail. There are a few ways to work "fix" this: 10 11 1. Contact the upstream for the repository and get them to fix the problem. 12 13 2. Reconfigure the baseurl/etc. for the repository, to point to a working 14 upstream. This is most often useful if you are using a newer 15 distribution release than is supported by the repository (and the 16 packages for the previous distribution release still work). 17 18 3. Run the command with the repository temporarily disabled 19 yum --disablerepo=<repoid> ... 20 21 4. Disable the repository permanently, so yum won't use it by default. Yum 22 will then just ignore the repository until you permanently enable it 23 again or use --enablerepo for temporary usage: 24 25 yum-config-manager --disable <repoid> 26 or 27 subscription-manager repos --disable=<repoid> 28 29 5. Configure the failing repository to be skipped, if it is unavailable. 30 Note that yum will try to contact the repo. when it runs most commands, 31 so will have to try and fail each time (and thus. yum will be be much 32 slower). If it is a very temporary problem though, this is often a nice 33 compromise: 34 35 yum-config-manager --save --setopt=<repoid>.skip_if_unavailable=true 36 37Cannot find a valid baseurl for repo: base/7/x86_64
点赞
收藏

评论区

加载中...

相关推荐

MySQL:[Err] 1292 - Incorrect datetime value: ‘0000-00-00 00:00:00‘ for column ‘CREATE_TIME‘ at row 1

文章目录问题用navicat导入数据时,报错:原因这是因为当前的MySQL不支持datetime为0的情况。解决修改sql\mode:sql\mode:SQLMode定义了MySQL应支持的SQL语法、数据校验等,这样可以更容易地在不同的环境中使用MySQL。全局s

Oracle 分组与拼接字符串同时使用

SELECTT.,ROWNUMIDFROM(SELECTT.EMPLID,T.NAME,T.BU,T.REALDEPART,T.FORMATDATE,SUM(T.S0)S0,MAX(UPDATETIME)CREATETIME,LISTAGG(TOCHAR(

MySQL部分从库上面因为大量的临时表tmp_table造成慢查询

背景描述Time:20190124T00:08:14.70572408:00User@Host:@Id:Schema:sentrymetaLast_errno:0Killed:0Query_time:0.315758Lock_

手写Java HashMap源码

HashMap的使用教程HashMap的使用教程HashMap的使用教程HashMap的使用教程HashMap的使用教程22

2020年前端实用代码段,为你的工作保驾护航

有空的时候,自己总结了几个代码段,在开发中也经常使用,谢谢。1、使用解构获取json数据let jsonData  id: 1,status: "OK",data: 'a', 'b';let  id, status, data: number   jsonData;console.log(id, status, number )

4、jstack查看线程栈信息

1、介绍利用jps、top、jstack命令找到进程中耗时最大的线程,以及线程状态等等,同时最后还可以显示出死锁的线程查找:FoundoneJavaleveldeadlock即可1、jps获得进程号!(https://oscimg.oschina.net/oscnet/da00a309fa6