<?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 FTP Script to transfer archive log files between 2 HP-UX servers. in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746231#M494723</link>
    <description>Hi,&lt;BR /&gt;I need to transfer archive log files between 2 HP-UX servers. Every 10 min the FTP schedule script will run. So that if file is available &lt;BR /&gt;script will ftp the file. And also script should have logic of sending the latest archive log files of last FTP script run, So that the script will send only the latest files when script again run at schedule time.&lt;BR /&gt; &lt;BR /&gt;And also before the script run it should check whether this ftp script is already running, If script is already running then it should not run the FTP script again. &lt;BR /&gt;&lt;BR /&gt;Please let me know how to modfiy the FTP script below to have the above requirement.&lt;BR /&gt;&lt;BR /&gt;#!/bin/ksh&lt;BR /&gt;cd /directory/Outbound&lt;BR /&gt;HOST='ftp.test.com'&lt;BR /&gt;USER='unix'&lt;BR /&gt;PASSWD='unix'&lt;BR /&gt;ftp -n -v $HOST &amp;lt;&amp;lt; EOF&lt;BR /&gt;user $USER $PASSWD&lt;BR /&gt;lcd /directory/Outbound&lt;BR /&gt;cd upload&lt;BR /&gt;bin&lt;BR /&gt;prompt&lt;BR /&gt;mput *.LOG&lt;BR /&gt;EOF&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Narendra</description>
    <pubDate>Mon, 31 Jan 2011 10:23:35 GMT</pubDate>
    <dc:creator>Narendra Uttekar</dc:creator>
    <dc:date>2011-01-31T10:23:35Z</dc:date>
    <item>
      <title>FTP Script to transfer archive log files between 2 HP-UX servers.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746231#M494723</link>
      <description>Hi,&lt;BR /&gt;I need to transfer archive log files between 2 HP-UX servers. Every 10 min the FTP schedule script will run. So that if file is available &lt;BR /&gt;script will ftp the file. And also script should have logic of sending the latest archive log files of last FTP script run, So that the script will send only the latest files when script again run at schedule time.&lt;BR /&gt; &lt;BR /&gt;And also before the script run it should check whether this ftp script is already running, If script is already running then it should not run the FTP script again. &lt;BR /&gt;&lt;BR /&gt;Please let me know how to modfiy the FTP script below to have the above requirement.&lt;BR /&gt;&lt;BR /&gt;#!/bin/ksh&lt;BR /&gt;cd /directory/Outbound&lt;BR /&gt;HOST='ftp.test.com'&lt;BR /&gt;USER='unix'&lt;BR /&gt;PASSWD='unix'&lt;BR /&gt;ftp -n -v $HOST &amp;lt;&amp;lt; EOF&lt;BR /&gt;user $USER $PASSWD&lt;BR /&gt;lcd /directory/Outbound&lt;BR /&gt;cd upload&lt;BR /&gt;bin&lt;BR /&gt;prompt&lt;BR /&gt;mput *.LOG&lt;BR /&gt;EOF&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Narendra</description>
      <pubDate>Mon, 31 Jan 2011 10:23:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746231#M494723</guid>
      <dc:creator>Narendra Uttekar</dc:creator>
      <dc:date>2011-01-31T10:23:35Z</dc:date>
    </item>
    <item>
      <title>Re: FTP Script to transfer archive log files between 2 HP-UX servers.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746232#M494724</link>
      <description>&lt;BR /&gt;&lt;BR /&gt;#!/bin/ksh&lt;BR /&gt;if [ -f /tmp/.ftpbusy ]&lt;BR /&gt;then&lt;BR /&gt;echo "Busy by a previuos ftp proccess"&lt;BR /&gt;else&lt;BR /&gt;touch /tmp/ftpbusy&lt;BR /&gt;cd /directory/Outbound&lt;BR /&gt;HOST='ftp.test.com'&lt;BR /&gt;USER='unix'&lt;BR /&gt;PASSWD='unix'&lt;BR /&gt;ftp -n -v $HOST &amp;lt;&amp;lt; EOF&lt;BR /&gt;user $USER $PASSWD&lt;BR /&gt;lcd /directory/Outbound&lt;BR /&gt;cd upload&lt;BR /&gt;bin&lt;BR /&gt;prompt&lt;BR /&gt;mput *.LOG&lt;BR /&gt;EOF&lt;BR /&gt;rm /tmp/.ftpbusy&lt;BR /&gt;fi</description>
      <pubDate>Mon, 31 Jan 2011 11:21:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746232#M494724</guid>
      <dc:creator>Jose Mosquera</dc:creator>
      <dc:date>2011-01-31T11:21:52Z</dc:date>
    </item>
    <item>
      <title>Re: FTP Script to transfer archive log files between 2 HP-UX servers.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746233#M494725</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Previous post aviods overlapping of processes using a file control (/tmp/.ftpbusy). Use a convenient place to create it.&lt;BR /&gt;&lt;BR /&gt;To controls lastest log files you could rename them to a sent extention (i.e: .LOG.SENT), once the mput command have been done. Or move them to a sent log directory once sent them (mv *.LOG /anywhere). By this way you just have the last files to send when you execute mput *.LOG.&lt;BR /&gt;&lt;BR /&gt;Rgds.&lt;BR /&gt;</description>
      <pubDate>Mon, 31 Jan 2011 12:05:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746233#M494725</guid>
      <dc:creator>Jose Mosquera</dc:creator>
      <dc:date>2011-01-31T12:05:39Z</dc:date>
    </item>
    <item>
      <title>Re: FTP Script to transfer archive log files between 2 HP-UX servers.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746234#M494726</link>
      <description>Hi,&lt;BR /&gt;As log files are generated incremental by one i.e. LOG.001,LOG.002,LOG.003. Can we have a logic to check which log files are transfer base on log sequence number so that next time it will send only the logs which were not earlier sent.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Narendra</description>
      <pubDate>Mon, 31 Jan 2011 17:03:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746234#M494726</guid>
      <dc:creator>Narendra Uttekar</dc:creator>
      <dc:date>2011-01-31T17:03:39Z</dc:date>
    </item>
    <item>
      <title>Re: FTP Script to transfer archive log files between 2 HP-UX servers.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746235#M494727</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;Given that your logfiles are named in the format "LOG.001, LOG.002, LOG.003", etc. to find the next name to use, you could do something like:&lt;BR /&gt;&lt;BR /&gt;# cat ./nextlog&lt;BR /&gt;#!/bin/sh&lt;BR /&gt;LAST=$(ls -r LOG.*|head -1|sed -e 's/LOG.//')&lt;BR /&gt;[ ${LAST} = 999 ] &amp;amp;&amp;amp; LAST=0&lt;BR /&gt;LAST=$(( LAST+1 ))&lt;BR /&gt;NEXT=$(printf "LOG.%03d\n" ${LAST})&lt;BR /&gt;echo ${NEXT}&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...&lt;BR /&gt;</description>
      <pubDate>Mon, 31 Jan 2011 18:21:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746235#M494727</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2011-01-31T18:21:25Z</dc:date>
    </item>
    <item>
      <title>Re: FTP Script to transfer archive log files between 2 HP-UX servers.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746236#M494728</link>
      <description>Shalom,&lt;BR /&gt;&lt;BR /&gt;A lower band width alternative might be to use rsync to copy files between servers. rsync, available from Internet Express on &lt;A href="http://software.hp.com" target="_blank"&gt;http://software.hp.com&lt;/A&gt; has options to only copy over files that have changed, and not bother recopying the entire set of files.&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Mon, 31 Jan 2011 18:32:43 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/4746236#M494728</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2011-01-31T18:32:43Z</dc:date>
    </item>
    <item>
      <title>Re: FTP Script to transfer transaction log backup files between 2 HP-UX servers from DC to DR server</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/6799682#M494729</link>
      <description>&lt;P&gt;Can anybody let me know the shell script to transfer&amp;nbsp;sybase ase&amp;nbsp;transaction log backup files between 2 HP-UX servers i.e. Primary site to DR site?&lt;/P&gt;&lt;P&gt;I need full script to schedule it from Primary server which will transfer these files to DR.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Later , i need to schedule it using crontab.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;DK&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://community.hpe.com/t5/user/viewprofilepage/user-id/610257"&gt;@Jose Mosquera&lt;/a&gt; wrote:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;#!/bin/ksh&lt;BR /&gt;if [ -f /tmp/.ftpbusy ]&lt;BR /&gt;then&lt;BR /&gt;echo "Busy by a previuos ftp proccess"&lt;BR /&gt;else&lt;BR /&gt;touch /tmp/ftpbusy&lt;BR /&gt;cd /directory/Outbound&lt;BR /&gt;HOST='ftp.test.com'&lt;BR /&gt;USER='unix'&lt;BR /&gt;PASSWD='unix'&lt;BR /&gt;ftp -n -v $HOST &amp;lt;&amp;lt; EOF&lt;BR /&gt;user $USER $PASSWD&lt;BR /&gt;lcd /directory/Outbound&lt;BR /&gt;cd upload&lt;BR /&gt;bin&lt;BR /&gt;prompt&lt;BR /&gt;mput *.LOG&lt;BR /&gt;EOF&lt;BR /&gt;rm /tmp/.ftpbusy&lt;BR /&gt;fi&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://community.hpe.com/t5/user/viewprofilepage/user-id/610257"&gt;@Jose Mosquera&lt;/a&gt; wrote:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;#!/bin/ksh&lt;BR /&gt;if [ -f /tmp/.ftpbusy ]&lt;BR /&gt;then&lt;BR /&gt;echo "Busy by a previuos ftp proccess"&lt;BR /&gt;else&lt;BR /&gt;touch /tmp/ftpbusy&lt;BR /&gt;cd /directory/Outbound&lt;BR /&gt;HOST='ftp.test.com'&lt;BR /&gt;USER='unix'&lt;BR /&gt;PASSWD='unix'&lt;BR /&gt;ftp -n -v $HOST &amp;lt;&amp;lt; EOF&lt;BR /&gt;user $USER $PASSWD&lt;BR /&gt;lcd /directory/Outbound&lt;BR /&gt;cd upload&lt;BR /&gt;bin&lt;BR /&gt;prompt&lt;BR /&gt;mput *.LOG&lt;BR /&gt;EOF&lt;BR /&gt;rm /tmp/.ftpbusy&lt;BR /&gt;fi&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://community.hpe.com/t5/user/viewprofilepage/user-id/610257"&gt;@Jose Mosquera&lt;/a&gt; wrote:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;#!/bin/ksh&lt;BR /&gt;if [ -f /tmp/.ftpbusy ]&lt;BR /&gt;then&lt;BR /&gt;echo "Busy by a previuos ftp proccess"&lt;BR /&gt;else&lt;BR /&gt;touch /tmp/ftpbusy&lt;BR /&gt;cd /directory/Outbound&lt;BR /&gt;HOST='ftp.test.com'&lt;BR /&gt;USER='unix'&lt;BR /&gt;PASSWD='unix'&lt;BR /&gt;ftp -n -v $HOST &amp;lt;&amp;lt; EOF&lt;BR /&gt;user $USER $PASSWD&lt;BR /&gt;lcd /directory/Outbound&lt;BR /&gt;cd upload&lt;BR /&gt;bin&lt;BR /&gt;prompt&lt;BR /&gt;mput *.LOG&lt;BR /&gt;EOF&lt;BR /&gt;rm /tmp/.ftpbusy&lt;BR /&gt;fi&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 06 Oct 2015 09:21:12 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ftp-script-to-transfer-archive-log-files-between-2-hp-ux-servers/m-p/6799682#M494729</guid>
      <dc:creator>DK_SYB</dc:creator>
      <dc:date>2015-10-06T09:21:12Z</dc:date>
    </item>
  </channel>
</rss>

