<?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: Auto day-end script problem in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053544#M137124</link>
    <description>The backup problem like tape error, no tape in tape drive, etc. Thanks.</description>
    <pubDate>Thu, 21 Aug 2003 06:16:25 GMT</pubDate>
    <dc:creator>ajk_5</dc:creator>
    <dc:date>2003-08-21T06:16:25Z</dc:date>
    <item>
      <title>Auto day-end script problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053543#M137123</link>
      <description>Dear all,&lt;BR /&gt;&lt;BR /&gt;I am working on the auto day-end process which will send email to system administrator if any backup problem. However my script doesn't work, how do I improve the script? Also, the backup_db_test.log has nothing inside, why is that?&lt;BR /&gt;&lt;BR /&gt;Thanks  !&lt;BR /&gt;&lt;BR /&gt;Regards&lt;BR /&gt;Ajk&lt;BR /&gt;&lt;BR /&gt;################################&lt;BR /&gt;# Perform Backup&lt;BR /&gt;################################&lt;BR /&gt;&lt;BR /&gt;DATE=`date "+%b %d"`&lt;BR /&gt;ADMIN_EMAIL=administrator@abc.com&lt;BR /&gt;echo&lt;BR /&gt;echo "Backup directories: /dskdump/livedbbackup"&lt;BR /&gt;echo "----------------------------------------"&lt;BR /&gt;echo "Insert a new tape into tape driver"&lt;BR /&gt;echo&lt;BR /&gt;echo "Press ENTER to start backup"&lt;BR /&gt;read dummy&lt;BR /&gt;&lt;BR /&gt;cd /dskdump/livedbbackup&lt;BR /&gt;$ISD_MENU/writelog.sh Backup Disk Dump DB Start&lt;BR /&gt;tar cvhf /dev/rmt/0m * &amp;gt;&amp;gt; $ISD_MENU/backup_db_test.log  &lt;BR /&gt;&lt;BR /&gt;if [`grep -i "cannot open" $ISD_MENU/isdadmin.log|wc -l` &amp;gt; 0] &lt;BR /&gt;then&lt;BR /&gt;grep "$DATE" $ISD_MENU/isdadmin.log|grep "cannot open"|mailx -s "Backup tape cannot open" $ADMIN_EMAIL&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;$ISD_MENU/writelog.sh Backup Disk Dump DB End&lt;BR /&gt;date&lt;BR /&gt;echo "Backup Finished !"&lt;BR /&gt;echo Press ENTER to continue...&lt;BR /&gt;read dummy&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 21 Aug 2003 06:14:34 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053543#M137123</guid>
      <dc:creator>ajk_5</dc:creator>
      <dc:date>2003-08-21T06:14:34Z</dc:date>
    </item>
    <item>
      <title>Re: Auto day-end script problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053544#M137124</link>
      <description>The backup problem like tape error, no tape in tape drive, etc. Thanks.</description>
      <pubDate>Thu, 21 Aug 2003 06:16:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053544#M137124</guid>
      <dc:creator>ajk_5</dc:creator>
      <dc:date>2003-08-21T06:16:25Z</dc:date>
    </item>
    <item>
      <title>Re: Auto day-end script problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053545#M137125</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;1) Nothing in the backup_db_test.loog because you never defined in this script the variable ISD_MENU. Also, quote it with graphes.&lt;BR /&gt;&lt;BR /&gt;$ISD_MENU/backup_db_test.log  --&amp;gt;&amp;gt; ${ISD_MENU}/backup_db_test.log &lt;BR /&gt;&lt;BR /&gt;So do for all variables used in the script, it's best.&lt;BR /&gt;&lt;BR /&gt;2) examinate the return code from tar:&lt;BR /&gt;&lt;BR /&gt;tar .....&lt;BR /&gt;RC=$?&lt;BR /&gt;&lt;BR /&gt;0 --&amp;gt;&amp;gt; all is OK&lt;BR /&gt;&amp;gt;0  --&amp;gt;&amp;gt; some errors, check&lt;BR /&gt;&lt;BR /&gt;3) you could think of using fbackup/frecover, it's faster and with better output. refer to man pages for use and to this forum for a list of config parameters...&lt;BR /&gt;&lt;BR /&gt;   Massimo</description>
      <pubDate>Thu, 21 Aug 2003 06:46:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053545#M137125</guid>
      <dc:creator>Massimo Bianchi</dc:creator>
      <dc:date>2003-08-21T06:46:54Z</dc:date>
    </item>
    <item>
      <title>Re: Auto day-end script problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053546#M137126</link>
      <description>Dears,&lt;BR /&gt;&lt;BR /&gt;I modify my script, but it is still not working and the log file has nothing inside. Please help. Thanks a lot!&lt;BR /&gt;&lt;BR /&gt;Regards&lt;BR /&gt;Ajk&lt;BR /&gt;&lt;BR /&gt;################################&lt;BR /&gt;# Perform Backup&lt;BR /&gt;################################&lt;BR /&gt;#/misadmin/isd_menu/baktp_time.sh&lt;BR /&gt;DATE=`date "+%b %d"`&lt;BR /&gt;ADMIN_EMAIL=administrator@abc.com&lt;BR /&gt;echo&lt;BR /&gt;echo "Backup directories: /dskdump/livedbbackup"&lt;BR /&gt;echo "----------------------------------------"&lt;BR /&gt;echo "Insert a new tape into tape driver"&lt;BR /&gt;echo&lt;BR /&gt;echo "Press ENTER to start backup"&lt;BR /&gt;read dummy&lt;BR /&gt;&lt;BR /&gt;cd /dskdump/livedbbackup&lt;BR /&gt;/misadmin/isd_menu/writelog.sh Backup Disk Dump DB Start&lt;BR /&gt;tar cvhf /dev/rmt/0m * &amp;gt;&amp;gt; /misadmin/isd_menu/backup_db_test.log&lt;BR /&gt;&lt;BR /&gt;RC=$? &lt;BR /&gt;&lt;BR /&gt;if [RC &amp;gt; 0]&lt;BR /&gt;then&lt;BR /&gt;mailx -s "Backup Error!" $ADMIN_EMAIL&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;#if [`grep -i "cannot open" $ISD_MENU/isdadmin.log|wc -l` &amp;gt; 0] &lt;BR /&gt;#then&lt;BR /&gt;#grep "$DATE" $ISD_MENU/isdadmin.log|grep "cannot open"|mailx -s "Backup tape cannot open" $ADMIN_EMAIL&lt;BR /&gt;#fi&lt;BR /&gt;&lt;BR /&gt;/misadmin/isd_menu/writelog.sh Backup Disk Dump DB End&lt;BR /&gt;date&lt;BR /&gt;echo "Backup Finished !"&lt;BR /&gt;echo Press ENTER to continue...&lt;BR /&gt;read dummy&lt;BR /&gt;</description>
      <pubDate>Fri, 22 Aug 2003 01:29:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053546#M137126</guid>
      <dc:creator>ajk_5</dc:creator>
      <dc:date>2003-08-22T01:29:37Z</dc:date>
    </item>
    <item>
      <title>Re: Auto day-end script problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053547#M137127</link>
      <description>These questions may seem silly:&lt;BR /&gt;&lt;BR /&gt;How are you launching this script? It seems familiar.  Is it by cron?  What's the cron entry?  &lt;BR /&gt;&lt;BR /&gt;Has it ever worked?&lt;BR /&gt;&lt;BR /&gt;Did you know that for cron launched scripts you need to build the environment for it, its not like a telnet or secure shell login session?&lt;BR /&gt;&lt;BR /&gt;What if any errors is this script generating.&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Fri, 22 Aug 2003 02:27:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053547#M137127</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2003-08-22T02:27:09Z</dc:date>
    </item>
    <item>
      <title>Re: Auto day-end script problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053548#M137128</link>
      <description>Hi,&lt;BR /&gt;for debugging purpose, as the second line put a&lt;BR /&gt;"set -x"&lt;BR /&gt;so all commands will be printed.&lt;BR /&gt;&lt;BR /&gt;Also: can you check with "ll" if the file and directory have proper permission for the user starting the commands ?&lt;BR /&gt;&lt;BR /&gt;Maybe the file is empty because it is not writeable by the user.&lt;BR /&gt;&lt;BR /&gt;  Massimo&lt;BR /&gt;</description>
      <pubDate>Fri, 22 Aug 2003 07:33:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053548#M137128</guid>
      <dc:creator>Massimo Bianchi</dc:creator>
      <dc:date>2003-08-22T07:33:18Z</dc:date>
    </item>
    <item>
      <title>Re: Auto day-end script problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053549#M137129</link>
      <description>One thing you might have an issue with is&lt;BR /&gt;&lt;BR /&gt;[ blah blah &amp;gt; 0 ]&lt;BR /&gt;&lt;BR /&gt;This, should be [ blag blah -gt 0 ]&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 22 Aug 2003 09:58:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/auto-day-end-script-problem/m-p/3053549#M137129</guid>
      <dc:creator>Mark Grant</dc:creator>
      <dc:date>2003-08-22T09:58:17Z</dc:date>
    </item>
  </channel>
</rss>

