Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot convert xva file #1

Open
mfechner opened this issue Aug 14, 2014 · 3 comments
Open

Cannot convert xva file #1

mfechner opened this issue Aug 14, 2014 · 3 comments

Comments

@mfechner
Copy link

I just create a xva file from a xenserver 6.2 untared it and execute:

python2 xenmigrate_new.py  -c Ref\:32/ test.img

Bit I get the error message:

xenmigrate 0.7.4 -- 2011.09.13
(c)2011 Jolokia Networks and Mark Pace -- jolokianetworks.com

convert ref dir   : Ref:32/
to raw file       : test.img
last file         : 40986
disk image size   : 40 GB

RW notification every: 1.0GB
Converting:
Traceback (most recent call last):
  File "xenmigrate_new.py", line 508, in <module>
    reftoraw(opts.convert,args[0],opts.gz)
  File "xenmigrate_new.py", line 358, in reftoraw
    source.close()
UnboundLocalError: local variable 'source' referenced before assignment
@m34nbunny
Copy link

I know this is old; however for anyone wanting to fix it, search the file and replace every instance that is within a

finally:
try:
source.close()

replace with

finally:
try:
"""source.close()"""

Not a permanent solution but it will start converting the file.

@derekjhyang
Copy link
Owner

@MeanBunny , thank you for your comment. I know that is old but I can work in Xenserver 5.5

@javax-sousa
Copy link

I modified it according to the suggestion above, but it still didn't work:
error log:
enmigrate 0.7.4 -- 2011.09.13
(c)2011 Jolokia Networks and Mark Pace -- jolokianetworks.com

convert ref dir : Ref:26
to raw file : disk.img
last file : 51200
disk image size : 50 GB

RW notification every: 1.0GB
Converting:
Traceback (most recent call last):
File "xenmigrate.py", line 507, in
reftoraw(opts.convert,args[0],opts.gz)
File "xenmigrate.py", line 357, in reftoraw
source.close()
UnboundLocalError: local variable 'source' referenced before assignment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants