Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Virt-Manager Interface Issues
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
icehac
n00b
n00b


Joined: 19 Jun 2014
Posts: 5

PostPosted: Mon Nov 03, 2014 12:09 am    Post subject: Virt-Manager Interface Issues Reply with quote

Hello All,

I am trying to start the interface within virt-manager. Unfortunately, I am prompted with this error when trying to run the Virtual Network:
"Error starting network 'default': Unable to create bridge virbr0: File exists."

I am also prompted with this error when I try to run the Virtual Interface virbr0 (which was automatically created):
"Error starting interface 'virbr0': this function is not supported by the connection driver: virInterfaceCreate"

I am trying to assign an interface to the VM's to have them NAT to my physical interface (wireless...wlp2s0). I am not using NetworkManager, and am using wpa_supplicant/dhcpcd instead.
Any ideas? I'm coming from a redhat background, but am definitely a Gentoo newbie. Any ideas about how to go about fixing this issue?

Thanks!
Back to top
View user's profile Send private message
icehac
n00b
n00b


Joined: 19 Jun 2014
Posts: 5

PostPosted: Tue Nov 04, 2014 6:32 pm    Post subject: Reply with quote

I was finally able to solve the issue....even though the errors hinted at permission issues (creating the interface), the real culprit was the IPv4 NAT module in the kernel config. For future reference, if anyone else has this issue, this is how I solved it using "genkernel --menuconfig all"

Code:
--> Networking Support
   --> Networking Options
      --> Network packet filtering framework (Netfilter)
         --> IP: Netfilter Configuration

<M> IPv4 NAT


Hope this helps!
Back to top
View user's profile Send private message
icehac
n00b
n00b


Joined: 19 Jun 2014
Posts: 5

PostPosted: Tue Nov 04, 2014 8:58 pm    Post subject: Reply with quote

Also, those who are attempting to use NATing on their interfaces, here are the iptables rules that I had to establish:

Code:

# iptables -t nat -A POSTROUTING -o "interface name goes here" -j MASQUERADE
# iptables -I FORWARD 1 -i virbr0
# iptables -I FORWARD 1 -i virbr0 -j ACCEPT
# iptables -I FORWARD 1 -o virbr0 -m state --state RELATED,ESTABLISHED -j ACCEPT


As well as the script I used to create the default bridged interfaces (wasn't included with the emerge packages for some reason)[/quote]

virsh net-define /usr/share/libvirt/networks/default.xml

default.xml :
Code:

<network>
   <name>default</name>
   <bridge name="virbr0"/>
   <forward/>
   <ip address="192.168.122.1" netmask="255.255.255.0">
      <dhcp>
         <range start="192.168.122.2" end="192.168.122.254"/>
      </dhcp>
   </ip>
</network>
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum