Guest User

Untitled

a guest
Nov 21st, 2017
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 13.76 KB | None | 0 0
  1. $ free -h
  2. total used free shared buffers cached
  3. Mem: 998M 986M 12M 0B 464K 904M
  4. -/+ buffers/cache: 81M 917M
  5. Swap: 511M 511M 0B
  6.  
  7. # swapoff -a
  8. swapoff: /swapfile: swapoff failed: Cannot allocate memory
  9.  
  10. "Overall swap used: 18376 kB"
  11.  
  12. MemTotal: 1022464 kB
  13. MemFree: 14344 kB
  14. Buffers: 192 kB
  15. Cached: 719816 kB
  16. SwapCached: 2212 kB
  17. Active: 304304 kB
  18. Inactive: 657344 kB
  19. Active(anon): 294128 kB
  20. Inactive(anon): 651264 kB
  21. Active(file): 10176 kB
  22. Inactive(file): 6080 kB
  23. Unevictable: 0 kB
  24. Mlocked: 0 kB
  25. HighTotal: 127336 kB
  26. HighFree: 316 kB
  27. LowTotal: 895128 kB
  28. LowFree: 14028 kB
  29. SwapTotal: 524284 kB
  30. SwapFree: 0 kB
  31. Dirty: 4 kB
  32. Writeback: 0 kB
  33. AnonPages: 239528 kB
  34. Mapped: 11968 kB
  35. Shmem: 703760 kB
  36. Slab: 28924 kB
  37. SReclaimable: 12116 kB
  38. SUnreclaim: 16808 kB
  39. KernelStack: 2200 kB
  40. PageTables: 5812 kB
  41. NFS_Unstable: 0 kB
  42. Bounce: 0 kB
  43. WritebackTmp: 0 kB
  44. CommitLimit: 1035516 kB
  45. Committed_AS: 2193368 kB
  46. VmallocTotal: 122880 kB
  47. VmallocUsed: 14092 kB
  48. VmallocChunk: 105548 kB
  49. HardwareCorrupted: 0 kB
  50. AnonHugePages: 0 kB
  51. HugePages_Total: 0
  52. HugePages_Free: 0
  53. HugePages_Rsvd: 0
  54. HugePages_Surp: 0
  55. Hugepagesize: 2048 kB
  56. DirectMap4k: 911352 kB
  57. DirectMap2M: 0 kB
  58.  
  59. top - 22:00:18 up 1 day, 2:34, 4 users, load average: 1,97, 1,25, 0,88
  60. Tasks: 137 total, 3 running, 134 sleeping, 0 stopped, 0 zombie
  61. %Cpu(s): 4,9 us, 3,0 sy, 2,7 ni, 83,2 id, 6,1 wa, 0,0 hi, 0,0 si, 0,0 st
  62. KiB Mem: 1022464 total, 1008788 used, 13676 free, 188 buffers
  63. KiB Swap: 524284 total, 524284 used, 0 free, 719792 cached
  64.  
  65. PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
  66. 7861 stenyak 20 0 6336 1252 976 R 18,0 0,1 0:00.03 top
  67. 5194 isabel 30 10 44372 5344 1404 R 12,0 0,5 0:36.11 glmatrix
  68. 17940 root 20 0 103m 6844 2828 S 6,0 0,7 11:02.21 Xorg
  69. 1 root 20 0 2280 28 0 S 0,0 0,0 0:02.49 init
  70. 2 root 20 0 0 0 0 S 0,0 0,0 0:00.00 kthreadd
  71. 3 root 20 0 0 0 0 S 0,0 0,0 0:15.25 ksoftirqd/0
  72. 5 root 20 0 0 0 0 S 0,0 0,0 0:00.00 kworker/u:0
  73. 6 root rt 0 0 0 0 S 0,0 0,0 0:00.93 migration/0
  74. 7 root rt 0 0 0 0 S 0,0 0,0 0:00.46 watchdog/0
  75. 8 root rt 0 0 0 0 S 0,0 0,0 0:00.73 migration/1
  76. 10 root 20 0 0 0 0 S 0,0 0,0 0:17.30 ksoftirqd/1
  77. 12 root rt 0 0 0 0 S 0,0 0,0 0:00.43 watchdog/1
  78. 13 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 cpuset
  79. 14 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 khelper
  80. 15 root 20 0 0 0 0 S 0,0 0,0 0:00.00 kdevtmpfs
  81. 16 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 netns
  82. 17 root 20 0 0 0 0 S 0,0 0,0 0:00.44 sync_supers
  83. 18 root 20 0 0 0 0 S 0,0 0,0 0:00.00 bdi-default
  84. 19 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 kintegrityd
  85. 20 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 kblockd
  86. 22 root 20 0 0 0 0 S 0,0 0,0 0:00.07 khungtaskd
  87. 23 root 20 0 0 0 0 D 0,0 0,0 2:50.47 kswapd0
  88. 24 root 25 5 0 0 0 S 0,0 0,0 0:00.00 ksmd
  89. 25 root 20 0 0 0 0 S 0,0 0,0 0:00.00 fsnotify_mark
  90. 26 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 crypto
  91. 99 root 20 0 0 0 0 S 0,0 0,0 0:00.00 khubd
  92. 115 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 ata_sff
  93. 116 root 20 0 0 0 0 S 0,0 0,0 0:00.00 scsi_eh_0
  94. 117 root 20 0 0 0 0 S 0,0 0,0 0:00.00 scsi_eh_1
  95. 118 root 20 0 0 0 0 S 0,0 0,0 0:01.66 kworker/u:1
  96. 152 root 20 0 0 0 0 S 0,0 0,0 0:02.12 jbd2/sda1-8
  97. 153 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 ext4-dio-unwrit
  98. 280 root 20 0 2944 352 128 S 0,0 0,0 0:00.30 udevd
  99. 423 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 hd-audio0
  100. 1286 root 20 0 0 0 0 S 0,0 0,0 0:07.06 jbd2/sda2-8
  101. 1287 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 ext4-dio-unwrit
  102. 1561 root 20 0 0 0 0 S 0,0 0,0 0:03.09 flush-8:0
  103. 1603 root 20 0 2376 48 0 S 0,0 0,0 0:00.33 rpcbind
  104. 1634 statd 20 0 2648 68 64 S 0,0 0,0 0:00.00 rpc.statd
  105. 1639 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 rpciod
  106. 1641 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 nfsiod
  107. 1648 root 20 0 2576 0 0 S 0,0 0,0 0:00.00 rpc.idmapd
  108. 2019 root 20 0 29088 976 0 S 0,0 0,1 0:22.26 rsyslogd
  109. 2123 root 20 0 1876 84 24 S 0,0 0,0 0:00.23 acpid
  110. 2161 message+ 20 0 3756 728 0 S 0,0 0,1 0:02.06 dbus-daemon
  111. 2213 daemon 20 0 2152 20 0 S 0,0 0,0 0:00.00 atd
  112. 2231 root 20 0 4488 220 128 S 0,0 0,0 0:00.00 bluetoothd
  113. 2242 root 10 -10 0 0 0 S 0,0 0,0 0:00.00 krfcommd
  114. 2259 avahi 20 0 3272 292 168 S 0,0 0,0 0:00.66 avahi-daemon
  115. 2262 avahi 20 0 3156 24 0 S 0,0 0,0 0:00.00 avahi-daemon
  116. 2265 root 20 0 5968 180 152 S 0,0 0,0 0:00.00 bitlbee
  117. 2271 root 20 0 0 0 0 S 0,0 0,0 0:11.69 kworker/0:2
  118. 2304 root 20 0 19056 700 220 S 0,0 0,1 0:00.75 NetworkManager
  119. 2334 root 20 0 5536 176 108 S 0,0 0,0 0:02.86 cron
  120. 2350 root 20 0 6700 492 152 S 0,0 0,0 0:00.01 sudo
  121. 2351 root 20 0 15304 5880 1428 R 0,0 0,6 61:42.79 iotop
  122. 2359 root 20 0 24256 600 56 S 0,0 0,1 0:01.12 polkitd
  123. 2390 root 20 0 6892 368 180 S 0,0 0,0 0:00.15 modem-manager
  124. 2392 root 20 0 7536 80 0 S 0,0 0,0 0:00.13 cupsd
  125. 2396 root 20 0 20964 516 296 S 0,0 0,1 0:00.15 gdm3
  126. 2712 root 20 0 10068 196 84 S 0,0 0,0 0:11.72 kerneloops
  127. 2714 root 20 0 6896 2108 372 S 0,0 0,2 0:05.69 ddclient - slee
  128. 2802 Debian-+ 20 0 7424 100 40 S 0,0 0,0 0:00.05 exim4
  129. 2877 daemon 20 0 1868 236 172 S 0,0 0,0 0:01.22 uptimed
  130. 2881 root 20 0 6464 208 104 S 0,0 0,0 0:00.27 sshd
  131. 2913 root 20 0 1848 72 8 S 0,0 0,0 0:00.00 minissdpd
  132. 2936 root 20 0 4328 40 36 S 0,0 0,0 0:00.00 getty
  133. 2937 root 20 0 4328 40 36 S 0,0 0,0 0:00.00 getty
  134. 2938 root 20 0 4328 40 36 S 0,0 0,0 0:00.00 getty
  135. 2939 root 20 0 4328 40 36 S 0,0 0,0 0:00.00 getty
  136. 2940 root 20 0 4328 40 36 S 0,0 0,0 0:00.00 getty
  137. 2941 root 20 0 4328 40 36 S 0,0 0,0 0:00.00 getty
  138. 2961 root 20 0 23384 540 156 S 0,0 0,1 0:00.88 accounts-daemon
  139. 2965 root 20 0 29216 292 64 S 0,0 0,0 0:01.35 console-kit-dae
  140. 3050 root 20 0 27408 320 0 S 0,0 0,0 0:00.48 upowerd
  141. 3115 stenyak 20 0 6260 320 84 S 0,0 0,0 0:00.51 screen
  142. 3119 stenyak 20 0 6260 248 40 S 0,0 0,0 0:00.61 screen
  143. 3121 stenyak 20 0 6260 132 16 S 0,0 0,0 0:00.48 screen
  144. 3124 stenyak 20 0 6388 1004 572 S 0,0 0,1 1:33.81 p2p.sh
  145. 3125 stenyak 20 0 34176 5604 1764 S 0,0 0,5 1:57.10 quasselcore
  146. 3129 stenyak 20 0 55268 2972 652 S 0,0 0,3 3:00.32 bot.py
  147. 3280 rtkit 21 1 18980 180 64 S 0,0 0,0 0:01.23 rtkit-daemon
  148. 3367 root 20 0 0 0 0 S 0,0 0,0 0:00.00 kauditd
  149. 3684 root 20 0 2940 340 112 S 0,0 0,0 0:00.00 udevd
  150. 3685 root 20 0 2940 208 0 S 0,0 0,0 0:00.00 udevd
  151. 5845 root 20 0 6444 904 592 S 0,0 0,1 0:00.00 cron
  152. 5876 stenyak 20 0 1932 428 368 S 0,0 0,0 0:00.00 sh
  153. 5878 stenyak 20 0 6048 1232 1080 S 0,0 0,1 0:00.00 memmon.sh
  154. 7857 stenyak 20 0 5060 508 448 S 0,0 0,0 0:00.00 sleep
  155. 9071 root 20 0 9816 860 200 S 0,0 0,1 0:00.10 sshd
  156. 9080 stenyak 20 0 10180 1112 136 S 0,0 0,1 0:06.93 sshd
  157. 9081 stenyak 20 0 9280 3232 148 S 0,0 0,3 0:00.62 bash
  158. 9436 root 20 0 7396 1188 684 S 0,0 0,1 0:07.05 bitlbee
  159. 10285 root 20 0 0 0 0 S 0,0 0,0 0:00.00 kworker/1:0
  160. 12728 stenyak 20 0 7960 2960 648 S 0,0 0,3 23:35.01 htop
  161. 12950 root 20 0 9832 80 76 S 0,0 0,0 0:00.08 sshd
  162. 12955 stenyak 20 0 9832 0 0 S 0,0 0,0 0:00.04 sshd
  163. 12956 stenyak 20 0 9304 36 32 S 0,0 0,0 0:00.64 bash
  164. 17939 root 20 0 23284 1080 320 S 0,0 0,1 0:00.11 gdm-simple-slav
  165. 18062 root 20 0 29808 964 364 S 0,0 0,1 0:00.38 gdm-session-wor
  166. 20066 root 20 0 0 0 0 S 0,0 0,0 0:09.72 kworker/0:0
  167. 28369 isabel 20 0 1932 112 108 S 0,0 0,0 0:00.03 sh
  168. 28404 isabel 20 0 3868 260 68 S 0,0 0,0 0:00.20 ssh-agent
  169. 28407 isabel 20 0 3516 0 0 S 0,0 0,0 0:00.00 dbus-launch
  170. 28408 isabel 20 0 3420 304 116 S 0,0 0,0 0:00.24 dbus-daemon
  171. 28416 isabel 20 0 6344 744 548 S 0,0 0,1 0:00.29 xfconfd
  172. 28422 isabel 20 0 8336 496 248 S 0,0 0,0 0:01.46 xscreensaver
  173. 28424 isabel 20 0 21932 580 340 S 0,0 0,1 0:00.17 xfce4-session
  174. 28430 isabel 20 0 24392 2032 1160 S 0,0 0,2 0:16.32 xfwm4
  175. 28432 isabel 20 0 117m 2072 908 S 0,0 0,2 0:01.26 xfce4-panel
  176. 28434 isabel 20 0 22520 256 256 S 0,0 0,0 0:00.06 Thunar
  177. 28436 isabel 20 0 21016 688 460 S 0,0 0,1 0:00.06 xfsettingsd
  178. 28437 isabel 20 0 119m 3344 1312 S 0,0 0,3 0:03.50 xfdesktop
  179. 28441 isabel 20 0 21072 272 268 S 0,0 0,0 0:00.07 kerneloops-appl
  180. 28443 isabel 20 0 29816 540 228 S 0,0 0,1 0:00.10 polkit-gnome-au
  181. 28450 isabel 20 0 263m 544 276 S 0,0 0,1 0:00.30 xfce4-volumed
  182. 28452 isabel 20 0 63936 488 0 S 0,0 0,0 0:00.31 tracker-store
  183. 28457 isabel 20 0 23240 768 472 S 0,0 0,1 0:00.18 xfce4-settings-
  184. 28460 isabel 9 -11 99532 500 248 S 0,0 0,0 0:00.38 pulseaudio
  185. 28470 isabel 20 0 21936 612 312 S 0,0 0,1 0:00.20 panel-6-systray
  186. 28472 isabel 20 0 339m 1348 552 S 0,0 0,1 0:00.42 xfce4-mixer-plu
  187. 28473 isabel 20 0 22028 2292 1740 S 0,0 0,2 0:59.33 xfce4-oragecloc
  188. 28514 isabel 20 0 371m 21m 2428 S 0,0 2,1 3:46.22 chromium
  189. 28517 isabel 20 0 111m 3020 288 S 0,0 0,3 0:00.58 chromium
  190. 28518 isabel 20 0 1948 64 0 S 0,0 0,0 0:00.00 chromium-sandbo
  191. 28519 isabel 20 0 120m 3324 288 S 0,0 0,3 0:00.20 chromium
  192. 28522 isabel 20 0 128m 3252 204 S 0,0 0,3 0:00.01 chromium
  193. 28558 isabel 20 0 208m 52m 476 S 0,0 5,3 1:25.92 chromium
  194. 28573 isabel 20 0 271m 103m 1244 S 0,0 10,3 3:01.64 chromium
  195. 28693 isabel 20 0 120m 3836 628 S 0,0 0,4 0:43.86 chromium
  196. 28696 isabel 20 0 83088 6412 108 S 0,0 0,6 0:16.55 GoogleTalkPlugi
  197. 28706 isabel 20 0 159m 6896 972 S 0,0 0,7 9:00.72 chromium
  198. 32332 root 20 0 0 0 0 S 0,0 0,0 0:06.24 kworker/1:2
  199. 32351 stenyak 9 -11 99108 1032 192 S 0,0 0,1 0:00.51 pulseaudio
  200. 32455 root 20 0 9816 108 76 S 0,0 0,0 0:00.11 sshd
  201. 32460 stenyak 20 0 9992 264 144 S 0,0 0,0 0:07.43 sshd
  202. 32462 stenyak 20 0 9300 1976 108 S 0,0 0,2 0:01.31 bash
  203.  
  204. if (!quiet || errno == ENOMEM)
  205. warn(_("%s: swapoff failed"), orig_special);
  206.  
  207. return -1;
  208.  
  209. apt-get install smem
  210.  
  211. $ pidof myprocess
  212. 123
  213. $ cat /proc/123/status
  214.  
  215. Name: snapinit
  216. State: S (sleeping)
  217. Tgid: 2769
  218. Ngid: 0
  219. Pid: 2769
  220. PPid: 1
  221. TracerPid: 0
  222. Uid: 0 0 0 0
  223. Gid: 0 0 0 0
  224. FDSize: 64
  225. Groups:
  226. NStgid: 2769
  227. NSpid: 2769
  228. NSpgid: 2765
  229. NSsid: 2765
  230. VmPeak: 141952 kB
  231. VmSize: 141952 kB
  232. VmLck: 0 kB
  233. VmPin: 0 kB
  234. VmHWM: 11552 kB
  235. VmRSS: 3444 kB
  236. VmData: 772 kB
  237. VmStk: 136 kB
  238. VmExe: 244 kB
  239. VmLib: 62356 kB
  240. VmPTE: 208 kB
  241. VmPMD: 12 kB
  242. VmSwap: 1968 kB
  243. HugetlbPages: 0 kB
  244. Threads: 1
  245. SigQ: 0/3912
  246. SigPnd: 0000000000000000
  247. ShdPnd: 0000000000000000
  248. SigBlk: 0000000000014006
  249. SigIgn: 0000000000001000
  250. SigCgt: 00000001800004c8
  251. CapInh: 0000000000000000
  252. CapPrm: 0000003fffffffff
  253. CapEff: 0000003fffffffff
  254. CapBnd: 0000003fffffffff
  255. CapAmb: 0000000000000000
  256. Seccomp: 0
  257. Cpus_allowed: 1
  258. Cpus_allowed_list: 0
  259. Mems_allowed: 00000000,00000001
  260. Mems_allowed_list: 0
  261. voluntary_ctxt_switches: 36
  262. nonvoluntary_ctxt_switches: 23
  263.  
  264. VmPeak: 141952 kB
  265. VmSize: 141952 kB
  266. VmLck: 0 kB
  267. VmPin: 0 kB
  268. VmHWM: 11552 kB
  269. VmRSS: 3444 kB
  270. VmData: 772 kB
  271. VmStk: 136 kB
  272. VmExe: 244 kB
  273. VmLib: 62356 kB
  274. VmPTE: 208 kB
  275. VmPMD: 12 kB
  276. VmSwap: 1968 kB
  277.  
  278. #!/bin/sh
  279. echo " NAME PID SWAP"
  280. for PID in /proc/[0-9]*
  281. do
  282. if stat $PID/status >/dev/null
  283. then
  284. # get name of process
  285. procname=`grep 'Name:' $PID/status | awk -e '{ print $2 };'`
  286. # get amount of swap in use by that process
  287. procswap=`grep 'VmSwap:' $PID/status | awk -e '{ print $2 };'`
  288.  
  289. printf "%-21s %11d %11dn" $procname `basename $PID` $procswap
  290. fi
  291. done
  292.  
  293. NAME PID SWAP
  294. systemd 1 348
  295. watchdog/0 10 0
  296. ipv6_addrconf 106 0
  297. ureadahead 13234 28
  298. gnome-calculato 13997 0
  299. apache2 14175 7240
  300. freshclam 1447 3072
  301. systemd-logind 1449 244
Add Comment
Please, Sign In to add comment