How to export smaller LUNs out of a SpycerBox

Permanently deleted user -

Location of the script is:


Find the portion that looks like:

devlist=$(lsscsi |grep -i "LSI" | awk '{print $6}' | sed "s/\/dev\///")
for DEVICE in $devlist ; do

   size=$(cat /proc/partitions |grep -m1 "$DEVICE" | tr -s " " |cut -d " " -f 4)
   if [ $size -gt 1800000000 ] ; then
      echo "Found storage disk: $DEVICE"
      LABEL=`printf "sb-${host_id}_data%d" $I`
      echo "open $LABEL /dev/$DEVICE BLOCKIO" > /proc/scsi_tgt/vdisk/vdisk
      echo "add $LABEL $I" > /proc/scsi_tgt/groups/Default/devices
      ((I += 1))
      echo "Create vdisk: $LABEL"

done ;

the 1800000000 means export any disk larger that 1.8Tb.

750000000 means 750Gb

10000000 means 100Gb


BE WARNED! if you export the metadata volume (which is always the smallest disk), you will ALSO be exporting the OS drive.

Have more questions? Submit a request


Article is closed for comments.