Description of problem: When adding a new network by virt-manager, there will be a warning when an unsuitable network specified, but it will failed to give out warning sometimes. This maybe not a bug, but an advice of feature improvement, I'm not very sure. Version-Release number of selected component (if applicable): virt-manager-0.6.1-6.el5 How reproducible: 100% Steps to Reproduce: 1. Launch virt-manager 2. Open "Host Details" window by "Edit --> Host Details", go to page of "Virtual Networks" 3. Add a new network follow the wizard, specify the same Network of the host machine on page of "Choosing an IPv4 address space". For example, the host network is "10.66.70.0/24", then specify "10.66.70.0/24" here. Actual results: There is none warning at step 3, but in fact, the guest should not have a same network with the host when using NAT. Expected results: It will be better if the background of the input field change color to remind end users. Additional info:
Not entirely sure how easy this will be. Need to investigate.
This check should probably be done in the libvirt layer, I'd say it should refuse to start any virtual network which has an IP range that clashes with any current host interface. Obviously this won't help if the host interface gets a clashing IP addr after the virtual network starts, but that's not so immediately critical as breaking existing host networking.
This request was evaluated by Red Hat Product Management for inclusion in the current release of Red Hat Enterprise Linux. Because the affected component is not scheduled to be updated in the current release, Red Hat is unfortunately unable to address this request at this time. Red Hat invites you to ask your support representative to propose this request, if appropriate and relevant, in the next release of Red Hat Enterprise Linux.
Reassigning to libvirt per comment #2
This request was evaluated by Red Hat Product Management for inclusion in the current release of Red Hat Enterprise Linux. Because the affected component is not scheduled to be updated in the current release, Red Hat is unable to address this request at this time. Red Hat invites you to ask your support representative to propose this request, if appropriate, in the next release of Red Hat Enterprise Linux.
The patch is pushed upstream for quite a while now: commit a83fe2c23efad190a1e00e448f607fe032650fd6 Author: Cole Robinson <crobinso> AuthorDate: Thu May 20 19:31:16 2010 -0400 Commit: Cole Robinson <crobinso> CommitDate: Thu May 27 18:02:53 2010 -0400 network: bridge: Don't start network if it collides with host routing Fedora bug https://bugzilla.redhat.com/show_bug.cgi?id=235961 If using the default virtual network, an easy way to lose guest network connectivity is to install libvirt inside the VM. The autostarted default network inside the guest collides with host virtual network routing. This is a long standing issue that has caused users quite a bit of pain and confusion. On network startup, parse /proc/net/route and compare the requested IP+netmask against host routing destinations: if any matches are found, refuse to start the network. v2: Drop sscanf, fix a comment typo, comment that function could use libnl instead of /proc v3: Consider route netmask. Compare binary data rather than convert to string. v4: Return to using sscanf, drop inet functions in favor of virSocket, parsing safety checks. Don't make parse failures fatal, in case expected format changes. v5: Try and continue if we receive unexpected. Delimit parsed lines to prevent scanning past newline v0.8.1-199-ga83fe2c It's part of 0.8.2 release which is part of RHEL-5.10. Hence I'm closing this one as CURRENTRELEASE.