<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Logging commands executed in shell in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600787#M232973</link>
    <description>Is there any good and straightforward way on HP-UX to log commands executed in a shell?&lt;BR /&gt;Obviously there is .sh_history and .bash_history but it not very accurate. (If you just close the putty window or login simultaneously with same account it doesn't updated well.)&lt;BR /&gt;And I also want to see the time when a given command was executed which not included in shell history files.&lt;BR /&gt;&lt;BR /&gt;I would appreciate any ideas…&lt;BR /&gt;Thanks in advance.&lt;BR /&gt;</description>
    <pubDate>Wed, 10 Aug 2005 11:20:30 GMT</pubDate>
    <dc:creator>Laszlo Csizmadia</dc:creator>
    <dc:date>2005-08-10T11:20:30Z</dc:date>
    <item>
      <title>Logging commands executed in shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600787#M232973</link>
      <description>Is there any good and straightforward way on HP-UX to log commands executed in a shell?&lt;BR /&gt;Obviously there is .sh_history and .bash_history but it not very accurate. (If you just close the putty window or login simultaneously with same account it doesn't updated well.)&lt;BR /&gt;And I also want to see the time when a given command was executed which not included in shell history files.&lt;BR /&gt;&lt;BR /&gt;I would appreciate any ideas…&lt;BR /&gt;Thanks in advance.&lt;BR /&gt;</description>
      <pubDate>Wed, 10 Aug 2005 11:20:30 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600787#M232973</guid>
      <dc:creator>Laszlo Csizmadia</dc:creator>
      <dc:date>2005-08-10T11:20:30Z</dc:date>
    </item>
    <item>
      <title>Re: Logging commands executed in shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600788#M232974</link>
      <description>You can use a product like powerbroker and require user to start his/her session with &lt;BR /&gt;&lt;BR /&gt;pbrun ksh # (or shell of your choice)&lt;BR /&gt;&lt;BR /&gt;from this moment on, every keystroke they make gets recorded in PB logs. It is not a free product, but has very good logging capabilities as well as delegation of authority features.&lt;BR /&gt;&lt;BR /&gt;visit :&lt;BR /&gt;&lt;BR /&gt;http;//&lt;A href="http://www.symark.com" target="_blank"&gt;www.symark.com&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;for more information.&lt;BR /&gt;HTH</description>
      <pubDate>Wed, 10 Aug 2005 11:27:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600788#M232974</guid>
      <dc:creator>Mel Burslan</dc:creator>
      <dc:date>2005-08-10T11:27:54Z</dc:date>
    </item>
    <item>
      <title>Re: Logging commands executed in shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600789#M232975</link>
      <description>you could use script. Set it up to execute as they logon in their profile, and it will create a file which you could name using date/time extensions, and this records all commands they issue while logged in on this session.&lt;BR /&gt;man script</description>
      <pubDate>Wed, 10 Aug 2005 11:35:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600789#M232975</guid>
      <dc:creator>melvyn burnard</dc:creator>
      <dc:date>2005-08-10T11:35:45Z</dc:date>
    </item>
    <item>
      <title>Re: Logging commands executed in shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600790#M232976</link>
      <description>Powerbroker seems a good a sophisticated tool but I would prefer some HP tool.&lt;BR /&gt;(Or something open source with GPL license.)&lt;BR /&gt;BTW is it possible to do this with HP-UX own accounting mechanism? Man acct.</description>
      <pubDate>Wed, 10 Aug 2005 11:39:55 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600790#M232976</guid>
      <dc:creator>Laszlo Csizmadia</dc:creator>
      <dc:date>2005-08-10T11:39:55Z</dc:date>
    </item>
    <item>
      <title>Re: Logging commands executed in shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600791#M232977</link>
      <description>Thanks Melvyn! I guess you mean sg like this e.g.:&lt;BR /&gt;# Set up shell history file&lt;BR /&gt;        myterm=`ps | tail -1 | awk '{print $2}'`&lt;BR /&gt;        export HISTFILE=$HOME/.sh_history.`who -R|grep \$myterm|awk '{print $6}'&lt;BR /&gt;|sed s/\(//|sed s/\)//`&lt;BR /&gt;&lt;BR /&gt;But it doesn't log timestamp for commands. And it not really working if you just close your teminal. It just solve the problem of simultaneous login.</description>
      <pubDate>Wed, 10 Aug 2005 11:43:51 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600791#M232977</guid>
      <dc:creator>Laszlo Csizmadia</dc:creator>
      <dc:date>2005-08-10T11:43:51Z</dc:date>
    </item>
    <item>
      <title>Re: Logging commands executed in shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600792#M232978</link>
      <description>We use the auditing susbsystem, and log all exec() calls. This has worked good for us. However there is a bug if you login using SSH as it's not self-auditing as telnetd is. I've published a workaround here:&lt;BR /&gt;&lt;A href="http://www.mayoxide.com/audenable/" target="_blank"&gt;http://www.mayoxide.com/audenable/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Another alternative is documented here:&lt;BR /&gt;&lt;A href="http://honeypots.sourceforge.net/modified_script.html" target="_blank"&gt;http://honeypots.sourceforge.net/modified_script.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;I started porting this to HP-UX some time ago (can give you my sources if you want) but found it to be too risky for corner cases.&lt;BR /&gt;&lt;BR /&gt;Olivier.</description>
      <pubDate>Wed, 10 Aug 2005 11:45:19 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600792#M232978</guid>
      <dc:creator>Olivier Masse</dc:creator>
      <dc:date>2005-08-10T11:45:19Z</dc:date>
    </item>
    <item>
      <title>Re: Logging commands executed in shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600793#M232979</link>
      <description>Using the HIST file, can incorporate date/time&lt;BR /&gt;&lt;BR /&gt;# Set History File&lt;BR /&gt;  HISTFILE=/home/root/.sh_history_"${HST}"_"${USR}"-as-"${NAME}"_`date +%y%m%d.%H%M%S_$$`&lt;BR /&gt;  export HISTFILE&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;The 1-liner you posted just recently can have the date functionality included with it. This way you get the date/time stamps as well.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 10 Aug 2005 11:49:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600793#M232979</guid>
      <dc:creator>Rick Garland</dc:creator>
      <dc:date>2005-08-10T11:49:44Z</dc:date>
    </item>
    <item>
      <title>Re: Logging commands executed in shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600794#M232980</link>
      <description>Thanks Olivier!!&lt;BR /&gt;I exactly looking for something like this. I'll have a look at these tomorrow. Thanks.</description>
      <pubDate>Wed, 10 Aug 2005 12:12:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600794#M232980</guid>
      <dc:creator>Laszlo Csizmadia</dc:creator>
      <dc:date>2005-08-10T12:12:25Z</dc:date>
    </item>
    <item>
      <title>Re: Logging commands executed in shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600795#M232981</link>
      <description>Rick,&lt;BR /&gt;&lt;BR /&gt;but I want a timestamp when e.g. the "ls -lR" was executed by user xyz.&lt;BR /&gt;What you wrote here just append a timestamp to the history file.</description>
      <pubDate>Wed, 10 Aug 2005 12:14:42 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/logging-commands-executed-in-shell/m-p/3600795#M232981</guid>
      <dc:creator>Laszlo Csizmadia</dc:creator>
      <dc:date>2005-08-10T12:14:42Z</dc:date>
    </item>
  </channel>
</rss>

