<?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: ksh script Agian !! in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/ksh-script-agian/m-p/4428540#M663863</link>
    <description>Hi,&lt;BR /&gt;&lt;BR /&gt;you can go on from previous thread.&lt;BR /&gt;&lt;BR /&gt;as answer you don't need MD5A=$MD5B? in loop. remove it. &lt;BR /&gt;&lt;BR /&gt;in loop you copy the file and get the checksum. and if local and remote are same exit the loop. so you must compare local and remote file cheksum( MD5A and MD5B)</description>
    <pubDate>Thu, 28 May 2009 10:17:50 GMT</pubDate>
    <dc:creator>Kenan Erdey</dc:creator>
    <dc:date>2009-05-28T10:17:50Z</dc:date>
    <item>
      <title>ksh script Agian !!</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ksh-script-agian/m-p/4428539#M663862</link>
      <description>Dear my friends,&lt;BR /&gt;&lt;BR /&gt;Dear my friends,&lt;BR /&gt;&lt;BR /&gt;I have below script:&lt;BR /&gt;&lt;BR /&gt;if [ "$x" != "0" ]; then&lt;BR /&gt;cat $y | while read LINE&lt;BR /&gt;do&lt;BR /&gt;is_ok=1&lt;BR /&gt;      until [ $is_ok -eq 0 ]; do&lt;BR /&gt;cp -p $z${LINE} /eva/bulk/tmp/${LINE}&lt;BR /&gt;cmp -s $z${LINE} /eva/bulk/tmp/${LINE}&amp;gt; /dev/null&lt;BR /&gt;is_ok=$?&lt;BR /&gt;         done&lt;BR /&gt;   is_ok=1&lt;BR /&gt;   until [ $is_ok -eq 0 ]; do&lt;BR /&gt;   rm -f /eva/bulk/tmp/${LINE}.gz&lt;BR /&gt;   usr/contrib/bin/gzip /eva/bulk/tmp/${LINE}&lt;BR /&gt;    is_ok=$?&lt;BR /&gt;         done&lt;BR /&gt;MD5A=$(md5sum /eva/bulk/tmp/${LINE}.gz | cut -c 1-32)&lt;BR /&gt;MD5B="0"&lt;BR /&gt;until [ "$MD5A" = "$MD5B" ]; do&lt;BR /&gt;remsh remserver -l root -n rm -f /cx/arc/${LINE}.gz&lt;BR /&gt;rcp -p /eva/bulk/tmp/${LINE}.gz remserver:/cx/arc/${LINE}.gz&lt;BR /&gt;MD5B=$(remsh remserver -l root -n md5sum /cx/arc/${LINE}.gz|cut -c 1-32)&lt;BR /&gt;MD5A=$MD5B?&lt;BR /&gt;    done&lt;BR /&gt;&lt;BR /&gt;done&lt;BR /&gt;&lt;BR /&gt;else echo "There are no files to be copied................."&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;How to check so the last looping (rcp) has match the test value (MD5A=MD5B).Because my above script still looping and the check does not work.Thanks in advanced.</description>
      <pubDate>Thu, 28 May 2009 10:02:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ksh-script-agian/m-p/4428539#M663862</guid>
      <dc:creator>zap_2</dc:creator>
      <dc:date>2009-05-28T10:02:54Z</dc:date>
    </item>
    <item>
      <title>Re: ksh script Agian !!</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ksh-script-agian/m-p/4428540#M663863</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;you can go on from previous thread.&lt;BR /&gt;&lt;BR /&gt;as answer you don't need MD5A=$MD5B? in loop. remove it. &lt;BR /&gt;&lt;BR /&gt;in loop you copy the file and get the checksum. and if local and remote are same exit the loop. so you must compare local and remote file cheksum( MD5A and MD5B)</description>
      <pubDate>Thu, 28 May 2009 10:17:50 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ksh-script-agian/m-p/4428540#M663863</guid>
      <dc:creator>Kenan Erdey</dc:creator>
      <dc:date>2009-05-28T10:17:50Z</dc:date>
    </item>
  </channel>
</rss>

