[PLUGIN] Web Virtual Manager (depreciated)


dmacias

Recommended Posts

Sooo, I accidentally created an instance from XML with a space in the server name.  Virtman was displeased.  Now, I can't access the instances page.  Every time I do, I get a 500 error.  I have looked all over to find where these things are stored so I can delete the offending image, but I'm at a loss.  I have tried the github repo for virtman itself, but the FAQ is written in cyrillic.  Which I am at best unqualified to even attempt.

 

If anyone can point me in the right direction, I'd be very grateful!

 

TIA,

 

P

 

You should be able to enter this in console. Just put the \ before the space The second command restarts libvirt

rm /etc/libvirt/qemu/NAME\ WITHSPACE.xml
/etc/rc.d/rc.libvirt restart

Link to comment
  • Replies 157
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

I've got the beta10 version of libvirt plugin installed, and the 2014.09.18 WebVirtMgr installed with Beta10a.

 

When I restart my unRAID server, both virtMan and VM Manager show up in the Settings with a status of "Stopped".  I thought both were supposed to start during boot, as I don't see any settings for autostart.

 

Am I correct in thinking something is wrong because these plugins aren't starting?  If so, any suggestions on troubleshooting?  I do not so any errors in the log.

 

The only thing "special" I can think of is I am mounting /mnt/btrfs (an ssd drive) in my go script, and pointing WebVirtMgr there instead of to my cache drive.

I updated them both now. Try removing the plugins from the plugin menu then reinstalling using the links from the first post. I renamed the webvirtmgr repo but old link should still work. 

Link to comment

I rebooted onto 10a w/o updating the two plugins that seem to be showing updates.  And everything started all the way up (libvirt/webvirtmgr) and my VM booted.

 

 

I see this in plugin's though.  Is it ok to install these updates?  do I need to make any configuration changes?

I would just remove both and reinstall from the plugin menu using the new links on the first page. Your settings won't be removed. I updated both today.

Link to comment

I've got the beta10 version of libvirt plugin installed, and the 2014.09.18 WebVirtMgr installed with Beta10a.

 

When I restart my unRAID server, both virtMan and VM Manager show up in the Settings with a status of "Stopped".  I thought both were supposed to start during boot, as I don't see any settings for autostart.

 

Am I correct in thinking something is wrong because these plugins aren't starting?  If so, any suggestions on troubleshooting?  I do not so any errors in the log.

 

The only thing "special" I can think of is I am mounting /mnt/btrfs (an ssd drive) in my go script, and pointing WebVirtMgr there instead of to my cache drive.

Also if you moved the webvirtmgr directory you might have changed the permissions. To fix you can change the Run as User from nobody to root.  Click apply. Then change back to nobody and click apply again. Then it should start.

Link to comment

You should be able to enter this in console. Just put the \ before the space The second command restarts libvirt

rm /etc/libvirt/qemu/NAME\ WITHSPACE.xml
/etc/rc.d/rc.libvirt restart

 

Thanks dmacias!!  I was actually composing my reply (below) when you posted this.  I approached a different way after some googling:

 

Figured it out.  For anyone else in my position, to delete the VM, you have to destroy it, then undefine it:

 

virsh destroy "Spaces are anathema to Linux-VM"

 

virsh undefine "Spaces are anathema to Linux-VM"

 

And then the VM management page will reappear.  Because spaces.

 

Very glad to know where it stores the XML files though, I'm sure it will come in handy.  Not sure why I didn't thnk of undefine before...maybe cause destroy sounds so much more final...  :)

 

Thanks again!

 

P

Link to comment

On B10, and cant start this manager, I see this in my syslog

 

Oct  2 19:38:04 Tower php: /etc/rc.d/rc.webvirtmgr buttonstart  
Oct  2 19:38:04 Tower php: Starting Web Virtual Manager
Oct  2 19:38:05 Tower sudo:     root : TTY=unknown ; PWD=/usr/local/emhttp ; USER=root ; COMMAND=/bin/bash -c nohup /usr/bin/python /mnt/cache/appdata/webvirtmgr/manage.py runserver 0:8010 > /dev/null 2>&1 &
Oct  2 19:38:18 Tower php: Application did not start for some reason
Oct  2 19:38:19 Tower php: ... Start Failed
Oct  2 19:38:20 Tower php: 

 

Did a re install, now all OK.

 

//Peter

Link to comment

On B10, and cant start this manager, I see this in my syslog

 

Oct  2 19:38:04 Tower php: /etc/rc.d/rc.webvirtmgr buttonstart  
Oct  2 19:38:04 Tower php: Starting Web Virtual Manager
Oct  2 19:38:05 Tower sudo:     root : TTY=unknown ; PWD=/usr/local/emhttp ; USER=root ; COMMAND=/bin/bash -c nohup /usr/bin/python /mnt/cache/appdata/webvirtmgr/manage.py runserver 0:8010 > /dev/null 2>&1 &
Oct  2 19:38:18 Tower php: Application did not start for some reason
Oct  2 19:38:19 Tower php: ... Start Failed
Oct  2 19:38:20 Tower php: 

 

