>>>>> "Brian" == Brian W Spolarich <[EMAIL PROTECTED]> writes:
Brian> What about moving the volumes from one partition to another? i.e.
Brian> attach the new disk, mount it as a new /vice partition, and do a
Brian> for volume in partition
Brian> do
Brian> echo "Moving volume $volume..."
Brian> vos move -id $volume -fromserver <servername> -frompartition <oldpart> \
Brian> -toserver <servername> -topartition <newpart>
Brian> done
It would really be nice if that worked, but your pseudo-code assumes
everything is a RW volume. Moving replicated volumes is far more
complex.
for volume in partition(s)
do
if [[ volume is not replicated ]]
vos move
then
elif [[ volume is RO, but not a RO Clone ]]
then
vos addsite new RO
vos release
vos remove the old RO
elif [[ volume is RO clone or volume is a BK ]]
then
skip it (handled below)
elif [[ volume is RW and replicated ]]
then
vos remove the RO clone
vos move the RW
vos addsite the RO clone
vos release
fi
done
You also probably want some code to balance the data across a number
of partitions as the move ie being done, using a list of target
server/partitions.
You may also want to vos backup the RW volumes after they have been
moved as well.
This is hard. In fact, the code we have which automates this is 500
lines long, not counting a couple of external libraries it uses (its
all perl5, BTW). It also takes a while. You may want to parallelize
the code (which is also hard) to process multiple volumes at once.
To make a long story really short: this is why we use redundant disks
for our critical AFS servers. On our old SunOS 4.1.3 serers, we use
Sun;s Online Disk Suite (ODS) to mirror all the /vicep*, and on newer
servers we use RAID Arrays.
W. Phillip Moore Phone: (212)-762-2433
Information Technology Department FAX: (212)-762-1009
Morgan Stanley and Co. E-mail: [EMAIL PROTECTED]
750 7th Ave, NY, NY 10019
"Grant me the serenity to accept the things I cannot change, the
courage to change the things I can, and the wisdom to hide the
bodies of the people that I had to kill because they pissed me
off."
-- Anonymous
"Every normal man must be tempted at times to spit on his
hands, hoist the black flag, and begin slitting throats."
-- H.L. Mencken