<br><br><div class="gmail_quote">On Sat, Jan 14, 2012 at 8:41 AM, Radek Bursztynowski <span dir="ltr">&lt;<a href="mailto:radek@bursztynowski.waw.pl">radek@bursztynowski.waw.pl</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<u></u>


  
  

<div>
Dnia 2012-01-14, sob o godzinie 15:08 +0100, Dennis Jacobfeuerborn pisze:
<div><div class="h5"><blockquote type="CITE">
<pre>On 01/14/2012 02:59 PM, Radek Bursztynowski wrote:
&gt; Hi,
&gt;
&gt; I have installed CentOS 6.2 x86_64 and KVM/Qemu and I have some troubles
&gt; with network.
&gt;
&gt; The first case:
&gt; -----------------
&gt;
&gt; The configuration is:
&gt; - CentOS 6.2 (hardware machine) has one Ethernet interface with static IP
&gt; address (eth0).
&gt; - Virtual machine has bridge network interface with eth0 interface on
&gt; CentOS 6.2. This bridge is created using wizard integrated with virt-manager.
&gt; - Bridge interface on virtual machine receives IP addres from DHCP server.
&gt; IP address is received well.
&gt; - All firewalls and SELinux are closed.
&gt;
&gt; Virtual machine has no any connection with CentOS 6.2 hardware machine, and
&gt; CentOS 6.2 has no any connection with virtual machine. But every others
&gt; machines have all connection with both virtual and CentOS 6.2 machine.
&gt;
&gt; The question: Why?
&gt;
&gt; The second case:
&gt; ----------------------
&gt;
&gt; The configuration is:
&gt; - On CentOS 6.2 (hardware machine) I created bridhe (br0) with eth0
&gt; hardware interface. Two situations:
&gt; + I force two different IP addresses for eth0 and br0 interfaces - there no
&gt; any connection with this server. So I don&#39;t test this case.
&gt; + I forced one IP addres for both eth0 and br0 interfaces. ifconfig shows
&gt; that eth0 has no IP address, br0 has IP address. So, I test this case.
&gt; - I use Red Hat documentation:
&gt; <a href="http://docs.redhat.com/docs/en-US/Red_Hat_Enterprise_Linux/5/html-single/Virtualization/index.html#sect-Virtualization-Network_Configuration-Bridged_networking_with_libvirt" target="_blank">http://docs.redhat.com/docs/en-US/Red_Hat_Enterprise_Linux/5/html-single/Virtualization/index.html#sect-Virtualization-Network_Configuration-Bridged_networking_with_libvirt</a>)
&gt; - On virtual machine I created bridge connection with br0 interface on
&gt; CentOS 6.2.
&gt; - All machines have all connections.
&gt; - All firewalls and SELinux are closed.
&gt;
&gt; NFS server on CentOS 6.2 (hardware machine) doesn&#39;t serve exported file system.
&gt;
&gt; The questions:
&gt; 1. Is it proper that eth0 has no IP addres and bridge (br0) interface has?
&gt; 2. What about my NFS? NFS server worked well before starting virtualization.
&gt;
&gt; Who can me help with my troubles?

You say you create bridge interfaces in your virtual machines. Why? Usually 
you don&#39;t do that you create a bridge only on the host.

You also say you &quot;forced&quot; one IP address for both eth0 and br0. There is no 
need to force anything. eth0 shouldn&#39;t have an IP but br0 should have this 
IP instead.

Regards,
   Dennis
_______________________________________________
</pre>
</blockquote></div></div>
Dennis,<br>
<br>
Thanks for interesting. Few words explanation. <br>
I have one network segment, and I try to joint virtual machines to this segment. So my hardvare machine has 192.168.0.1 address, gateway is 192.168.0.254, netmask = 255.255.255.0.<br>
<br>
Regarding bridge on my virtual machine. When I started virtualization I had NAT only in another network segment. So, I look for solution adding virtual machines to my base network segment. Previously I used VMware Server, and it was proper solution.<br>

