The code below is meant to calculate the percentage completed when a file is getting dd.
percentDone=$(((varFileSize / backupSize) * 100)
percentDone=$((varFileSize / backupSize))
percentDone=$((percentDone * 100))
Since bash only supports integers you have to do the calculation other way around:
percentDone=$(varFileSize * 100 / backupSize)
Otherwise dividing anything less than
backupSize with it will result in zero and multiplying it with anything won't help.