At present when inspecting a file based image we always use ``qemu-img`` to
determine the virtual size of the image. This works well but can lead to
the resource tracker taking considerable time to update on hosts with
a large number of instances/images.
This change switches to using os.stat and os.path.getsize to determine
the allocated and virtual disk sizes of RAW disks.
Future changes will look into caching the virtual size of the disk
within disk.info locally on the host to also improve this for qcow2 and
ploop, further simplifying this code path.
Closes-bug: #1785827
Change-Id: Ic5c41493dcdcd807209be2beaae0dbbdf5d2ba3f
(cherry picked from commit e6af812865)
(cherry picked from commit bda6173a84)
(cherry picked from commit b58805753a)