<br>
Regarding my force one IP addres for both interface. I used this solution because eth0 has no any IP addres and I couldn&#39;t find CentOS 6.2 server in the network. Using exactly Red Hat configuration I have:<br>
<br>
# more ifcfg-eth0<br>
DEVICE=eth0<br>
TYPE=Ethernet<br>
BOOTPROTO=none<br>
IPADDR=192.168.0.1<br>
NETMASK=255.255.255.0<br>
PREFIX=24<br>
GATEWAY=192.168.0.254<br>
DNS1=192.168.0.199<br>
DNS2=194.204.159.1<br>
DNS3=194.204.152.34<br>
DEFROUTE=yes<br>
IPV4_FAILURE_FATAL=yes<br>
IPV6INIT=no<br>
NAME=eth0<br>
ONBOOT=yes<br>
BRIDGE=br0<br>
MTU=9000<br>
DOMAIN=<a href="http://bursztynowski.waw.pl" target="_blank">bursztynowski.waw.pl</a><br>
UUID=5fb06bd0-0bb0-7ffb-45f1-d6edd65f3e03<br>
<br>
# more ifcfg-br0<br>
DEVICE=br0<br>
TYPE=Bridge<br>
BOOTPROTO=dhcp<br>
#IPADDR=192.168.0.1<br>
#NETMASK=255.255.255.0<br>
#PREFIX=24<br>
#GATEWAY=192.168.0.254<br>
#DNS1=192.168.0.199<br>
#DNS2=194.204.159.1<br>
#DNS3=194.204.152.34<br>
ONBOOT=yes<br>
DELAY=0<br>
<br>
(previous configuration br0 was: <br>
BOOTPRO=static<br>
and with no &#39;#&#39; characters. Then all worked excluding NFS.<br>
<br>
<br>
# ifconfig                            <br>
br0       Link encap:Ethernet  HWaddr 00:50:8D:94:2F:B7            <br>
          inet addr:192.168.0.92  Bcast:192.168.0.255  Mask:255.255.255.0<br>
          inet6 addr: fe80::250:8dff:fe94:2fb7/64 Scope:Link             <br>
          UP BROADCAST RUNNING MULTICAST  MTU:9000  Metric:1             <br>
          RX packets:16 errors:0 dropped:0 overruns:0 frame:0            <br>
          TX packets:26 errors:0 dropped:0 overruns:0 carrier:0          <br>
          collisions:0 txqueuelen:0                                      <br>
          RX bytes:3034 (2.9 KiB)  TX bytes:4313 (4.2 KiB)               <br>
<br>
eth0      Link encap:Ethernet  HWaddr 00:50:8D:94:2F:B7  <br>
          inet6 addr: fe80::250:8dff:fe94:2fb7/64 Scope:Link<br>
          UP BROADCAST RUNNING PROMISC MULTICAST  MTU:9000  Metric:1<br>
          RX packets:57255 errors:0 dropped:0 overruns:0 frame:0<br>
          TX packets:60263 errors:0 dropped:0 overruns:0 carrier:0<br>
          collisions:0 txqueuelen:1000<br>
          RX bytes:21481457 (20.4 MiB)  TX bytes:15768417 (15.0 MiB)<br>
          Interrupt:23 Base address:0x8000<br>
<br>
lo        Link encap:Local Loopback<br>
          inet addr:127.0.0.1  Mask:255.0.0.0<br>
          inet6 addr: ::1/128 Scope:Host<br>
          UP LOOPBACK RUNNING  MTU:16436  Metric:1<br>
          RX packets:30723 errors:0 dropped:0 overruns:0 frame:0<br>
          TX packets:30723 errors:0 dropped:0 overruns:0 carrier:0<br>
          collisions:0 txqueuelen:0<br>
          RX bytes:92725098 (88.4 MiB)  TX bytes:92725098 (88.4 MiB)<br>
<br>
Should I replace static and dhcp addresses between eth0 and br0 interface?<br>
<br>
Regards,<br>
Radek<br>
<br>
<br>
<br>
<br>
<br>
<br>
</div>

<br>_______________________________________________<br>
CentOS-virt mailing list<br>
<a href="mailto:CentOS-virt@centos.org">CentOS-virt@centos.org</a><br>
<a href="http://lists.centos.org/mailman/listinfo/centos-virt" target="_blank">http://lists.centos.org/mailman/listinfo/centos-virt</a><br>
<br></blockquote></div><br><div>To use bridging on the virtual host you have to assign the IPs to br0 and then add &quot;Bridge=br0&quot; to ifcfg-eth0.  I have working examples here, <a href="http://itscblog.tamu.edu/startup-guide-for-kvm-on-centos-6/">http://itscblog.tamu.edu/startup-guide-for-kvm-on-centos-6/</a>.</div>