Issue
How can I get the total physical memory in bytes of my Linux PC?
I need to assign it to a bash script variable.
Solution
grep MemTotal /proc/meminfo | awk '{print $2}'
The returned number is in KB
Answered By - Neuquino
How can I get the total physical memory in bytes of my Linux PC?
I need to assign it to a bash script variable.
grep MemTotal /proc/meminfo | awk '{print $2}'
The returned number is in KB