LinuxQuestions.org
Review your favorite Linux distribution.
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 12-21-2019, 01:06 PM   #1
tux111
Member
 
Registered: Oct 2012
Location: Germany
Distribution: Xubuntu
Posts: 81

Rep: Reputation: Disabled
isolate libvirt / kvm guests in virtual network


All,

is it possible to isolate libvirt / kvm guests in a virtual network? (I think VirtualBox has such an option).

- Chris
 
Old 12-21-2019, 04:34 PM   #2
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
You mean an isolated network?
 
Old 12-22-2019, 05:49 AM   #3
tux111
Member
 
Registered: Oct 2012
Location: Germany
Distribution: Xubuntu
Posts: 81

Original Poster
Rep: Reputation: Disabled
Only the virtual machines should connect to each other, but not even to the KVM host.
 
Old 12-22-2019, 07:31 AM   #4
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
From the above link:
Code:
<network>
  <name>private</name>
  <bridge name="virbr2"/>
  <ip address="192.168.152.1" netmask="255.255.255.0">
    <dhcp>
      <range start="192.168.152.2" end="192.168.152.254"/>
    </dhcp>
  </ip>
  <ip family="ipv6" address="2001:db8:ca2:3::1" prefix="64"/>
</network>
The only way the guests can talk to the hosts is by accessing virbr2, i.e. 192.168.152.1. If no host process listens at virbr2, there is nothing the guests can connect to. If you are still bothered by the connectivity to virbr2, use iptables to shield it totally. If you don't even want DHCP, remove the dhcp clause. I don't know if you can remove the bridge's IP address, but it would be worth a try.

Last edited by berndbausch; 12-22-2019 at 07:34 AM.
 
2 members found this post helpful.
  


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
LXer: Track KVM guests with libvirt and the Linux audit subsystem LXer Syndicated Linux News 0 03-28-2019 04:41 AM
LXer: Track KVM guests with libvirt and the Linux audit subsystem LXer Syndicated Linux News 0 06-18-2012 07:00 AM
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
KVM on Redhat 5.7: KVM can ping outside network, outside network can't ping KVM svandyk Linux - Networking 1 09-23-2011 06:45 AM
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 03:04 AM.

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