linux command to check memory usage in percentage
$ free -t | awk 'NR == 2 {printf("Current Memory Utilization is : %.2f%"), $3/$2*100}'
or
$ free -t | awk 'FNR == 2 {printf("Current Memory Utilization is : %.2f%"), $3/$2*100}'
Current Memory Utilization is : 20.42%
free -mtop - 15:20:30 up 6:57, 5 users, load average: 0.64, 0.44, 0.33
Tasks: 265 total, 1 running, 263 sleeping, 0 stopped, 1 zombie
%Cpu(s): 7.8 us, 2.4 sy, 0.0 ni, 88.9 id, 0.9 wa, 0.0 hi, 0.0 si, 0.0 st
KiB Mem: 8167848 total, 6642360 used, 1525488 free, 1026876 buffers
KiB Swap: 1998844 total, 0 used, 1998844 free, 2138148 cached
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
2986 enlighte 20 0 584m 42m 26m S 14.3 0.5 0:44.27 yakuake
1305 root 20 0 448m 68m 39m S 5.0 0.9 3:33.98 Xorg
7701 enlighte 20 0 424m 17m 10m S 4.0 0.2 0:00.12 kio_thumbnail
Also in Shell:
- How do I get a complete list of all table names in all databases in Hive?
- exit from jshell
- remove directory and contents
- recursive grep recursion depth
- command to know disk ussage in ec2 instance
- linux find file
- which desktop environment is runnings
- npm move package from devdependencies to dependencies
- raspberry shell get datetime now
- optional argument bash
- git clone a specific commit
- git how to delete origin branch
- start a local SMTP debugging server in linux
- git cherry pick commit
- how to install node fetch
- powershell get date
- git rename branch
- how to update vs code in linux
- install tensorflow
- ubuntu remove temp files
- bash write
- powershell script enable tls 1.2
- locate file in same directory linux
- Realtek RTL8812BU Network WiFi Adapter kali linux driver