Home / Linux / Displaying data in a human-friendly way on Linux

Displaying data in a human-friendly way on Linux

Not everyone thinks in binary or wants to mentally insert commas into large numbers to come to grips with the sizes of their files. So it’s not surprising that Linux commands have evolved over several decades to incorporate more human-friendly ways of displaying information to its users. In today’s post, we’re going to look at some of the options provided by various commands that make digesting data just a little easier.

Why not default to friendly?

If you’re wondering why human-friendliness isn’t the default –- we humans are, after all, the default users of computers — you might be asking yourself “Why do we have to go out of our way to get command responses that will make sense to everyone?” The answer is primarily that changing the default output of commands would likely interfere with numerous other processes that were built to expect the default responses. Other tools as well as scripts that have been developed over the decades might break in some very ugly ways if they were suddenly fed output in a very different format than what they were built to expect. It’s probably also true that some of us might prefer to see all of the digits in our file sizes – 1338277310 instead of 1.3G. In any case, switching defaults could be very disruptive while promoting some easy options for more human-friendly responses only involves us learning some command options.

Looking at our options

So, what are some of the easy options for making the output of Unix commands a little easier to parse? Let’s check some command by command.


You may not have noticed this, but you can change the display of overall memory usage in top by typing “E” (i.e., capital E) once top is running. Successive presses will change the numeric display from KiB to MiB to GiB to TiB to PiB to EiB and back to KiB.


>> Source Link

Check Also

What is the Role of Typing Speed in Programming?

Probably you have been close to some of the experienced developers. Have you ever been …

%d bloggers like this: