retspen / webvirtmgr

WebVirtMgr panel for manage virtual machine
http://retspen.github.io
2.05k stars 537 forks source link

500 internal error #599

Open qiuchengxuan opened 8 years ago

qiuchengxuan commented 8 years ago

seems I created a iface with virsh and failed to commit, then this issue occurs.


ERROR:django.request:Internal Server Error: /interfaces/1/ Traceback (most recent call last): File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/core/handlers/base.py", line 115, in get_response response = callback(request, _callback_args, _callback_kwargs) File "/media/nas/dev/webvirtmgr/interfaces/views.py", line 53, in interfaces return render_to_response('interfaces.html', locals(), context_instance=RequestContext(request)) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/shortcuts/init.py", line 29, in render_to_response return HttpResponse(loader.render_to_string(_args, _kwargs), **httpresponse_kwargs) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/loader.py", line 177, in render_to_string return t.render(context_instance) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/base.py", line 140, in render return self._render(context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/base.py", line 134, in _render return self.nodelist.render(context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/base.py", line 830, in render bit = self.render_node(node, context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/base.py", line 844, in render_node return node.render(context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/loader_tags.py", line 124, in render return compiled_parent._render(context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/base.py", line 134, in _render return self.nodelist.render(context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/base.py", line 830, in render bit = self.render_node(node, context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/base.py", line 844, in render_node return node.render(context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/loader_tags.py", line 63, in render result = block.nodelist.render(context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/base.py", line 830, in render bit = self.render_node(node, context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/base.py", line 844, in render_node return node.render(context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/defaulttags.py", line 285, in render return nodelist.render(context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/base.py", line 830, in render bit = self.render_node(node, context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/base.py", line 844, in render_node return node.render(context) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/defaulttags.py", line 196, in render nodelist.append(node.render(context)) File "/home/qiubuyi/.local/lib/python2.7/site-packages/django/template/defaulttags.py", line 426, in render raise e NoReverseMatch: Reverse for 'interface' with arguments '(u'1', 'openwrt-bridge')' and keyword arguments '{}' not found.


ifconfig | grep Link br0 Link encap:Ethernet HWaddr 3c:a8:2a:9f:43:f0
inet6 addr: fe80::3ea8:2aff:fe9f:43f0/64 Scope:Link em1 Link encap:Ethernet HWaddr 3c:a8:2a:9f:43:f0
lo Link encap:Local Loopback
vnet0 Link encap:Ethernet HWaddr fe:54:00:f4:73:0a
inet6 addr: fe80::fc54:ff:fef4:730a/64 Scope:Link


brctl show bridge name bridge id STP enabled interfaces br0 8000.3ca82a9f43f0 no em1 vnet0


virsh iface-dumpxml openwrt-bridge `

`

zingmars commented 7 years ago

I know that you've probably moved on, but for future reference it's an issue with the route for interfaces not taking dashes into consideration (something similar has happened before - https://github.com/retspen/webvirtmgr/issues/436). I submitted a pull request (https://github.com/retspen/webvirtmgr/pull/647), but since the project seems to be dead, I wouldn't count on it being accepted.