<?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 Re: last command on a network in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217081#M169652</link>
    <description>Hi Mark,&lt;BR /&gt;&lt;BR /&gt;Though the user login information is obtained from the NIS, the system still keeps the login activities in the local files (utmpx/wtmpx). I would suggest you to write a script that can do a remsh to all the systems, run last command and redirect the o/p to a file. If you feel this is a security risk then you have to do this on individual systems ..&lt;BR /&gt;&lt;BR /&gt;-KarthiK S S</description>
    <pubDate>Fri, 12 Mar 2004 06:32:16 GMT</pubDate>
    <dc:creator>Karthik S S</dc:creator>
    <dc:date>2004-03-12T06:32:16Z</dc:date>
    <item>
      <title>last command on a network</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217079#M169650</link>
      <description>Hi everybody,&lt;BR /&gt;&lt;BR /&gt;I have been asked to identify users on our network who haven't logged in for over 90 days. I know I can do this with "last|grep userid", but don't want to have to log in to every server/workstation for every user. As the users are set up in NIS, I am sure there must be a way of doing it from the NIS server.&lt;BR /&gt;&lt;BR /&gt;Any ideas?&lt;BR /&gt;&lt;BR /&gt;Mark Syder (like the drink but spelt different)</description>
      <pubDate>Fri, 12 Mar 2004 06:29:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217079#M169650</guid>
      <dc:creator>MarkSyder</dc:creator>
      <dc:date>2004-03-12T06:29:17Z</dc:date>
    </item>
    <item>
      <title>Re: last command on a network</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217080#M169651</link>
      <description>Hi Mark,&lt;BR /&gt;&lt;BR /&gt;How about the finger command.&lt;BR /&gt;&lt;BR /&gt;# finger user&lt;BR /&gt;&lt;BR /&gt;Robert-Jan</description>
      <pubDate>Fri, 12 Mar 2004 06:31:43 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217080#M169651</guid>
      <dc:creator>Robert-Jan Goossens</dc:creator>
      <dc:date>2004-03-12T06:31:43Z</dc:date>
    </item>
    <item>
      <title>Re: last command on a network</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217081#M169652</link>
      <description>Hi Mark,&lt;BR /&gt;&lt;BR /&gt;Though the user login information is obtained from the NIS, the system still keeps the login activities in the local files (utmpx/wtmpx). I would suggest you to write a script that can do a remsh to all the systems, run last command and redirect the o/p to a file. If you feel this is a security risk then you have to do this on individual systems ..&lt;BR /&gt;&lt;BR /&gt;-KarthiK S S</description>
      <pubDate>Fri, 12 Mar 2004 06:32:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217081#M169652</guid>
      <dc:creator>Karthik S S</dc:creator>
      <dc:date>2004-03-12T06:32:16Z</dc:date>
    </item>
    <item>
      <title>Re: last command on a network</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217082#M169653</link>
      <description>Thanks for the prompt replies.&lt;BR /&gt;&lt;BR /&gt;I'll give them both a go and award points accordingly.&lt;BR /&gt;&lt;BR /&gt;Mark</description>
      <pubDate>Fri, 12 Mar 2004 06:35:19 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217082#M169653</guid>
      <dc:creator>MarkSyder</dc:creator>
      <dc:date>2004-03-12T06:35:19Z</dc:date>
    </item>
    <item>
      <title>Re: last command on a network</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217083#M169654</link>
      <description>No, there isn't, unless of course you have your  utmp/wtmp files synchronised with NIS :)</description>
      <pubDate>Fri, 12 Mar 2004 06:36:08 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217083#M169654</guid>
      <dc:creator>Mark Grant</dc:creator>
      <dc:date>2004-03-12T06:36:08Z</dc:date>
    </item>
    <item>
      <title>Re: last command on a network</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217084#M169655</link>
      <description>Karthik - I'm not ignoring you, I just haven't had time to check your solution yet. I will award your points when I've tried writing the script and know the result.&lt;BR /&gt;&lt;BR /&gt;Robert-Jan - thanks, I've tried it, but it still means logging in on every server/ws.&lt;BR /&gt;&lt;BR /&gt;Mark</description>
      <pubDate>Fri, 12 Mar 2004 06:40:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217084#M169655</guid>
      <dc:creator>MarkSyder</dc:creator>
      <dc:date>2004-03-12T06:40:25Z</dc:date>
    </item>
    <item>
      <title>Re: last command on a network</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217085#M169656</link>
      <description>Mark,&lt;BR /&gt;&lt;BR /&gt;That is OK .. take your own time :-))&lt;BR /&gt;&lt;BR /&gt;-Karthik S S</description>
      <pubDate>Fri, 12 Mar 2004 07:06:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217085#M169656</guid>
      <dc:creator>Karthik S S</dc:creator>
      <dc:date>2004-03-12T07:06:49Z</dc:date>
    </item>
    <item>
      <title>Re: last command on a network</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217086#M169657</link>
      <description>Install expect script from,&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://hpux.connect.org.uk/hppd/hpux/Tcl/expect-5.39/" target="_blank"&gt;http://hpux.connect.org.uk/hppd/hpux/Tcl/expect-5.39/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;And sitting from a workstation run the following script (slight modification required - you can login as root or any normal user - a file by name server_list should be created which will contain a list of machine names),&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;for i in `/usr/bin/cat server_list`&lt;BR /&gt;do&lt;BR /&gt;/usr/sbin/ping $i&lt;BR /&gt;if [ $? -eq 0 ]&lt;BR /&gt;then&lt;BR /&gt;/usr/local/bin/expect &amp;lt;&lt;EOF&gt;&lt;/EOF&gt;set prompt "(%|#|\\$|&amp;lt;|&amp;gt;)"  &lt;BR /&gt;set timeout 10 &lt;BR /&gt;spawn telnet $i&lt;BR /&gt;expect "Login: "&lt;BR /&gt;send "root\r"&lt;BR /&gt;expect "Password: "&lt;BR /&gt;send "password\r"&lt;BR /&gt;expect "$"&lt;BR /&gt;send "last | grep user\r"&lt;BR /&gt;expect "$"&lt;BR /&gt;send "exit\r"&lt;BR /&gt;exit&lt;BR /&gt;EOF&lt;BR /&gt;else&lt;BR /&gt;/usr/bin/echo "$i is down"&lt;BR /&gt;fi&lt;BR /&gt;done &amp;gt; userstat.out&lt;BR /&gt;&lt;BR /&gt;Hope this helps...&lt;BR /&gt;&lt;BR /&gt;-Karthik S S</description>
      <pubDate>Fri, 12 Mar 2004 07:15:01 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217086#M169657</guid>
      <dc:creator>Karthik S S</dc:creator>
      <dc:date>2004-03-12T07:15:01Z</dc:date>
    </item>
    <item>
      <title>Re: last command on a network</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217087#M169658</link>
      <description>You can replace telnet with rlogin/remsh which will be much faster.&lt;BR /&gt;&lt;BR /&gt;No points for this please ..&lt;BR /&gt;&lt;BR /&gt;-KarthiK S S</description>
      <pubDate>Fri, 12 Mar 2004 07:35:11 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217087#M169658</guid>
      <dc:creator>Karthik S S</dc:creator>
      <dc:date>2004-03-12T07:35:11Z</dc:date>
    </item>
    <item>
      <title>Re: last command on a network</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217088#M169659</link>
      <description>Thanks Karthik.&lt;BR /&gt;&lt;BR /&gt;The file is being created as I write.&lt;BR /&gt;&lt;BR /&gt;I think I'll probably leave it running overnight - it looks as though it's going to be big.&lt;BR /&gt;&lt;BR /&gt;Mark</description>
      <pubDate>Tue, 16 Mar 2004 10:25:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/last-command-on-a-network/m-p/3217088#M169659</guid>
      <dc:creator>MarkSyder</dc:creator>
      <dc:date>2004-03-16T10:25:29Z</dc:date>
    </item>
  </channel>
</rss>

