Multiple users accessing KVM

1110 pts.
Tags:
Kernels
KVM
Virtual machine manager
Virtual Machine Security
Virtual Machines
How can I have multiple users access our kernel-based virtual machine at the same time? Can we use some sort of screen sharing to get around the 1 user at a time limit?

Answer Wiki

Thanks. We'll let you know when a new response is added.

This can easily be done by letting users ssh into a screen session. First, install the screen package:
On RedHat
# yum install screen

On Debian/Ubuntu:
$ sudo apt-get install screen

If you want them to all have the same screen session, then include this in the .bashrc file:


if [ ps auxw|grep [s]creen > /dev/null ]; then
screen
else
screen -x
fi

If screen is not running.. it will spawn a new screen session. If it already IS running, it will have the new user JOIN the screen session.

Now if you want them to each get their OWN screen session, then you will need to write a custom script to spawn screen with X number of sessions.. and then auto join new people to n+1 screen (where n is the number of users currently logged in).

It’s not a perfect solution, but you’re asking for a work around here.

Tweeks

Discuss This Question: 7  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • petkoa
    Is there really such "one user at a time" limit for any virtual machine, including KVM? May be you are considering a limit of the OS running in virtual machine?
    3,120 pointsBadges:
    report
  • Tweeks
    Petoka.. It sounds like he's on a restricted host config. Tweeks
    35 pointsBadges:
    report
  • petkoa
    @Tweeks: Just my point - "screen" utility is working on OS level, not VM. @NewnanIT: some more information about your OS - some flavor of Linux, or Windows (as I figure, more probably) will be of utter help for solving the problem...
    3,120 pointsBadges:
    report
  • NewnanIT
    [...] 4. Several community members jumped in with suggestions for a question regarding multiple users accessing KVM. [...]
    0 pointsBadges:
    report
  • NewnanIT
    Kernel-based Virtual Machine (KVM) is a full virtualization solution for Linux on x86 hardware containing virtualization extensions (Intel VT or AMD-V). It comes with a loadable kernel module, kvm.ko, which provides the core virtualization infrastructure and a processor-specific module, kvm-intel.ko or kvm-amd.ko. Using KVM, one can run multiple virtual machines running unmodified Linux or Windows images. Each virtual machine can have its own private virtualized hardware: a network card, disk, graphics adapter, to know more about this question u can visit http://www.techyv.com/questions/multiple-users-access-our-kernel-based-virtual-machine#comment-33264
    0 pointsBadges:
    report
  • petkoa
    @Carlosdl: Carlos, it seems somebody again copy/pasting in the forum like our dear friend Rachil?
    3,120 pointsBadges:
    report
  • carlosdl
    :-) :-) :-) I agree Petko, this looks exactly as those posts from Rechil, but he has resurrected with his own name (I saw a couple of answers by him recently), so, maybe he has a ... friend ? (please, no)
    69,065 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following