mirror of
https://github.com/retspen/webvirtmgr.git
synced 2026-04-25 15:45:51 +03:00
[GH-ISSUE #353] Cloning Failed, Getting 500 errors when attempting to access anything #263
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @goshlanguage on GitHub (Jun 30, 2014).
Original GitHub issue: https://github.com/retspen/webvirtmgr/issues/353
I was cloning a VM from the Instance menu and it failed abruptly without any indication of an error.
Now, when I try to access instances I receive a 500 error and cannot remove any instance of the failed VM. I assume I'll need to remove the cloned instance that failed to copy from the database in order to resolve my issue, however here is the stacktrace obtained by running Webvirtmgr in Debug mode and watching the console:
ERROR:django.request:Internal Server Error: /instances/1/
Traceback (most recent call last):
File "/usr/lib/python2.6/site-packages/django/core/handlers/base.py", line 115, in get_response
response = callback(request, _callback_args, *_callback_kwargs)
File "/var/www/webvirtmgr/instance/views.py", line 429, in instances
return render_to_response('instances.html', locals(), context_instance=RequestContext(request))
File "/usr/lib/python2.6/site-packages/django/shortcuts/init.py", line 29, in render_to_response
return HttpResponse(loader.render_to_string(_args, *_kwargs), **httpresponse_kwargs)
File "/usr/lib/python2.6/site-packages/django/template/loader.py", line 177, in render_to_string
return t.render(context_instance)
File "/usr/lib/python2.6/site-packages/django/template/base.py", line 140, in render
return self._render(context)
File "/usr/lib/python2.6/site-packages/django/template/base.py", line 134, in _render
return self.nodelist.render(context)
File "/usr/lib/python2.6/site-packages/django/template/base.py", line 830, in render
bit = self.render_node(node, context)
File "/usr/lib/python2.6/site-packages/django/template/base.py", line 844, in render_node
return node.render(context)
File "/usr/lib/python2.6/site-packages/django/template/loader_tags.py", line 124, in render
return compiled_parent._render(context)
File "/usr/lib/python2.6/site-packages/django/template/base.py", line 134, in _render
return self.nodelist.render(context)
File "/usr/lib/python2.6/site-packages/django/template/base.py", line 830, in render
bit = self.render_node(node, context)
File "/usr/lib/python2.6/site-packages/django/template/base.py", line 844, in render_node
return node.render(context)
File "/usr/lib/python2.6/site-packages/django/template/loader_tags.py", line 63, in render
result = block.nodelist.render(context)
File "/usr/lib/python2.6/site-packages/django/template/base.py", line 830, in render
bit = self.render_node(node, context)
File "/usr/lib/python2.6/site-packages/django/template/base.py", line 844, in render_node
return node.render(context)
File "/usr/lib/python2.6/site-packages/django/template/defaulttags.py", line 285, in render
return nodelist.render(context)
File "/usr/lib/python2.6/site-packages/django/template/base.py", line 830, in render
bit = self.render_node(node, context)
File "/usr/lib/python2.6/site-packages/django/template/base.py", line 844, in render_node
return node.render(context)
File "/usr/lib/python2.6/site-packages/django/template/defaulttags.py", line 196, in render
nodelist.append(node.render(context))
File "/usr/lib/python2.6/site-packages/django/template/defaulttags.py", line 426, in render
raise e
NoReverseMatch: Reverse for 'instance' with arguments '(u'1', 'Git Server')' and keyword arguments '{}' not found.
[30/Jun/2014 05:39:44] "GET /instances/1/ HTTP/1.1" 500 1831
[30/Jun/2014 05:39:44] "GET /static/css/bootstrap.min.css HTTP/1.1" 304 0
[30/Jun/2014 05:39:44] "GET /static/js/jquery-1.10.2.js HTTP/1.1" 304 0
[30/Jun/2014 05:39:44] "GET /static/css/webvirtmgr.css HTTP/1.1" 304 0
[30/Jun/2014 05:39:44] "GET /static/js/bootstrap.min.js HTTP/1.1" 304 0
Can you offer any advice? This occured after trying to clone the instance (powered off from the instance settings tab). Is this a bug?
@goshlanguage commented on GitHub (Jun 30, 2014):
I have attempted to remove the instance from the instance_instance table, however it has been unsuccessful, even after trying to run ./manage syncdb afterward. I probably don't know how ./manage syncdb works.
I am still getting the same error message, and if I grep for "Git Server" (the name of the instance I wanted to clone), it's found in the webvirtmgr.sqlite3 file.
Any advice on where this might still be referenced? I search all of the tables I could fine:
I have removed the only instance I found from instance_instance but it seems to still be there.
Thank you in advance for any help.
@retspen commented on GitHub (Jun 30, 2014):
You use name with space 'Git Server'. Can you rename your server like that 'Git_Server'
@goshlanguage commented on GitHub (Jun 30, 2014):
How can I, I can't access anything from the dashboard? Also, I have removed it from the Database in instance_instance, have I done that correctly and are there other places where I need to do so?
@goshlanguage commented on GitHub (Jun 30, 2014):
I have tracked the issue through line 429 of webvirtmgr/instance/views.py and it looks like it's pulling the data from virsh through qemu:///system using the provided credentials.
I'm not able to delete this instance through virsh:
http://serverfault.com/questions/609026/virsh-domain-has-space-in-it-can-not-remove
Do you know how I might remove this and resolve this issue? Also, I'd recommend that the clone server field in settings check for spaces and throw an error if illegal characters are present, preferably before it clones a vm and causes this issue.
@goshlanguage commented on GitHub (Jun 30, 2014):
I was able to fix this through the answer in my serverfault question. For any other affected parties you can stop libvirt and remove the offending server clone from /etc/libvirt/qemu/ and then start libvirt to resolve this problem.
@retspen commented on GitHub (Jun 30, 2014):
You can do that (input \ after first word):
$ virsh stop GIt\ Server