HostOnNet Blog

Enable Date and Time in history

Linux “history” command shows previous commands used in your server. This is good as you can see what commands are run on your server.

By default history do not show date and time of command execution. You can enable this by editing the file /etc/profile and adding following line as the last line.

HISTTIMEFORMAT=”%h.%d %H:%M”


Posted in Linux. Bookmark the permalink.