Results 1 to 5 of 5
I use this command to give my free memory in my system: free | grep Mem | awk '{ print $4 }'
And, I would like to know what's the ...
- 12-10-2008 #1Just Joined!
- Join Date
- Oct 2008
- Posts
- 48
Descompose memory result
I use this command to give my free memory in my system: free | grep Mem | awk '{ print $4 }'
And, I would like to know what's the arithmetical math to descompose this result into Gb, Mb and Kbytes.
For example, If I have 1048577Kbyes
1048577 / 1024 = 1024,0009 Mb
1024,0009 / 1024 = 1 Gb
my result: 1GB, 1Mb, 0Kbytes.
I would like to make this with and script.
Help me please!
- 12-17-2008 #2Just Joined!
- Join Date
- Oct 2008
- Posts
- 48
anybody help me?
- 12-17-2008 #3--
Bill
Old age and treachery will overcome youth and skill.
- 12-17-2008 #4Just Joined!
- Join Date
- Oct 2008
- Posts
- 48
yes but it's different.
In my first post i put the total memory in GB, Mb and Kbytes,
now i would like to make an operation (i don't know to make it!)
- 12-17-2008 #5
So now it's time for you to learn about bash and bash scripting.
--
Bill
Old age and treachery will overcome youth and skill.


Reply With Quote