cmdref.net - Cheat Sheet and Example

cmdref.net is command references/cheat sheets/examples for system engineers.

User Tools

Site Tools


Sidebar








Cloud



Etc


Reference














.

os:linux:command:history.html



Linux Commands#Process Management

history : How to use history command in Linux with examples

man history


Tips

/etc/profile or /etc/bashrc

HISTTIMEFORMAT='%F %T '
HISTSIZE=100000
HISTFILESIZE=100000
#always refresh
PROMPT_COMMAND='history -a; history -c; history -r'
$ HISTTIMEFORMAT="%Y/%m/%d %H:%M:%S "

 1000  2017/01/11 00:14:12 shutdown -h  now
 1001  2017/01/11 00:14:19 alias 
 1002  2017/01/11 00:14:29 unalias mv
 1003  2017/01/11 00:14:32 alias
 1004  2017/01/11 00:15:09 man unalias
 1005  2017/01/11 00:17:54 man script
HISTIGNORE=hostname:ls





Linux Commands#Process Management




os/linux/command/history.html.txt ยท Last modified: 2022/08/20 by admin

Page Tools