10 lines
197 B
Bash
Executable File
10 lines
197 B
Bash
Executable File
#!/bin/sh
|
|
|
|
total_mem=$(free -m | awk '$1 == "Mem:" { print $2 }')
|
|
|
|
while(true); do
|
|
current_mem=$(free -m | awk '$1 == "-/+" { print $3 }')
|
|
echo "${current_mem}MB/${total_mem}MB"
|
|
sleep 3
|
|
done
|