1

I have a server running Ubuntu 14.04LTS. On it I created a (KVM) VM with Ubuntu 16.04 Desktop.

I setup Spice on this VM so that I can access it remotely. Everything is working fine, got TLS, USB redirection, everything working nicely.

However, this machine is intended to be used by two people, I was hoping that I could have User1 access it, be greeted with the login screen, login and use the machine at will. Then at the same time, User2 would be able to launch the spice client (using remote-viewer), also be greeted with a login screen, and use the machine at the same time as User2.

However, what I get is, when User2 connects, User1 is disconnected immediatelly and takes over the Desktop of User1.

I searched and found some brief mentions to multi-monitor support, read about enabling ticketing (setting a password for Spice), etc and thought it would lead me to the solution I want but nope.

I tried adding a second Spice Display to the VM but when launching the VM using virt-manager it says only one Spice Display can exist at a time.

Do not know what else to try, does anyone know how to accomplish this?

PS: I know I could create two VMs, one for each user, but please that is not what I want.

mbello
  • 172
  • 1
  • 7

3 Answers3

3

spice provides direct access to the console, opening spice is pretty much the same thing as sitting in front of the virtual machine. You can't sit two people in front of the same desktop (well you can, but that's not very conventional and requires special hardware. and furniture.) So when the second user connects, he pretty much kicks the chair from under the first one, and takes his place.

To accomplish what you want, you need to set up a terminal server on this VM and connect using the appropriate protocol. There's a hack available that allows you to run spice as a server inside a machine, instead of providing a console from the host side, but last time I tried it, it was pretty much broken.

dyasny
  • 18,482
  • 6
  • 48
  • 63
3

For the original poster, have you tried X2Go? I know that's another server piece you have to install in your 16.04 system, but using that on my machines, with the X2go client allowed multiple users to login with different X sessions at the same time.

I find that depending on your hardware capabilities, the Mate and XFCE desktops perform really well. Haven't tried Gnome 3, KDE, Cinnamon, or Unity yet, but intend to over the next few weeks.

I have done this to a Digital Ocean droplet on which I installed Mate desktop and X2Go sever, and have also done it on a home PC with Mate installed, but have not done it on a KVM virtual machine yet.

bmcgonag
  • 31
  • 2
2

It's not a flashy, but you could always run a shared session over VNC - that does allow multiple connections to share the same session and display. x11vnc is a common example which works well in this situation.

Keep in mind that VNC doesn't handle encryption so running through a encrypted SSH/VPN tunnel is highly recommended.

Brennen Smith
  • 1,638
  • 7
  • 11