Attached is a patch that should address this issue. Basically, it will try up to three times to unmount the disk, rather than failing on the first time. Example output from an attempt that would have previously failed:
...
2009-03-24 00:42:12,075 INFO Unmounting target filesystem
2009-03-24 00:42:12,076 DEBUG Unmounting /tmp/vmbuilderYGTk5J/target/
2009-03-24 00:42:12,076 DEBUG ['umount', '/tmp/vmbuilderYGTk5J/target/']
2009-03-24 00:42:12,488 INFO Attempting to unmount disk '/tmp/vmbuilderYGTk5J/disk0.img'
2009-03-24 00:42:12,489 DEBUG ['kpartx', '-d', '/tmp/vmbuilderYGTk5J/disk0.img']
2009-03-24 00:42:12,502 INFO device-mapper: remove ioctl failed: Device or resource busy
2009-03-24 00:42:12,504 INFO ioctl: LOOP_CLR_FD: Device or resource busy
2009-03-24 00:42:12,504 INFO Failed to unmount disk '/tmp/vmbuilderYGTk5J/disk0.img'
2009-03-24 00:42:15,507 INFO Attempting to unmount disk '/tmp/vmbuilderYGTk5J/disk0.img'
2009-03-24 00:42:15,507 DEBUG ['kpartx', '-d', '/tmp/vmbuilderYGTk5J/disk0.img']
2009-03-24 00:42:15,519 DEBUG loop deleted : /dev/loop6
2009-03-24 00:42:15,520 INFO Converting /tmp/vmbuilderYGTk5J/disk0.img to qcow2, format debian-kvm/disk0.qcow2
...
Attached is a patch that should address this issue. Basically, it will try up to three times to unmount the disk, rather than failing on the first time. Example output from an attempt that would have previously failed: GTk5J/target/ YGTk5J/ target/ '] YGTk5J/ disk0.img' YGTk5J/ disk0.img' ] YGTk5J/ disk0.img' YGTk5J/ disk0.img' YGTk5J/ disk0.img' ] GTk5J/disk0. img to qcow2, format debian- kvm/disk0. qcow2
...
2009-03-24 00:42:12,075 INFO Unmounting target filesystem
2009-03-24 00:42:12,076 DEBUG Unmounting /tmp/vmbuilderY
2009-03-24 00:42:12,076 DEBUG ['umount', '/tmp/vmbuilder
2009-03-24 00:42:12,488 INFO Attempting to unmount disk '/tmp/vmbuilder
2009-03-24 00:42:12,489 DEBUG ['kpartx', '-d', '/tmp/vmbuilder
2009-03-24 00:42:12,502 INFO device-mapper: remove ioctl failed: Device or resource busy
2009-03-24 00:42:12,504 INFO ioctl: LOOP_CLR_FD: Device or resource busy
2009-03-24 00:42:12,504 INFO Failed to unmount disk '/tmp/vmbuilder
2009-03-24 00:42:15,507 INFO Attempting to unmount disk '/tmp/vmbuilder
2009-03-24 00:42:15,507 DEBUG ['kpartx', '-d', '/tmp/vmbuilder
2009-03-24 00:42:15,519 DEBUG loop deleted : /dev/loop6
2009-03-24 00:42:15,520 INFO Converting /tmp/vmbuilderY
...