Retrieving the top 10 used commands in Linux is simple using the history command. What is the history command The history command, as its name implies, is used to view previously executed commands. It’s API is minimal and easy to use. How to view top used commands in Linux Using a combination of history and awk, we can pull the top 10 commands like this: 1history | 2 awk '{CMD[$1]++;count++;}END { for (a in CMD)print CMD[a] " " CMD[a]/count*100 "% " a;}' | 3 grep -v ".