<?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 ssh automated script with MP in Integrity Servers</title>
    <link>https://community.hpe.com/t5/integrity-servers/ssh-automated-script-with-mp/m-p/4143388#M3272</link>
    <description>rx2660 MP&lt;BR /&gt;&lt;BR /&gt;I have a telnet automated script that connects into MP and submits several MP commands. It's working fine.&lt;BR /&gt;&lt;BR /&gt;Now I would like to use ssh instead of telnet.&lt;BR /&gt;I can establish a ssh session with MP from putty. &lt;BR /&gt;&lt;BR /&gt;1)When I try to ssh from HP-UX 11.23 to the MP I cant establish the session:&lt;BR /&gt;_________________________________________&lt;BR /&gt;&lt;BR /&gt;# ssh &lt;SOMEHOST_MP_IP&gt;&lt;BR /&gt;&lt;BR /&gt;OpenSSH_4.4p1-hpn12v11, OpenSSL 0.9.7l 28 Sep 2006&lt;BR /&gt;HP-UX Secure Shell-A.04.40.011, HP-UX Secure Shell version&lt;BR /&gt;debug1: Reading configuration data /opt/ssh/etc/ssh_config&lt;BR /&gt;debug3: RNG is ready, skipping seeding&lt;BR /&gt;debug2: ssh_connect: needpriv 0&lt;BR /&gt;debug1: Connecting to  &lt;SOMEHOST_MP_IP&gt;&lt;BR /&gt;[&lt;SOMEHOST_MP_IP&gt;] port 22.&lt;BR /&gt;debug1: Connection established.&lt;BR /&gt;debug1: permanently_set_uid: 0/3&lt;BR /&gt;....&lt;BR /&gt;....&lt;BR /&gt;debug1: sending SSH2_MSG_KEXDH_INIT&lt;BR /&gt;debug1: expecting SSH2_MSG_KEXDH_REPLY&lt;BR /&gt;Received disconnect from &lt;SOMEHOST_MP_IP&gt;: 11:  Client Disconnect&lt;BR /&gt;_________________________________________&lt;BR /&gt;&lt;BR /&gt;Any ideas why after "expecting SSH2_MSG_KEXDH_REPLY" the session disconnects?&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;2)How can I automate ssh (e.g. using here document)&lt;BR /&gt;&lt;BR /&gt;I get the following message:&lt;BR /&gt;&lt;BR /&gt;Pseudo-terminal will not be allocated because stdin is not a terminal.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;&lt;BR /&gt;Joao Rei&lt;BR /&gt;&lt;BR /&gt;&lt;/SOMEHOST_MP_IP&gt;&lt;/SOMEHOST_MP_IP&gt;&lt;/SOMEHOST_MP_IP&gt;&lt;/SOMEHOST_MP_IP&gt;</description>
    <pubDate>Mon, 11 Feb 2008 21:20:19 GMT</pubDate>
    <dc:creator>Joao Rei</dc:creator>
    <dc:date>2008-02-11T21:20:19Z</dc:date>
    <item>
      <title>ssh automated script with MP</title>
      <link>https://community.hpe.com/t5/integrity-servers/ssh-automated-script-with-mp/m-p/4143388#M3272</link>
      <description>rx2660 MP&lt;BR /&gt;&lt;BR /&gt;I have a telnet automated script that connects into MP and submits several MP commands. It's working fine.&lt;BR /&gt;&lt;BR /&gt;Now I would like to use ssh instead of telnet.&lt;BR /&gt;I can establish a ssh session with MP from putty. &lt;BR /&gt;&lt;BR /&gt;1)When I try to ssh from HP-UX 11.23 to the MP I cant establish the session:&lt;BR /&gt;_________________________________________&lt;BR /&gt;&lt;BR /&gt;# ssh &lt;SOMEHOST_MP_IP&gt;&lt;BR /&gt;&lt;BR /&gt;OpenSSH_4.4p1-hpn12v11, OpenSSL 0.9.7l 28 Sep 2006&lt;BR /&gt;HP-UX Secure Shell-A.04.40.011, HP-UX Secure Shell version&lt;BR /&gt;debug1: Reading configuration data /opt/ssh/etc/ssh_config&lt;BR /&gt;debug3: RNG is ready, skipping seeding&lt;BR /&gt;debug2: ssh_connect: needpriv 0&lt;BR /&gt;debug1: Connecting to  &lt;SOMEHOST_MP_IP&gt;&lt;BR /&gt;[&lt;SOMEHOST_MP_IP&gt;] port 22.&lt;BR /&gt;debug1: Connection established.&lt;BR /&gt;debug1: permanently_set_uid: 0/3&lt;BR /&gt;....&lt;BR /&gt;....&lt;BR /&gt;debug1: sending SSH2_MSG_KEXDH_INIT&lt;BR /&gt;debug1: expecting SSH2_MSG_KEXDH_REPLY&lt;BR /&gt;Received disconnect from &lt;SOMEHOST_MP_IP&gt;: 11:  Client Disconnect&lt;BR /&gt;_________________________________________&lt;BR /&gt;&lt;BR /&gt;Any ideas why after "expecting SSH2_MSG_KEXDH_REPLY" the session disconnects?&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;2)How can I automate ssh (e.g. using here document)&lt;BR /&gt;&lt;BR /&gt;I get the following message:&lt;BR /&gt;&lt;BR /&gt;Pseudo-terminal will not be allocated because stdin is not a terminal.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;&lt;BR /&gt;Joao Rei&lt;BR /&gt;&lt;BR /&gt;&lt;/SOMEHOST_MP_IP&gt;&lt;/SOMEHOST_MP_IP&gt;&lt;/SOMEHOST_MP_IP&gt;&lt;/SOMEHOST_MP_IP&gt;</description>
      <pubDate>Mon, 11 Feb 2008 21:20:19 GMT</pubDate>
      <guid>https://community.hpe.com/t5/integrity-servers/ssh-automated-script-with-mp/m-p/4143388#M3272</guid>
      <dc:creator>Joao Rei</dc:creator>
      <dc:date>2008-02-11T21:20:19Z</dc:date>
    </item>
    <item>
      <title>Re: ssh automated script with MP</title>
      <link>https://community.hpe.com/t5/integrity-servers/ssh-automated-script-with-mp/m-p/4143389#M3273</link>
      <description>Hi Joao&lt;BR /&gt;&lt;BR /&gt;I don't know your firmware revision.But latest firmware has some fixes about SSH in MP like below&lt;BR /&gt;iLO-2 MP F.02.17&lt;BR /&gt;&lt;BR /&gt;    * Who command now shows current user.&lt;BR /&gt;    * Web GUI interface timeout has been increased from 5 to 15 minutes.&lt;BR /&gt;    * Incomplete hot-key sequence on serial console is now forwarded to OS console.&lt;BR /&gt;    * SSH now works with SSH 4.4.&lt;BR /&gt;    * vMedia connection enabled when system power is off.&lt;BR /&gt;    * Web power status was showing as unavailable on power off.&lt;BR /&gt;    * Battery failure event no longer occurs on upgrade.&lt;BR /&gt;    * Repeating CO and Ctrl-B can no longer cause an MP hang.&lt;BR /&gt;    * Fixed SSH bad password detection. &lt;BR /&gt;&lt;BR /&gt;You can check your firmware revision from MP-&amp;gt;CM-&amp;gt;SYSREV&lt;BR /&gt;&lt;BR /&gt;The corrected firmware located in &lt;A href="http://h20000.www2.hp.com/bizsupport/TechSupport/SoftwareDescription.jsp?lang=en&amp;amp;cc=us&amp;amp;prodTypeId=15351&amp;amp;prodSeriesId=3346452&amp;amp;prodNameId=3346456&amp;amp;swEnvOID=54&amp;amp;swLang=13&amp;amp;mode=2&amp;amp;taskId=135&amp;amp;swItem=ux-56643-1" target="_blank"&gt;http://h20000.www2.hp.com/bizsupport/TechSupport/SoftwareDescription.jsp?lang=en&amp;amp;cc=us&amp;amp;prodTypeId=15351&amp;amp;prodSeriesId=3346452&amp;amp;prodNameId=3346456&amp;amp;swEnvOID=54&amp;amp;swLang=13&amp;amp;mode=2&amp;amp;taskId=135&amp;amp;swItem=ux-56643-1&lt;/A&gt;&lt;BR /&gt;and installation instructions are &lt;BR /&gt;&lt;A href="http://h20000.www2.hp.com/bizsupport/TechSupport/SoftwareDescription.jsp?lang=en&amp;amp;cc=us&amp;amp;prodTypeId=15351&amp;amp;prodSeriesId=3346452&amp;amp;swItem=ux-56643-1&amp;amp;prodNameId=3346456&amp;amp;swEnvOID=54&amp;amp;swLang=13&amp;amp;taskId=135&amp;amp;mode=4&amp;amp;idx=1" target="_blank"&gt;http://h20000.www2.hp.com/bizsupport/TechSupport/SoftwareDescription.jsp?lang=en&amp;amp;cc=us&amp;amp;prodTypeId=15351&amp;amp;prodSeriesId=3346452&amp;amp;swItem=ux-56643-1&amp;amp;prodNameId=3346456&amp;amp;swEnvOID=54&amp;amp;swLang=13&amp;amp;taskId=135&amp;amp;mode=4&amp;amp;idx=1&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;I hope it will help&lt;BR /&gt;&lt;BR /&gt;Best Regards&lt;BR /&gt;Murat</description>
      <pubDate>Mon, 11 Feb 2008 22:14:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/integrity-servers/ssh-automated-script-with-mp/m-p/4143389#M3273</guid>
      <dc:creator>Murat SULUHAN</dc:creator>
      <dc:date>2008-02-11T22:14:16Z</dc:date>
    </item>
    <item>
      <title>Re: ssh automated script with MP</title>
      <link>https://community.hpe.com/t5/integrity-servers/ssh-automated-script-with-mp/m-p/4143390#M3274</link>
      <description>1) There is a bug of some sort in the implementation of ssh on some MPs, they work with some clients (e.g. Putty) but not with the OpenSSH client on which you have to manually specify a cipher. &lt;BR /&gt;&lt;BR /&gt;Try:&lt;BR /&gt;$ ssh -c 3des-cbc &lt;SOMEHOST_MP_IP&gt;&lt;BR /&gt;&lt;BR /&gt;or another ciper from the man page, I don't remember which one to use.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;2) You won't be able to automate easily commands on an MP, as here documents don't work for obvious reasons with SSH. The way I circumvented this is by creating an "operator" account on the MP with limited privileges, and automating the SSH session on it using expect. Not a best practice security-wise, but it works. I can send you an example program tomorrow if you want to. Or if you know perl, perl-expect is easier to program than vanilla expect. &lt;BR /&gt;&lt;BR /&gt;Olivier.&lt;BR /&gt;&lt;/SOMEHOST_MP_IP&gt;</description>
      <pubDate>Tue, 12 Feb 2008 03:50:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/integrity-servers/ssh-automated-script-with-mp/m-p/4143390#M3274</guid>
      <dc:creator>Olivier Masse</dc:creator>
      <dc:date>2008-02-12T03:50:07Z</dc:date>
    </item>
    <item>
      <title>Re: ssh automated script with MP</title>
      <link>https://community.hpe.com/t5/integrity-servers/ssh-automated-script-with-mp/m-p/4143391#M3275</link>
      <description>1) Thanks to all replys, the issue about ssh session from HP-UX to rx2660 MP is solved:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Current firmware revisions&lt;BR /&gt;&lt;BR /&gt; MP FW     : F.02.17&lt;BR /&gt;&lt;BR /&gt;# ssh Admin@&lt;SOMEHOST_MP_IP&gt;&lt;BR /&gt;&lt;BR /&gt;Works fine.&lt;BR /&gt;&lt;BR /&gt;Current firmware revisions&lt;BR /&gt;&lt;BR /&gt; MP FW     : F.01.58&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;# ssh -c 3des-cbc  Admin@&lt;SOMEHOST_MP_IP&gt;&lt;BR /&gt;&lt;BR /&gt;Works fine.&lt;BR /&gt;&lt;BR /&gt;_______________________________&lt;BR /&gt;&lt;BR /&gt;Olivier, can you please provide an expect script example to automate ssh?&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;&lt;BR /&gt;Joao Rei&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/SOMEHOST_MP_IP&gt;&lt;/SOMEHOST_MP_IP&gt;</description>
      <pubDate>Tue, 12 Feb 2008 12:28:55 GMT</pubDate>
      <guid>https://community.hpe.com/t5/integrity-servers/ssh-automated-script-with-mp/m-p/4143391#M3275</guid>
      <dc:creator>Joao Rei</dc:creator>
      <dc:date>2008-02-12T12:28:55Z</dc:date>
    </item>
    <item>
      <title>Re: ssh automated script with MP</title>
      <link>https://community.hpe.com/t5/integrity-servers/ssh-automated-script-with-mp/m-p/4143392#M3276</link>
      <description>Here is my expect script. It gets the temperature of the built-in sensor in a rx7640, but it should give you an idea.&lt;BR /&gt;&lt;BR /&gt;P.S.: Never use expect to automate SSH sessions between hosts, it's far from being secure as the password must be stored somewhere, certificates should be used instead.</description>
      <pubDate>Tue, 12 Feb 2008 13:47:31 GMT</pubDate>
      <guid>https://community.hpe.com/t5/integrity-servers/ssh-automated-script-with-mp/m-p/4143392#M3276</guid>
      <dc:creator>Olivier Masse</dc:creator>
      <dc:date>2008-02-12T13:47:31Z</dc:date>
    </item>
  </channel>
</rss>

