[opensuse] Multiple Network Card Problem on openSUSE 10.3
Hi, I have 2 network card, the first one is onboard network card and another is attached wifi card. I can connect to the network with each of them alone, but I cannot connect the two network card in a same time both with knetworkmanager (YAST tell me that I MUST used ifconfig for multiple card) or manual ifconfig. I've tried with same IP set (192.168.0.x) or different IP (192.168.0.x and 192.168.1.x) or trying with DHCP client with no luck. Is this possible to get the two network card (onboard and wifi) connected in a same time ? in previous, I've successfully connected with 2 network card (both of them are wired) on openSUSE 10.2 -- Best Regards, Masim "Vavai" Sugianto /************************************************************/ Blog (ID) : http://www.vavai.com/blog/index.php Blog (EN) : http://www.vavai.net Community : http://www.opensuse.or.id /************************************************************/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Mon, 16 Jun 2008 08:53:57 Masim "Vavai" Sugianto wrote:
Hi,
I have 2 network card, the first one is onboard network card and another is attached wifi card. I can connect to the network with each of them alone, but I cannot connect the two network card in a same time both with knetworkmanager (YAST tell me that I MUST used ifconfig for multiple card) or manual ifconfig.
I've tried with same IP set (192.168.0.x) or different IP (192.168.0.x and 192.168.1.x) or trying with DHCP client with no luck.
Is this possible to get the two network card (onboard and wifi) connected in a same time ? in previous, I've successfully connected with 2 network card (both of them are wired) on openSUSE 10.2
Yes, you can use both wireless and wired ethernet but not both to the same network - they must be in different subnets or you will generate routing loops (unless your router supports spanning tree protocol and you then need to run routed on the client to handle the multiple/redundant routes). You will need to configure each ethernet device via Yast or manually via ifconfig. You will need to use ifup to enable each network device (should be set up automatically by Yast if you tell it to start each interface at boot time or when the cable is plugged in). If you want to bridge the two networks together then you'll need to install and configure routed; you may also want/need iptables as well. It can be done - I have 2 laptops configured this way (without packet forwarding) and also have 2 network cards in my desktop machine (all running 10.3) so I know it works. Regards, Rodney. -- =================================================== Rodney Baker VK5ZTV rodney.baker@iinet.net.au =================================================== Learned men are the cisterns of knowledge, not the fountainheads.
On Monday 16 June 2008 12:28:35 Rodney Baker wrote:
Yes, you can use both wireless and wired ethernet but not both to the same network - they must be in different subnets or you will generate routing loops (unless your router supports spanning tree protocol and you then need to run routed on the client to handle the multiple/redundant routes).
You will need to configure each ethernet device via Yast or manually via ifconfig. You will need to use ifup to enable each network device (should be set up automatically by Yast if you tell it to start each interface at boot time or when the cable is plugged in).
If you want to bridge the two networks together then you'll need to install and configure routed; you may also want/need iptables as well.
It can be done - I have 2 laptops configured this way (without packet forwarding) and also have 2 network cards in my desktop machine (all running 10.3) so I know it works.
Regards, Rodney.
please, can you explain how you set up the options for each card? I need to set 2 different names, one for each ethernet card that I want to configure via dhcp/ddns, but I can't find a way to make this mechanism work. So far I always thought that the networking setup in openSuse is as broken and undecipherable as in debian (as opposed to the clear one in Fedora), but if you say that I can make it work how I need it I'll be really happy. Thanks, Nico -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Mon, 16 Jun 2008 20:20:13 Nico Sabbi wrote:
On Monday 16 June 2008 12:28:35 Rodney Baker wrote:
Yes, you can use both wireless and wired ethernet but not both to the same network - they must be in different subnets or you will generate routing loops (unless your router supports spanning tree protocol and you then need to run routed on the client to handle the multiple/redundant routes). [...] It can be done - I have 2 laptops configured this way (without packet forwarding) and also have 2 network cards in my desktop machine (all running 10.3) so I know it works.
Regards, Rodney.
please, can you explain how you set up the options for each card? I need to set 2 different names, one for each ethernet card that I want to configure via dhcp/ddns, but I can't find a way to make this mechanism work. So far I always thought that the networking setup in openSuse is as broken and undecipherable as in debian (as opposed to the clear one in Fedora), but if you say that I can make it work how I need it I'll be really happy. Thanks, Nico
Nico, How exactly do you want it to work? If you want to use DHCP for both network cards then each card must have access to a DHCP server for the network that they will talk to. If you can it is usually easier (for a small network) to use static IP's for multiple interfaces though. In my case I have my primary interface via DHCP and the secondary interface with a static IP address. You can only have *one* default gateway (i.e. the address that all non-local traffic for which their is no route configured will be sent through). With 2 network cards some form of dynamic routing table management makes things much easier; this is what the route daemon (routed) is for. Make sure that it is installed and running (set it to autostart via the runlevel editor) unless you have a good reason not to use it. Provided you have routers on the network that publish routing information via RIP it will then learn which interface to use for what networks. In the YaST Network Devices/Network Card utility, on the Global Options page make sure you select Traditional Method with ifup as the Network Setup Method. I found it to be much more reliable on all my machines than letting it use NetworkManager. If you don't have any IPv6 devices on your network you may as well uncheck the Enable IPv6 checkbox on this tab too (although I haven't bothered to). The DHCP Client Options I've left at the default settings. On the Overview tab select each interface in turn, click the Configure button and ensure that it is set for DHCP or static IP as appropriate. On the General tab of the configuration screen select At Boot Time or On Cable Connection if you want the interface to start automatically. For a wireless connection On Hotplug may be more appropriate but I haven't tested that - YMMV. My laptops are set to enable wireless at boot time and wired ethernet on cable connection. My desktop enables both wired connections at boot time. After saving the interface-specific settings, on the HostName/DNS tab you can configure whether or not to update the hostname and dns settings via DHCP or set them statically. Mine are static. The Routing tab is where you set the default gateway, set up any static routes and turn on IP forwarding (via the Enable IP Forwarding check box). Only enable IP forwarding if you're planning to use the machine as a router or bridge between 2 otherwise unconnected networks. Incidentally, I don't have a default gateway set on my desktop machine because routed takes care of that for me. Hope this helps. -- =================================================== Rodney Baker VK5ZTV rodney.baker@iinet.net.au =================================================== If entropy is increasing, where is it coming from?
On Monday 16 June 2008 15:59:09 Rodney Baker wrote:
On Mon, 16 Jun 2008 20:20:13 Nico Sabbi wrote:
please, can you explain how you set up the options for each card? I need to set 2 different names, one for each ethernet card that I want to configure via dhcp/ddns, but I can't find a way to make this mechanism work. So far I always thought that the networking setup in openSuse is as broken and undecipherable as in debian (as opposed to the clear one in Fedora), but if you say that I can make it work how I need it I'll be really happy. Thanks, Nico
Nico, How exactly do you want it to work? If you want to use DHCP for both network cards then each card must have access to a DHCP server for the network that they will talk to.
it's exactly what I need. Actually they are both in the same network for long and boring reasons that I'd better avoid explaining (thus there's only 1 default gateway) , but the issue remains: multi-homing
If you can it is usually easier (for a small network) to use static IP's for multiple interfaces though. In my case I have my primary interface via DHCP and the secondary interface with a static IP address.
yes, it's easier, but I'd like to solve this problem using DHCP alone
You can only have *one* default gateway (i.e. the address that all non-local traffic for which their is no route configured will be sent through).
it is only one for the reason I wrote (same network)
With 2 network cards some form of dynamic routing table management makes things much easier; this is what the route daemon (routed) is for. Make sure that it is installed and running (set it to autostart via the runlevel editor) unless you have a good reason not to use it. Provided you have routers on the network that publish routing information via RIP it will then learn which interface to use for what networks.
unneeded in this case, same reason
In the YaST Network Devices/Network Card utility, on the Global Options page make sure you select Traditional Method with ifup as the Network Setup Method. I found it to be much more reliable on all my machines than letting it use NetworkManager.
If you don't have any IPv6 devices on your network you may as well uncheck the Enable IPv6 checkbox on this tab too (although I haven't bothered to). The DHCP Client Options I've left at the default settings.
On the Overview tab select each interface in turn, click the Configure button and ensure that it is set for DHCP or static IP as appropriate. On the General tab of the configuration screen select At Boot Time or On Cable Connection if you want the interface to start automatically. For a wireless connection On Hotplug may be more appropriate but I haven't tested that - YMMV. My laptops are set to enable wireless at boot time and wired ethernet on cable connection. My desktop enables both wired connections at boot time.
After saving the interface-specific settings, on the HostName/DNS tab you can configure whether or not to update the hostname and dns settings via DHCP or set them statically. Mine are static.
but in yast there's only one name entry, not one for interface.
The Routing tab is where you set the default gateway, set up any static routes and turn on IP forwarding (via the Enable IP Forwarding check box). Only enable IP forwarding if you're planning to use the machine as a router or bridge between 2 otherwise unconnected networks.
Incidentally, I don't have a default gateway set on my desktop machine because routed takes care of that for me.
Hope this helps.
thanks for your detailed explanation, but unfortunately the main issue remains: I can't find a way to assign a name specific for the network interface rather than global :( Is a multi-homed configuration impossible in Suse? Well, maybe not: settting DHCLIENT_HOSTNAME_OPTION=myname2 in /etc/sysconfig/network-scripts/ifcfg-eth0 and disabling DHCLIENT_HOSTNAME_OPTION and DHCLIENT_CLIENT_ID in /etc/sysconfig/network-scripts/dhcp seems to work as expected, at least with a single network interface, but then why isn't it possible to specify a configuration like that in yast? Where's a specification of the valid settings for the ifcfg-ethN files? Thanks, Nico -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Wed, 18 Jun 2008 23:14:53 Nico Sabbi wrote:
On Monday 16 June 2008 15:59:09 Rodney Baker wrote:
[...] Nico, How exactly do you want it to work? If you want to use DHCP for both network cards then each card must have access to a DHCP server for the network that they will talk to.
it's exactly what I need. Actually they are both in the same network for long and boring reasons that I'd better avoid explaining (thus there's only 1 default gateway) , but the issue remains: multi-homing
Multi-homing is not (as I understand it) having both network cards on the same network; a multi-homed host is one that exists simultaneously on more than one network (e.g. a server with 2 or more network interfaces, each talking to a different subnet or network and not bridging the networks together (that is the job of a router).
[...] thanks for your detailed explanation, but unfortunately the main issue remains: I can't find a way to assign a name specific for the network interface rather than global :( Is a multi-homed configuration impossible in Suse?
As mentioned (or at least implied) above, multi-homed does not mean having multiple host names for a single machine. In fact, the host name configured in the local machine is not that relevant in the overall networking scheme of things. If you need to connect to the different IP addresses using different host names, that is where /etc/hosts and/or dns come into play. If you run a dns server on your local network, you can assign as many names as you like to a given IP address. If you have a wireless and/or dsl router on your network they often include a dns server and/or proxy. Otherwise, try reading up on bind (the Berkeley Internet Name Daemon).
Well, maybe not: settting DHCLIENT_HOSTNAME_OPTION=myname2 in /etc/sysconfig/network-scripts/ifcfg-eth0 and disabling
DHCLIENT_HOSTNAME_OPTION and DHCLIENT_CLIENT_ID
in /etc/sysconfig/network-scripts/dhcp
seems to work as expected, at least with a single network interface, but then why isn't it possible to specify a configuration like that in yast?
YaST seems to be mainly designed at basic, dare I say "lowest common denominator" setups in many cases, which is fair enough for the average user who does not need to do more advanced stuff. Those users who do need advanced features or configurations will usually either a) know enough to manually hack the configuration files or b) know where to go to get the information to allow them to learn how to hack the config files :-).
Where's a specification of the valid settings for the ifcfg-ethN files? Thanks, Nico
Try man ifcfg... -- =================================================== Rodney Baker VK5ZTV rodney.baker@iinet.net.au =================================================== The grand leap of the whale up the Fall of Niagara is esteemed, by all who have seen it, as one of the finest spectacles in nature. -- Benjamin Franklin.
On Mon, 16 Jun 2008 19:58:35 +0930
Rodney Baker
Yes, you can use both wireless and wired ethernet but not both to the same network - they must be in different subnets or you will generate routing loops
I disagree here. I have configured multiple interfaces on the same
subnet many times. You certainly need a unique IP address. I have used
both static and dynamic IP addresses. There may be only 1 default
route. I have also had occasions to have multiple subnets on the same
physical segment. I currently run a couple of servers where we have 5
IP addresses, which 2 or 3 assigned to physical machines, and the
others assigned logically to the primary interface.
One issue here is that you can only have 1 host name associated with an
IP address, and this is where having a combination of static and
dynamic addresses work.
--
--
Jerry Feldman
On Tue, 17 Jun 2008 01:34:45 Jerry Feldman wrote:
On Mon, 16 Jun 2008 19:58:35 +0930
Rodney Baker
wrote: Yes, you can use both wireless and wired ethernet but not both to the same network - they must be in different subnets or you will generate routing loops
I disagree here. I have configured multiple interfaces on the same subnet many times. You certainly need a unique IP address. I have used both static and dynamic IP addresses. There may be only 1 default route.
It can be done but you must be careful not to cause routing loops. IMHO it is best avoided unless you are conversant in IP networking and know how to use the right tools to troubleshoot if you run into problems. It can even be useful for redundancy and bandwidth sharing purposes, which is where things like STP (spanning tree protocol) and RIP come into play but I wouldn't recommend it to a networking novice.
I have also had occasions to have multiple subnets on the same physical segment. I currently run a couple of servers where we have 5 IP addresses, which 2 or 3 assigned to physical machines, and the others assigned logically to the primary interface.
I commonly do this on my laptop where I have to plug into different networks in different physical locations for testing and maintenance purposes. Having multiple IP's for the same interface (all on different subnets) helps to reduce the need to reconfigure at each location...
One issue here is that you can only have 1 host name associated with an IP address, and this is where having a combination of static and dynamic addresses work.
I disagree with that statement. You can have multiple hostnames associated with a given ip address and multiple ip addresses (on different networks) associated with the same host name for a multi-homed machine, however each machine can only be configured locally with a single hostname. To illustrate my point, run `dig mail.iinet.net.au` and `dig smtp.iinet.net.au`. Both names resolve to the same IP address. You can have multiple host names with dns entries pointing to the same IP address, just as you can use multiple aliases for a single address in /etc/hosts. You would not, however, use multiple entries in /etc/hosts with the same host name pointing to different ip addresses - that simply wouldn't work. The only way that I'm aware of to have multiple different IP's (in different subnets) for the same host is if they're on different networks and registered wtih different dns servers that are specific to each network (or have individual entries in /etc/hosts for each client on the various subnets). This would only be useful, however, if there was otherwise no connectivity between the different networks; after all, that is what routers are for. Of course, the same applies to having multiple subnets on the same physical segment with mutiple logical addresses assigned to the one interface. -- =================================================== Rodney Baker VK5ZTV rodney.baker@iinet.net.au =================================================== Flugg's Law: When you need to knock on wood is when you realize that the world is composed of vinyl, naugahyde and aluminum.
On Tue, 17 Jun 2008 08:34:24 +0930
Rodney Baker
It can be done but you must be careful not to cause routing loops. IMHO it is best avoided unless you are conversant in IP networking and know how to use the right tools to troubleshoot if you run into problems. It can even be useful for redundancy and bandwidth sharing purposes, which is where things like STP (spanning tree protocol) and RIP come into play but I wouldn't recommend it to a networking novice.
You are talking about routing protocols. This would be true if you used
the 2 NICS for routing. But, simply having 2 NICS each with a separate
IP address on the same subnet is not going to cause a problem. I
sometimes do it on one of my laptops by having both a wired and
wrieless working. If you are using simply static routing, there should
be no problem. But, you really don't get much (or any) benefit unless
you want the redundant bandwidth. But, I have never seen a routing loop
caused by a simple routing table in an end-user machine.
--
--
Jerry Feldman
participants (4)
-
Jerry Feldman
-
Masim "Vavai" Sugianto
-
Nico Sabbi
-
Rodney Baker