9/25/2006 ↓

Most oft-used *NIX commands

Author: Mark Ghosh Category: Cool Scripts, LinkyLoo

Thanks for visiting! We would like to serve you better. Please subscribe to our RSS feed for daily updates. This blog posts regular Wordpress news, updates of themes, plugins, ideas, hacks, quick fixes and everything about blogging, especially about Wordpress. You can also receive updates from this blog via email if you want that method of notification.

Most oft-used *NIX commands

history|awk ‘{print $2}’|awk ‘BEGIN {FS=”|”} {print $1}’|sort|uniq -c|sort -r

Very interesting review of the most often used commands on your *NIX machine. Here is my list

195 pico
131 cd
102 ls
58 uptime
47 exit
38 ps
34 clear
32 mytop
27 /etc/init.d/httpd
26 /etc/init.d/mysqld
23 tail
23 cat
22 mysql
20 sh

1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...

Visitors who read this post, also read:

    Friends

    Translate

    Translate to German Translate to Spanish Translate to French Translate to Italian Translate to Portuguese Translate to Japanese Translate to Korean Translate to Russian Translate to Chinese

    Latest Videos

    8 Comments | Leave a comment | Comments RSS

    1. If you run a lot of homemade scripts (or even aliases), then the list unfortunately doesn’t mean as much (assuming you are just interested in proper *NIX commands.)

      Here are mine, though:

      389 vi
      283 cd
      45 ls
      41 vrefs
      15 grep
      15 make
      14 sync
      13 uptime
      10 df
      9 less
      9 gen_banrules.sh
      9 banip
      8 finger
      7 tail
      7 man
      7 date
      6 rm
      6 pwd
      6 mysqldiff

      Also, a small change to the script (to sort reverse numeric):

      history|awk ‘{print $2}’|awk ‘BEGIN {FS=”|”} {print $1}’|sort|uniq -c|sort +0 -1 -rn | less

      Cheers.
      Scott

      [Reply] Scott Burkett (2 comments.) — 09/25/2006 @ 2:14 pm
    2. If you run a lot of homemade scripts (or even aliases), then the list unfortunately doesn’t mean as much (assuming you are just interested in proper *NIX commands.)

      Here are mine, though:

      389 vi
      283 cd
      45 ls
      41 vrefs
      15 grep
      15 make
      14 sync
      13 uptime
      10 df
      9 less
      9 gen_banrules.sh
      9 banip
      8 finger
      7 tail
      7 man
      7 date
      6 rm
      6 pwd
      6 mysqldiff

      Also, a small change to the script (to sort reverse numeric):

      Change the last sort call to: sort +0 -1 -rn

      Cheers.
      Scott

      [Reply] Scott Burkett (2 comments.) — 09/25/2006 @ 2:15 pm
    3. cat .zsh/history | sed -r 's/([^[:space:]]+).*/\1/’ | sort | uniq -c | sort -nr | less

      378 cd
      215 mplayer
      214 rm
      181 ls
      153 less
      145 sudo
      116 grep
      107 svn
      89 mv
      83 man
      55 unrar
      51 emacs
      48 mkdir
      36 mubase
      35 vlc
      33 cat
      27 tar
      22 dpkg
      20 unzip
      18 find
      16 apt-cache
      14 tail
      13 killall
      13 chmod
      12 echo
      12 aptitude
      10 zgrep
      10 perldoc
      10 cp

      [Reply] florian (2 comments.) — 09/25/2006 @ 5:56 pm
    4. For zsh:

      cat .zhistory | sed -r 's/([^[:space:]]+).*/\1/’ | sort | uniq -c | sort -nr | less

      378 cd
      214 rm
      181 ls
      153 less
      145 sudo
      116 grep
      107 svn
      89 mv
      83 man
      55 unrar
      51 emacs
      48 mkdir
      36 mubase
      35 vlc
      33 cat
      27 tar
      22 dpkg
      20 unzip
      18 find
      16 apt-cache
      14 tail
      13 killall
      13 chmod
      12 echo
      12 aptitude
      10 zgrep
      10 perldoc
      10 cp

      [Reply] florian (2 comments.) — 09/25/2006 @ 5:57 pm
    5. $ history|awk ‘{print $3.17 ($2)}’|awk ‘BEGIN {FS=”|”} {print $1.58 ($1)}’|sort|uniq -c|sort -r
      bash: syntax error near unexpected token `('

      Am I doing something wrong?

      [Reply] ketsugi (3 comments.) — 09/26/2006 @ 2:54 am
    6. [...] found in this site history|awk ‘{print $2}’|awk ‘BEGIN {FS=”|”} {print $1}’|sort|uniq -c|sort -r [...]

      my little space » Blog Archive » Most oft-used *NIX commands — 09/26/2006 @ 5:20 am
    7. Ketsugi,
      take the <code&gt out of the statement.

      [Reply] Mark (118 comments.) — 09/26/2006 @ 8:31 am
    8. On my laptop it’s:
      65 mv
      64 wget
      53 exit
      48 cd
      21 mkdir
      20 .
      19 ssh
      19 ls
      15 ~/wpdb
      14 sudo
      9 sync
      9 svn
      9 ping
      9 netstat
      9 mysqldump
      9 history
      8 ./refresh-wordpress
      7 ~/refresh-wordpress
      7 ps
      7 du

      On my server (as me) it’s:
      181 exit
      174 su
      84 cd
      71 mysql
      70 ls
      40 ps
      38 epsilon
      33 uptime
      30 pwd
      27 wget
      25 top
      15 .
      13 tar
      13 mv
      13 cp
      11 mysqladmin
      10 du
      9 lynx
      9 df
      8 users

      and on my server (as root) it’s:
      190 ls
      138 cd
      69 exit
      65 epsilon
      54 cp
      43 chown
      37 mv
      27 ps
      26 hostname
      26 .
      24 mysql
      23 chmod
      22 tar
      20 find
      19 pwd
      15 unzip
      15 du
      14 sudo
      14 rm
      13 chgrp

      [Reply] Mike Little (1 comments.) — 09/28/2006 @ 9:02 am

    Leave a comment

    Line and paragraph breaks automatic, e-mail address never displayed, HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

    (required)

    (required, will not be published)


    S2