LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Virtualization and Cloud
User Name
Password
Linux - Virtualization and Cloud This forum is for the discussion of all topics relating to Linux Virtualization and Linux Cloud platforms. Xen, KVM, OpenVZ, VirtualBox, VMware, Linux-VServer and all other Linux Virtualization platforms are welcome. OpenStack, CloudStack, ownCloud, Cloud Foundry, Eucalyptus, Nimbus, OpenNebula and all other Linux Cloud platforms are welcome. Note that questions relating solely to non-Linux OS's should be asked in the General forum.

Notices


Reply
  Search this Thread
Old 10-11-2013, 01:17 PM   #1
tux111
Member
 
Registered: Oct 2012
Location: Germany
Distribution: Xubuntu
Posts: 81

Rep: Reputation: Disabled
libvirt / kvm without root-permissions


Dear all,

I've asked this question already in another forum, but got no reply, unfortunately. So I'm asking here again.

Is it possible to create virtual machines without root permissions?

When trying to start a machine defined as not-privileged user, the error message is: Network not found: no network with matching name 'default'. default is only listed when logged in as root.

When trying to define a network as user: cannot write config file '/var/lib/libvirt/dnsmasq/chris.hostsfile' Permission denied.

The distribution is CentOS 6.3.

Thank you in advance!

Chris

PS: It is possible, with virt-manager GUI, but it isn't work from the shell until now...

Last edited by tux111; 10-11-2013 at 01:28 PM.
 
Old 10-12-2013, 11:11 AM   #2
gradinaruvasile
Member
 
Registered: Apr 2010
Location: Cluj, Romania
Distribution: Debian Testing
Posts: 731

Rep: Reputation: 158Reputation: 158
You can configure libvirt to run under its own user, not root (if its not the default setup). But you still need root access to do the setup initially. Another thing is that you have to make sure your user in the same group as the libvirt user and that group to have full access to the log files, etc.
 
Old 10-12-2013, 01:16 PM   #3
tux111
Member
 
Registered: Oct 2012
Location: Germany
Distribution: Xubuntu
Posts: 81

Original Poster
Rep: Reputation: Disabled
So the default setup is running as root? It seems possible to configure VMs with virt-manager as user, so I was surprised by the shell errors. In VirtualBox I can use all shell commands as user. Since it's only a little local setup I'll use root for the time being...
 
Old 10-12-2013, 10:12 PM   #4
gradinaruvasile
Member
 
Registered: Apr 2010
Location: Cluj, Romania
Distribution: Debian Testing
Posts: 731

Rep: Reputation: 158Reputation: 158
The setup i was referring to is to change the config options in libvirt. After that it should work from user level.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LibVirt/KVM: HyperThreading On or Off? r0b0 Linux - Virtualization and Cloud 3 02-17-2013 11:49 PM
kvm/libvirt bridge etheraap Linux - Server 0 02-04-2013 08:44 PM
libvirt install with kvm (from source) guardian1 Linux - Virtualization and Cloud 2 12-07-2012 05:07 PM
LXer: Scripting KVM with Python, Part 2: Add a GUI to manage KVM with libvirt and Python LXer Syndicated Linux News 0 01-17-2012 08:11 PM
LXer: Set up Ubuntu 11.04 KVM to run is spice session on Fedora 14 KVM Server ( Libvirt Preview Env) LXer Syndicated Linux News 0 03-20-2011 12:00 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Virtualization and Cloud

All times are GMT -5. The time now is 06:24 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration