query generated smart files
[gnt-info] / gnt-instance-fdisk.sh
1 #!/bin/sh -xe
2
3 instance=$1
4
5 node=`gnt-instance list --no-headers -o pnode $instance`
6 ssh $node fdisk -l /var/run/ganeti/instance-disks/$instance:0
7
8
9 exit 0
10
11 gnt-instance info --static $instance > /dev/shm/$instance
12 node=`grep 'primary:' /dev/shm/$instance | cut -d: -f2 | tr -d ' '`
13 lv=`grep 'logical_id:' /dev/shm/$instance | head -1 | cut -d: -f2 | tr -d ' '`
14 ssh $node fdisk -l /dev/$lv
15
16