<?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: Unattended backup tape advance how-to? in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/unattended-backup-tape-advance-how-to/m-p/2478855#M17899</link>
    <description>found the following which looks applicable ?&lt;BR /&gt;&lt;BR /&gt;Example chgvol script for fbackup to control tape libraries &lt;BR /&gt; DocId:&lt;BR /&gt;       KBAN00000401&lt;BR /&gt;                      &lt;BR /&gt;                      Updated:&lt;BR /&gt;                             20000706&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;DOCUMENT&lt;BR /&gt;&lt;BR /&gt;Below is an example chgvol script to enable the unattended use of tape&lt;BR /&gt;libraries and autoloaders with fbackup(1M). It is unsupported, but has&lt;BR /&gt;worked fine for many customers. It assumes the device file for the robotics&lt;BR /&gt;is at /dev/picker. This maybe changed in the script.&lt;BR /&gt;&lt;BR /&gt;Save this script in the file /var/adm/fbackupfiles/chgvol, and make it&lt;BR /&gt;executable. You will need to make sure that one of the switches on the&lt;BR /&gt;fbackup command line is -y. If you are using sam to&lt;BR /&gt;schedule the backups then it is recommended to do the following to add the -&lt;BR /&gt;y:&lt;BR /&gt;&lt;BR /&gt;1) cp /usr/sam/lbin/br_backup /usr/sam/lbin/br_backup.change&lt;BR /&gt;2) Change the cron job to call the modified br_backup.change&lt;BR /&gt;3) Edit the br_backup.change in the following two lines&lt;BR /&gt;&lt;BR /&gt;FULL) backup_type="-0" to&lt;BR /&gt;FULL) backup_type="-0 -y"&lt;BR /&gt;and&lt;BR /&gt;PART) backup_type="-1" to&lt;BR /&gt;PART) backup_type="-1 -y"&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Also you will need to use the -c option with fbackup, and specify&lt;BR /&gt;a configuration file(/var/adm/fbackupfiles/fbackup_config is a good&lt;BR /&gt;place for this file).  Sam does this automatically. You will just need&lt;BR /&gt;to edit the existing file.&lt;BR /&gt;&lt;BR /&gt;In this configuration file you should specify the following:&lt;BR /&gt;&lt;BR /&gt;blocksperrecord 128&lt;BR /&gt;records 32&lt;BR /&gt;checkpointfreq 256&lt;BR /&gt;readerprocesses 2&lt;BR /&gt;maxretries 5&lt;BR /&gt;retrylimit 5000000&lt;BR /&gt;maxvoluses 100&lt;BR /&gt;chgvol /var/adm/fbackupfiles/chgvol&lt;BR /&gt;filesperfsm 200&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;#!/usr/bin/sh&lt;BR /&gt;####################&lt;BR /&gt;# chgvol for autoloaders&lt;BR /&gt;# Revision 1.0&lt;BR /&gt;# Date: 12/21/99&lt;BR /&gt;# Author: James Kirkland / jtk@atl.hp.com&lt;BR /&gt;# Purpose: To allow fbackup to work with autoloaders&lt;BR /&gt;# NOTE! This script is not supported by HP.  It is provided as an example only!!&lt;BR /&gt;####################&lt;BR /&gt;&lt;BR /&gt;# Setting up variables&lt;BR /&gt;&lt;BR /&gt;TMPDIR=/var/tmp&lt;BR /&gt;RTDIR=/var/adm/chgvol&lt;BR /&gt;SES_FILE=$RTDIR/session&lt;BR /&gt;NUM=$TMPDIR/chg_num.tmp&lt;BR /&gt;PICKER=/dev/picker # device file for the robotic arm&lt;BR /&gt;&lt;BR /&gt;#scripting&lt;BR /&gt;&lt;BR /&gt;get_current_pid(){&lt;BR /&gt;NOW_PID=`ps -ef |grep fbackup |grep -v grep | cut -c 10-16`&lt;BR /&gt;return 0&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;is_sess_old (){&lt;BR /&gt;S_PID=`tail -1 $SES_FILE`&lt;BR /&gt;get_current_pid&lt;BR /&gt;if [ $NOW_PID -eq $S_PID ]&lt;BR /&gt;then&lt;BR /&gt;        echo "Continuing with current session from fbackup PID $S_PID"&lt;BR /&gt;else&lt;BR /&gt;        echo "This is the first tape change for fbackup PID $NOW_PID"&lt;BR /&gt;        echo $NOW_PID &amp;gt; $SES_FILE&lt;BR /&gt;        init_num&lt;BR /&gt;fi&lt;BR /&gt;return 0&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;init_num() {&lt;BR /&gt;echo "1" &amp;gt; $NUM&lt;BR /&gt;return 0&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;if [ -a $SES_FILE ]&lt;BR /&gt;then&lt;BR /&gt;        is_sess_old&lt;BR /&gt;else&lt;BR /&gt;        touch $SES_FILE&lt;BR /&gt;        is_sess_old&lt;BR /&gt;fi&lt;BR /&gt;if [ -a $NUM ]&lt;BR /&gt;then&lt;BR /&gt;        S_NUM=`cat $NUM`&lt;BR /&gt;else&lt;BR /&gt;        init_num&lt;BR /&gt;        S_NUM=`cat $NUM`&lt;BR /&gt;fi&lt;BR /&gt;S_NUM_OLD=$S_NUM&lt;BR /&gt;let S_NUM=S_NUM_OLD+1&lt;BR /&gt;if [ $S_NUM_OLD -gt 0 ]&lt;BR /&gt;then&lt;BR /&gt;        echo "Moving tape from Drive 1 to Slot $S_NUM_OLD ."&lt;BR /&gt;        mc -p $PICKER -s D1 -d S$S_NUM_OLD&lt;BR /&gt;        #err code needed&lt;BR /&gt;        echo "Moving tape from Slot $S_NUM to Drive 1 ."&lt;BR /&gt;        mc -p $PICKER -s S$S_NUM -d D1&lt;BR /&gt;        #err code needed&lt;BR /&gt;        echo $S_NUM &amp;gt; $NUM&lt;BR /&gt;        logger -t chgvol -p local0.info "Changing tape. Pulling from Slot&lt;BR /&gt;$S_NUM"&lt;BR /&gt;fi&lt;BR /&gt;exit 0</description>
    <pubDate>Thu, 04 Jan 2001 13:57:09 GMT</pubDate>
    <dc:creator>Alex Glennie</dc:creator>
    <dc:date>2001-01-04T13:57:09Z</dc:date>
    <item>
      <title>Unattended backup tape advance how-to?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unattended-backup-tape-advance-how-to/m-p/2478854#M17898</link>
      <description>Greetings,&lt;BR /&gt;&lt;BR /&gt;I am looking for a way to auto advance the tape in my HP C6366A during a SAM initiated backup under HPUX 11.0.  The C6366A is a 6-slot DAT drive library and I would like to find a way to auto advance the tape when it becomes full during a full backup.  Is there any facility to do this from within SAM or can I script this with 'fbackup' myself?  I have configured and been using the 'mc' command to auto advance the tape in between my SAM backups for the last year or so.  Now my volume groups have gotten a bit larger.&lt;BR /&gt;&lt;BR /&gt;I currently have a few fairly large logical volume groups. Might a better solution be to split them up into smaller groups?&lt;BR /&gt;&lt;BR /&gt;Any direction or advice is welcome.&lt;BR /&gt;&lt;BR /&gt;Thanks for your time.&lt;BR /&gt;</description>
      <pubDate>Thu, 04 Jan 2001 13:38:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unattended-backup-tape-advance-how-to/m-p/2478854#M17898</guid>
      <dc:creator>ANTHONY BARNES_1</dc:creator>
      <dc:date>2001-01-04T13:38:38Z</dc:date>
    </item>
    <item>
      <title>Re: Unattended backup tape advance how-to?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unattended-backup-tape-advance-how-to/m-p/2478855#M17899</link>
      <description>found the following which looks applicable ?&lt;BR /&gt;&lt;BR /&gt;Example chgvol script for fbackup to control tape libraries &lt;BR /&gt; DocId:&lt;BR /&gt;       KBAN00000401&lt;BR /&gt;                      &lt;BR /&gt;                      Updated:&lt;BR /&gt;                             20000706&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;DOCUMENT&lt;BR /&gt;&lt;BR /&gt;Below is an example chgvol script to enable the unattended use of tape&lt;BR /&gt;libraries and autoloaders with fbackup(1M). It is unsupported, but has&lt;BR /&gt;worked fine for many customers. It assumes the device file for the robotics&lt;BR /&gt;is at /dev/picker. This maybe changed in the script.&lt;BR /&gt;&lt;BR /&gt;Save this script in the file /var/adm/fbackupfiles/chgvol, and make it&lt;BR /&gt;executable. You will need to make sure that one of the switches on the&lt;BR /&gt;fbackup command line is -y. If you are using sam to&lt;BR /&gt;schedule the backups then it is recommended to do the following to add the -&lt;BR /&gt;y:&lt;BR /&gt;&lt;BR /&gt;1) cp /usr/sam/lbin/br_backup /usr/sam/lbin/br_backup.change&lt;BR /&gt;2) Change the cron job to call the modified br_backup.change&lt;BR /&gt;3) Edit the br_backup.change in the following two lines&lt;BR /&gt;&lt;BR /&gt;FULL) backup_type="-0" to&lt;BR /&gt;FULL) backup_type="-0 -y"&lt;BR /&gt;and&lt;BR /&gt;PART) backup_type="-1" to&lt;BR /&gt;PART) backup_type="-1 -y"&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Also you will need to use the -c option with fbackup, and specify&lt;BR /&gt;a configuration file(/var/adm/fbackupfiles/fbackup_config is a good&lt;BR /&gt;place for this file).  Sam does this automatically. You will just need&lt;BR /&gt;to edit the existing file.&lt;BR /&gt;&lt;BR /&gt;In this configuration file you should specify the following:&lt;BR /&gt;&lt;BR /&gt;blocksperrecord 128&lt;BR /&gt;records 32&lt;BR /&gt;checkpointfreq 256&lt;BR /&gt;readerprocesses 2&lt;BR /&gt;maxretries 5&lt;BR /&gt;retrylimit 5000000&lt;BR /&gt;maxvoluses 100&lt;BR /&gt;chgvol /var/adm/fbackupfiles/chgvol&lt;BR /&gt;filesperfsm 200&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;#!/usr/bin/sh&lt;BR /&gt;####################&lt;BR /&gt;# chgvol for autoloaders&lt;BR /&gt;# Revision 1.0&lt;BR /&gt;# Date: 12/21/99&lt;BR /&gt;# Author: James Kirkland / jtk@atl.hp.com&lt;BR /&gt;# Purpose: To allow fbackup to work with autoloaders&lt;BR /&gt;# NOTE! This script is not supported by HP.  It is provided as an example only!!&lt;BR /&gt;####################&lt;BR /&gt;&lt;BR /&gt;# Setting up variables&lt;BR /&gt;&lt;BR /&gt;TMPDIR=/var/tmp&lt;BR /&gt;RTDIR=/var/adm/chgvol&lt;BR /&gt;SES_FILE=$RTDIR/session&lt;BR /&gt;NUM=$TMPDIR/chg_num.tmp&lt;BR /&gt;PICKER=/dev/picker # device file for the robotic arm&lt;BR /&gt;&lt;BR /&gt;#scripting&lt;BR /&gt;&lt;BR /&gt;get_current_pid(){&lt;BR /&gt;NOW_PID=`ps -ef |grep fbackup |grep -v grep | cut -c 10-16`&lt;BR /&gt;return 0&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;is_sess_old (){&lt;BR /&gt;S_PID=`tail -1 $SES_FILE`&lt;BR /&gt;get_current_pid&lt;BR /&gt;if [ $NOW_PID -eq $S_PID ]&lt;BR /&gt;then&lt;BR /&gt;        echo "Continuing with current session from fbackup PID $S_PID"&lt;BR /&gt;else&lt;BR /&gt;        echo "This is the first tape change for fbackup PID $NOW_PID"&lt;BR /&gt;        echo $NOW_PID &amp;gt; $SES_FILE&lt;BR /&gt;        init_num&lt;BR /&gt;fi&lt;BR /&gt;return 0&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;init_num() {&lt;BR /&gt;echo "1" &amp;gt; $NUM&lt;BR /&gt;return 0&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;if [ -a $SES_FILE ]&lt;BR /&gt;then&lt;BR /&gt;        is_sess_old&lt;BR /&gt;else&lt;BR /&gt;        touch $SES_FILE&lt;BR /&gt;        is_sess_old&lt;BR /&gt;fi&lt;BR /&gt;if [ -a $NUM ]&lt;BR /&gt;then&lt;BR /&gt;        S_NUM=`cat $NUM`&lt;BR /&gt;else&lt;BR /&gt;        init_num&lt;BR /&gt;        S_NUM=`cat $NUM`&lt;BR /&gt;fi&lt;BR /&gt;S_NUM_OLD=$S_NUM&lt;BR /&gt;let S_NUM=S_NUM_OLD+1&lt;BR /&gt;if [ $S_NUM_OLD -gt 0 ]&lt;BR /&gt;then&lt;BR /&gt;        echo "Moving tape from Drive 1 to Slot $S_NUM_OLD ."&lt;BR /&gt;        mc -p $PICKER -s D1 -d S$S_NUM_OLD&lt;BR /&gt;        #err code needed&lt;BR /&gt;        echo "Moving tape from Slot $S_NUM to Drive 1 ."&lt;BR /&gt;        mc -p $PICKER -s S$S_NUM -d D1&lt;BR /&gt;        #err code needed&lt;BR /&gt;        echo $S_NUM &amp;gt; $NUM&lt;BR /&gt;        logger -t chgvol -p local0.info "Changing tape. Pulling from Slot&lt;BR /&gt;$S_NUM"&lt;BR /&gt;fi&lt;BR /&gt;exit 0</description>
      <pubDate>Thu, 04 Jan 2001 13:57:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unattended-backup-tape-advance-how-to/m-p/2478855#M17899</guid>
      <dc:creator>Alex Glennie</dc:creator>
      <dc:date>2001-01-04T13:57:09Z</dc:date>
    </item>
  </channel>
</rss>

