Linux history command

If you wish to find what commands you have previously executed in a Linux environment you can use the history command. In addition to that, you can also look in the file ~/.bash_history if you’re using bash. In this article we’ll cover the most basic usages of the Linux history command:

Display the last commands run with Linux history command

history

Clear your command history

history -c

Search for a command with history and grep

history | grep {Command to look for}
  • 0 Kunder som kunne bruge dette svar
Hjalp dette svar dig?

Relaterede artikler

Linux tar Command

The Linux tar command is used to compress and extract files to and from an archive. In this...

Linux top command

If you wish to monitor the performance of your VPS or Dedicated server and track processes, RAM...

Linux ping command

If you wish to test your connection to a server from your Linux system you can use the Linux ping...

Linux file command

The file command is used to check a file’s type and contents in Linux environment. It is most...

Linux export command

When you’re managing your shell’s variables and you wish to save them to your environment you can...