Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] Bridging configuration 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
Scorpion265
Tux's lil' helper
Tux's lil' helper


Joined: 05 May 2005
Posts: 129
Location: Kansas City, MO

PostPosted: Mon Mar 08, 2010 9:55 pm    Post subject: [SOLVED] Bridging configuration issues Reply with quote

Hello all,

I am currently running a xen system. I have xenbr0 that works on the internet, all my domU's can bind to external IPs no problem. I have a few testbed servers that I would like to have talking on a private IP network, however the init scripts are not letting me start up xenbr1. Let me show you my config:

Code:

config_eth0=( "null" )
config_xenbr0=( "208.94.241.194 netmask 255.255.255.248" )
bridge_xenbr0="eth0"
routes_xenbr0=( "default via 208.94.241.193" )
dns_domain_xenbr0="braingoo.net"
dns_servers_xenbr0="208.94.242.3 208.94.243.3"
dns_search_xenbr0="braingoo.net"
config_xenbr1=( "192.168.1.2 netmask 255.255.255.0" )


I get the following error when trying to start xenbr1:
Code:

virtualbrain conf.d # /etc/init.d/net.xenbr1 start
 * Caching service dependencies ...                                       [ ok ]
 * Starting xenbr1
 *   Bringing up xenbr1
 *     192.168.1.2
 *     network interface xenbr1 does not exist
 *     Please verify hardware or kernel module (driver)                   [ !! ]


if I manually create xenbr1 with brctl, and give it an IP via ifconfig, it works great. I would rather do this via the init scripts.


Last edited by Scorpion265 on Mon Mar 15, 2010 7:47 pm; edited 1 time in total
Back to top
View user's profile Send private message
Scorpion265
Tux's lil' helper
Tux's lil' helper


Joined: 05 May 2005
Posts: 129
Location: Kansas City, MO

PostPosted: Wed Mar 10, 2010 9:45 pm    Post subject: Reply with quote

Anyone? Bueller?
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21490

PostPosted: Thu Mar 11, 2010 3:03 am    Post subject: Reply with quote

Without examining the initscripts to confirm this theory, it could be an issue with insufficient configuration for xenbr1. You specify its address, but you do not specify what interfaces it should contain. The initscripts might not create the bridge if there are no interfaces to add to it. Even if they did, it would not be very useful.
Back to top
View user's profile Send private message
Scorpion265
Tux's lil' helper
Tux's lil' helper


Joined: 05 May 2005
Posts: 129
Location: Kansas City, MO

PostPosted: Thu Mar 11, 2010 3:53 am    Post subject: Reply with quote

Thats the thing, it would be very useful. This is a xen server, virtual machines, etc. These machines tap into bridges, I don't want one with a real device, they already have that for internet access. This would be for NFS shares, rsync, database traffic, etc. that would happen between the VMs in the system. I can use the brctl addbr xenbr1 to create the bridge, and assign it a private IP address, and it works as I want. However this is not a permanent solution, especially for unplanned reboots.

Before you ask why I am doing this, it's to save on bandwidth. I do not want network chatter that could happen virtually to cost me money.
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21490

PostPosted: Fri Mar 12, 2010 4:11 am    Post subject: Reply with quote

Scorpion265 wrote:
Thats the thing, it would be very useful. This is a xen server, virtual machines, etc. These machines tap into bridges, I don't want one with a real device, they already have that for internet access. This would be for NFS shares, rsync, database traffic, etc. that would happen between the VMs in the system. I can use the brctl addbr xenbr1 to create the bridge, and assign it a private IP address, and it works as I want. However this is not a permanent solution, especially for unplanned reboots.
Assuming my guess was correct, why not just create the tap devices and add them to the bridge via the normal Gentoo networking scripts, instead of using external guest-triggered scripts to activate them? Trying to use a hybrid of a Gentoo-managed bridge with externally-managed ports is messy even if it works.
Scorpion265 wrote:
Before you ask why I am doing this, it's to save on bandwidth. I do not want network chatter that could happen virtually to cost me money.
What kind of network are you on that a bit of leaked chatter will make a meaningful difference to your bill?
Back to top
View user's profile Send private message
Scorpion265
Tux's lil' helper
Tux's lil' helper


Joined: 05 May 2005
Posts: 129
Location: Kansas City, MO

PostPosted: Fri Mar 12, 2010 7:05 am    Post subject: Reply with quote

A tap device could work, is there any way to make them permanent? I am pretty sure they disappear when the server is cycled.

It's not a bit of leaked chatter, it's a lot. This is a personal project that involves multiple nodes and (sometimes) gigs of data get transferred back and forth. I am using virtual machines to cut down on costs for development and prototyping.If all goes well I will spend the money for real machines. I would have dual NICs and have a publicly accessible NIC and a private for between server communication.
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21490

PostPosted: Sat Mar 13, 2010 3:33 am    Post subject: Reply with quote

Tap devices do vanish when the system is rebooted. My thinking was that, if you have a relatively finite number of tap devices needed, then you could configure them in /etc/conf.d/net just like your real interfaces. Then, have your ifup scripts run /etc/init.d/net.tapX start instead of creating them directly via tunctl. This would cause the Gentoo networking scripts to bring up and configure the devices, and would allow you to name the devices as being part of the bridge. You might also need to have the ifup script include a statement like /etc/init.d/net.xenbr1 --quiet status || /etc/init.d/net.xenbr1 start so that the bridge would be started if it was not up. It should be safe to leave the tap devices up when they are unused, so the ifdown script might be a no-op.
Back to top
View user's profile Send private message
Scorpion265
Tux's lil' helper
Tux's lil' helper


Joined: 05 May 2005
Posts: 129
Location: Kansas City, MO

PostPosted: Mon Mar 15, 2010 7:21 pm    Post subject: Reply with quote

That was it! I didn't have a net.tap0. I set it to config_tap0 = ( "null" ) and used it as the bridge device. That worked perfectly! I've setup an internal DNS server for routing traffic properly on the internal network. On a side note, the speed of transfers have gone up significantly with this configuration. Thank you very much for your help!
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