{"id":195,"date":"2012-10-05T15:23:25","date_gmt":"2012-10-05T14:23:25","guid":{"rendered":"http:\/\/www.sebcharrot.com\/blog\/?p=195"},"modified":"2012-10-05T15:23:25","modified_gmt":"2012-10-05T14:23:25","slug":"showing-command-history-in-unix-with-timestamps","status":"publish","type":"post","link":"http:\/\/www.sebcharrot.com\/blog\/showing-command-history-in-unix-with-timestamps\/","title":{"rendered":"Showing command history in UNIX with timestamps"},"content":{"rendered":"<p>A handy little command for checking the history of all commands executed through the UNIX command prompt for that user.<\/p>\n<pre>history<\/pre>\n<p>This will return you a numbered list of commands, oldest first.<\/p>\n<p>Note that by default, &#8220;history&#8221; will NOT show you timestamps, which can be very handy if investigating activity on a certain machine.<\/p>\n<p>To show history with timestamps, you&#8217;ll need to set up an evironment variable to store the format that history should be output in. Simply execute the following command.<\/p>\n<pre>export HISTTIMEFORMAT='%F %T '<\/pre>\n<p>Any subsequent call to history will show you the date and time.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>A handy little command for checking the history of all commands executed through the UNIX command prompt for that user. history This will return you a numbered list of commands, oldest first. Note that by default, &#8220;history&#8221; will NOT show you timestamps, which can be very handy if investigating activity on a certain machine. To&hellip;&nbsp;<a href=\"http:\/\/www.sebcharrot.com\/blog\/showing-command-history-in-unix-with-timestamps\/\" class=\"\" rel=\"bookmark\">Read More &raquo;<span class=\"screen-reader-text\">Showing command history in UNIX with timestamps<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"neve_meta_sidebar":"","neve_meta_container":"","neve_meta_enable_content_width":"","neve_meta_content_width":0,"neve_meta_title_alignment":"","neve_meta_author_avatar":"","neve_post_elements_order":"","neve_meta_disable_header":"","neve_meta_disable_footer":"","neve_meta_disable_title":""},"categories":[23,15],"tags":[],"_links":{"self":[{"href":"http:\/\/www.sebcharrot.com\/blog\/wp-json\/wp\/v2\/posts\/195"}],"collection":[{"href":"http:\/\/www.sebcharrot.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.sebcharrot.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.sebcharrot.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.sebcharrot.com\/blog\/wp-json\/wp\/v2\/comments?post=195"}],"version-history":[{"count":0,"href":"http:\/\/www.sebcharrot.com\/blog\/wp-json\/wp\/v2\/posts\/195\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.sebcharrot.com\/blog\/wp-json\/wp\/v2\/media?parent=195"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.sebcharrot.com\/blog\/wp-json\/wp\/v2\/categories?post=195"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.sebcharrot.com\/blog\/wp-json\/wp\/v2\/tags?post=195"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}