获取infoscale的相关信息

#! /bin/bash

echo "----生成dg stripe数量-----"

for i in {79..80}

do

ssh 172.20.244.${i} 'a=$(cat /etc/hostname);mkdir /tmp/infoscale;touch /tmp/infoscale/file-$a;dg=$(vxdg list | awk \{print\ \$1\} | grep -v "NAME");

for dgname in $dg

do

echo " "

echo "-------$dgname dg stripe-----"

echo $dgname  $(vxprint -hft -g $dgname | grep "STRIPE"|awk \{print\ \$8\} | awk -F / \{print\ \$1\}) >> /tmp/infoscale/file-$a

echo "-------$dgname dg countend----"

done'

done

echo "-----拉取dg stripe数量文件----"

for i in {79..80}

do

scp 172.20.244.${i}:/tmp/infoscale/* /tmp/infoscale

done

你可能感兴趣的:(获取infoscale的相关信息)