Views

How can I create and delete drives from the command line?

This Wiki is brought to you by Backup Central, where you can find the Mr. Backup Blog, Forums, and a mailing list for each forum!

Backup FAQs Service Providers Backup Software Backup Hardware Backup Book Wiki Free Stuff Miscellaneous


There are some undocumented flags for the "tpconfig" command.

Here's the usage statement that you can pick out if you run "strings tpconfig":

Usage:

tpconfig [-d]

tpconfig -l

tpconfig -add -drive < drvindex > -type < drvtype > -name < drvname > -altname

           < altdrvname > [-vhname < vhdrvname >] [-drstatus [UP|DOWN]]
           [-cleanfreq < hours >] [-robot < robnum > -robtype < robtype >
           -robdrnum < robdrvnum > [-ACS < acsnum > -LSM < lsmnum >
           -PANEL < panelnum >]]


tpconfig -add -robot < robnum > -robtype < robtype > [-robpath < devfile >]

           [-cntlhost < cntlhost >] [-vdbhost < volume_database_host >]


tpconfig -update -drive < drvindex >

           [-type < drvtype >] [-name < drvname >] [-altname < altdrvname >]
           [-vhname < vhdrvname >] [-drstatus [UP|DOWN]] [-cleanfreq < hours >]
           [-robot < robnum > -robtype < robtype > -robdrnum < robdrvnum >
           [-ACS < acsnum > -LSM < lsmnum > -PANEL < panelnum >]]


tpconfig -update -robot < robnum > [-robtype < robtype >] [-robpath < devfile >]

           [-cntlhost < cntlhost >] [-vdbhost < volume_database_host >]


tpconfig -delete -drive < drvindex > Here is someting we found out using tpconfig undocumented flags to automate our tape/robot configuration procedures: -name flag did not set dirve name correctly, but -asciiname flag did. For SSO, -multihost yes worked (we stringsed tpconfig and noticed those two flags not listed in the usage lines). Here is the command we used: /usr/openv/volmgr/bin/tpconfig -add -drive $drivendex -type hcart -asciiname $drivename -altname $drivepath -drstatus UP -robot 0 -robtype tld -robdrnum $drivenumber -multihost yes

FYI: we only use this procedure on HP platforms. On Sun platform, we make sure the tape device paths are identical on all SAN media servres so all we need to do is to copy the existing /usr/openv/volmgr/database/ltidevs and /usr/openv/volmgr/database/robotic_def files. This makes configuring many SAN media servers fairly easy.