Continuing the last conversation from 11 Lesser Known Useful Linux Commands – Part I here in this article we will be focusing on other lesser known Linux commands, that will prove to be very much useful in managing Desktop and Server.
12. <space> Command
Every piece of command you type in terminal gets recorded in the history and can be retried using history command.
How about cheating history command? Yeah you can do it and its very easy. Just put one or more white space before typing a command in terminal and your command wont be recorded.
Lets give it a try, we will try five common Linux commands (say ls, pwd, uname, echo “hi” and who) in terminal after one white space and check if these commands are docked in history or not.
Now run ‘history‘ command to see whether these above executed commands are recorded or not.
You see our last executed commands are not logged. we can also cheat history by using an alternate command ‘cat | bash‘ of-course without quotes, in the same way as above.
No comments:
Post a Comment