Did a re install, now all OK.

 

//Peter

Did you have the latest versions? Might try changing users back and forth to fix permissions.

Link to comment

Latest version, and I did switched between root & nobody, no success, then I chose a different location and did a re install, so all good now.

 

//Peter

So do think it was a permission problem? Had moved directory or applied permissions to appdata.  Just curious cause I had it happen too but I had moved it to my docroot of my web server. So I just assumed I had applied web server user to directory.  I think I will have the plg apply runas user permissions on start instead of just on location change.

Link to comment

dmacias :

 

By the way, I still can't click on the Green "RUNNING", it still tries to open on the UNRAID:PORT.  Like I reported already, on the Mac, that doesn't work as you have to point to :

 

UNRAID.local:PORT

 

OR

 

IPOFUNRAID:PORT

 

Can this be configurable or auto/Detect in the Page ?

Link to comment

dmacias :

 

By the way, I still can't click on the Green "RUNNING", it still tries to open on the UNRAID:PORT.  Like I reported already, on the Mac, that doesn't work as you have to point to :

 

UNRAID.local:PORT

 

OR

 

IPOFUNRAID:PORT

 

Can this be configurable or auto/Detect in the Page ?

It is auto detected. "gethostname()"  You could go to settings/identification and change your server name to UNRAID.local or define a hostname for unRaid in your router or turn on DNS.  Also on your Mac in /etc/hosts you could define the host value for unRAID "UNRAID xx.xx.xx.xx".

 

Edit. Basically its a problem with DNS on your network or on your MAC.

Link to comment

Just needed to drop by for a sec and say this:  dmacias, you are the man!  Your work on this has been really helpful for folks here and continues to be.  I'm going to sticky this thread here because web virt manager is essential for anyone looking to get started with KVM in unRAID right now.  Thanks again for your hard work here!

Link to comment

dmacias :

 

By the way, I still can't click on the Green "RUNNING", it still tries to open on the UNRAID:PORT.  Like I reported already, on the Mac, that doesn't work as you have to point to :

 

UNRAID.local:PORT

 

OR

 

IPOFUNRAID:PORT

 

Can this be configurable or auto/Detect in the Page ?

It is auto detected. "gethostname()"  You could go to settings/identification and change your server name to UNRAID.local or define a hostname for unRaid in your router or turn on DNS.  Also on your Mac in /etc/hosts you could define the host value for unRAID "UNRAID xx.xx.xx.xx".

 

Edit. Basically its a problem with DNS on your network or on your MAC.

 

I'll check what i'll do.  On Mac, it is like that since OS X.  Any hosts on LAN need a .local to go to it.

Link to comment

I know the recent Betas have had vfio-bind included with the unRAID image.  Do these plugins handle the vfio-bind element of passthrough setup?  Or is it necessary to add a vfio-bind call to (I assume) the go script?

 

Thanks!

The latter of the two (go script).

 

Working to change that ;-)

Link to comment

I'm struggling with GPU passthrough using the new plugin.  It seems like the old qemu:commandline tags are ignored, and I'm not having any luck with the hostdev tags. 

 

