#!/bin/bash #returns size of a disc in Mb SIZE=`sfdisk -s $1` || exit 1 (( SIZE = SIZE / 1000 )) echo "$SIZE"