top button
Flag Notify
    Connect to us
      Facebook Login
      Site Registration

Facebook Login
Site Registration

How do you see command line history in UNIX?

+2 votes
56 views
How do you see command line history in UNIX?
posted Jul 27, 2015 by Mohammed Hussain

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

1 Answer

+2 votes
 
Best answer

Very useful indeed, use history command along with grep command in UNIX to find any relevant command you have already executed.

Example

$ history

Output
911  man  7 signal
912  man ps
913  man  7 signal
914  man killall
915  killall -l
916  man killall
917  su -

$ history | grep killall

Output
914  man killall
915  killall -l
916  man killall
answer Jul 28, 2015 by Manikandan J
Contact Us
+91 9880187415
sales@queryhome.net
support@queryhome.net
#280, 3rd floor, 5th Main
6th Sector, HSR Layout
Bangalore-560102
Karnataka INDIA.
QUERY HOME
...