Does anyone have GPU passthrough working for windows (I'm trying for Win7)?  If so, I'd appreciate hints or the relevant pieces of your xml file.

 

Part of my problem is that if I use dmacias' vnc settings, that allows vnc, but seems to break the GPU drivers.  If I don't include the vnc settings, I can't vnc or RDP, and there is no video from the GPU DVI output.  So I have to force shutdown the VM.

Link to comment

 

 

I'm struggling with GPU passthrough using the new plugin.  It seems like the old qemu:commandline tags are ignored, and I'm not having any luck with the hostdev tags. 

 

Does anyone have GPU passthrough working for windows (I'm trying for Win7)?  If so, I'd appreciate hints or the relevant pieces of your xml file.

 

Part of my problem is that if I use dmacias' vnc settings, that allows vnc, but seems to break the GPU drivers.  If I don't include the vnc settings, I can't vnc or RDP, and there is no video from the GPU DVI output.  So I have to force shutdown the VM.

 

Sorry I'm not much help.  I'm waiting on jonp to release his openelec vm before I am motivated to use gpu passthrough. The plugin really hasn't changed since webvirtmgr is what is at the core which hasn't changed.  But there may have been more changed in unraid from 9-10. Are you using the virtMan.plg also? Maybe a serial console instead.

Link to comment

dmacias :

 

By the way, I still can't click on the Green "RUNNING", it still tries to open on the UNRAID:PORT.  Like I reported already, on the Mac, that doesn't work as you have to point to :

 

UNRAID.local:PORT

 

OR

 

IPOFUNRAID:PORT

 

Can this be configurable or auto/Detect in the Page ?

I changed it to use the ip address from your unRAID network config.  So Let me know if that works.

Link to comment

I'm struggling with GPU passthrough using the new plugin.  It seems like the old qemu:commandline tags are ignored, and I'm not having any luck with the hostdev tags. 

 

Does anyone have GPU passthrough working for windows (I'm trying for Win7)?  If so, I'd appreciate hints or the relevant pieces of your xml file.

 

Part of my problem is that if I use dmacias' vnc settings, that allows vnc, but seems to break the GPU drivers.  If I don't include the vnc settings, I can't vnc or RDP, and there is no video from the GPU DVI output.  So I have to force shutdown the VM.

You cannot modify an existing "instance" in web virt manager to add GPU pass through or, like you're experiencing, it will drop the QEMU command line arguments.  You have to create a new instance (click from XML) and copy and paste that in there.

Link to comment

I'm struggling with GPU passthrough using the new plugin.  It seems like the old qemu:commandline tags are ignored, and I'm not having any luck with the hostdev tags. 

 

Does anyone have GPU passthrough working for windows (I'm trying for Win7)?  If so, I'd appreciate hints or the relevant pieces of your xml file.

 

Part of my problem is that if I use dmacias' vnc settings, that allows vnc, but seems to break the GPU drivers.  If I don't include the vnc settings, I can't vnc or RDP, and there is no video from the GPU DVI output.  So I have to force shutdown the VM.

You cannot modify an existing "instance" in web virt manager to add GPU pass through or, like you're experiencing, it will drop the QEMU command line arguments.  You have to create a new instance (click from XML) and copy and paste that in there.

 

  Wow never would have thought that. I was experiencing the same issue editing an existing "instance". I thought there was a problem with the lines being entered or the hardware I was trying to pass through. Other lines that I added or edited would be accepted. Thanks for the heads up. In the mean time maybe I will set up a virt manager on an other machine.

 

Reed

Link to comment

I'm struggling with GPU passthrough using the new plugin.  It seems like the old qemu:commandline tags are ignored, and I'm not having any luck with the hostdev tags. 

 

Does anyone have GPU passthrough working for windows (I'm trying for Win7)?  If so, I'd appreciate hints or the relevant pieces of your xml file.

 

Part of my problem is that if I use dmacias' vnc settings, that allows vnc, but seems to break the GPU drivers.  If I don't include the vnc settings, I can't vnc or RDP, and there is no video from the GPU DVI output.  So I have to force shutdown the VM.

You cannot modify an existing "instance" in web virt manager to add GPU pass through or, like you're experiencing, it will drop the QEMU command line arguments.  You have to create a new instance (click from XML) and copy and paste that in there.

 

  Wow never would have thought that. I was experiencing the same issue editing an existing "instance". I thought there was a problem with the lines being entered or the hardware I was trying to pass through. Other lines that I added or edited would be accepted. Thanks for the heads up. In the mean time maybe I will set up a virt manager on an other machine.

 

Reed

I figured this out because I was having the same problem.  What was odd though was if I did a "virsh create domain.XML" from command line, the VM would show up in web manager and the QEMU lines were still there!!  Then I tried to edit the VM XML and start it again and of course all my GPU pass through stopped working.  Not as intuitive as you'd like in a VM management tool, but I'm not complaining.

Link to comment

I figured this out because I was having the same problem.  What was odd though was if I did a "virsh create domain.XML" from command line, the VM would show up in web manager and the QEMU lines were still there!!

Yeah, I seem to have better luck with virsh create, in part because it gives errors in the terminal window. 

 

Little bit of a story here, but maybe it helps someone.  Per your previous response on vfio-bind in the go script, I put the vfio-bind command at the start of my script.  However, it doesn't seem to "take", and I don't see any error in the syslog.  But if I run

ls /dev/vfio

, I don't see my video group (1) listed there.

 

Without the vfio-bind, my qemu commands would give an error in virsh create.  If I manually run the same vfio-bind command from a terminal window, I get the group listed in /dev/vfio, and then virsh create would succeed.  I was able to get GPU passthru.

 

However, this led to the next problem, as the usb I was trying to passthru (a BT keyboard) seems to be failing - it won't run on a non-VM.  So I had no input device to enter my password to log in to windows.  When I unplugged the usb, it locked up the entire unRAID server.  So now it is running a parity check.  Oops.

 

So now I need to get usb passthru working.  But I will start another thread for that.

 

BTW, another advantage of virsh create - your raw xml isn't modified.  Virsh create can add the address to devices and controllers that are specific to your hardware.  If you post the modified xml here on the forum, I *think* it assumes you want to hardcode the address in, even if it isn't valid on someone else's system.  So it seems like the input to virsh create is a "cleaner" xml to share, isn't it?  Not sure there is a good solution, but wanted to mention the concern.

Link to comment

Running beta 10a, created a connection in WebVirtMgr but then I get this error:

"Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory "

Not sure what am I missing.

 

As of 10 you need the virtMan.plg also on the main page.  libvirt is not automatically started

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.