The Linux system uses the History command to view the system's log records to identify some issues. However, there is often no time and other information in the data output from History. This article will teach you how to customize the History output format for Linux systems.
Specific methods are as follows
root user to the server, a new file history_command
vim at /etc/profile.d//etc/profile.c /history_command
export HISTFILE=$HOME/.bash_history
export HISTSIZE=1200
export HISTFILESIZE=1200
export HISTCONTROL=ignoredups
export HISTTIMEFORMAT=“`whoami` %F %T ”
shopt -s histappend
typeset -r HISTTIMEFORMAT
source /etc/profile.c/History_command, make it effective, and then click on the history command to see:
#history 5
1008 root 2015-09-11 08:54:20 vim /etc/profile
1009 root 2015-09-11 09:13:17 history
On Linux systems, if you want to expand disk capacity, you can create new virtual disk space. After
In Linux, although you can enable Java directly, but sometimes you need to enable J
The most commonly used editor for Linux users is the VIM editor. In order to improve our editing spe
Linux prompts unable to load selinux policy error when booting, resulting in the sy
How to install and set GlusterFS on CentOS 6.4
Ubuntu install Nox, compile make error, what should I do?
How to create RPM or DEB package from Linux source code
How to install Eclipse and PyDev extensions in Ubuntu 14.04?
Linux network card binding setting method
What can I do if Sublime Text cannot be imported into Chinese in Linux?
How Linux prohibits automatic upgrade of system kernel Kernel
Linux how to install and configure rz/sz command
Linux method for handling Tomcat exceptions
Ubuntu 12.04 installation Xen FAQ and solution
What should I do if the Java process under Linux system disappears without cause?
Win7 system shutdown "hibernate" option does not see how to do
Computer crash can also be optimized
Make WinXP more secure, a few tricks, super killing skills
HP notebook boot does not display
How to choose 32-bit and 64-bit Win8 systems
How to set up printer sharing under win7 system
How to play a rookie streamline sharing six steps to make Windows 7 slimming
Care system, detailed Win8 enhanced version SmartScreen filter