euca-bundle-vol does not check rsync return code
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Eucalyptus |
Fix Released
|
Medium
|
Neil Soman | ||
euca2ools (Ubuntu) |
Fix Released
|
Medium
|
Dustin Kirkland |
Bug Description
Patch from Tim Gerla.
=== modified file 'euca2ools/
--- euca2ools/
+++ euca2ools/
@@ -986,7 +986,9 @@
print "Copying files..."
for exclude in excludes:
print "Excluding:", exclude
- output = Popen(rsync_cmd, stdout=PIPE, stderr=
+
+ pipe = Popen(rsync_cmd, stdout=PIPE, stderr=PIPE)
+ output = pipe.communicate()
for dir in self.img.
if not os.path.
@@ -1010,8 +1012,15 @@
print 'Making essential directory %s' % mount_location
mtab_file.close()
- if output[1]:
- raise CopyError
+ if pipe.returncode:
+ # rsync return code 23: Partial transfer due to error
+ # rsync return code 24: Partial transfer due to vanished source files
+ if pipe.returncode in (23, 24):
+ print "Warning: rsync reports files partially copied:"
+ print output
+ else:
+ print "Error: rsync failed with return code %d" % pipe.returncode
+ raise CopyError
def unmount_image(self, mount_point):
try:
Changed in euca2ools (Ubuntu): | |
status: | New → In Progress |
importance: | Undecided → Low |
importance: | Low → Medium |
assignee: | nobody → Dustin Kirkland (kirkland) |
Changed in eucalyptus: | |
status: | Fix Committed → Fix Released |
Fixed in revno 253.