Sponsored Content
Operating Systems Linux Red Hat Dual NICs - When I 'ifup eth1' it replaces eth0 Post 302753435 by phaedrus on Tuesday 8th of January 2013 04:08:44 PM
Old 01-08-2013
Dual NICs - When I 'ifup eth1' it replaces eth0

I've got an issue with a VMWare server running RHEL 6.3 that has dual E1000 NICs. I have configured the cards as I would normally do in /etc/sysconfig/network-scripts as ifcfg-eth0 and ifcfg-eth1. I can execute ifup eth0 and bring the interface up quite happily, however when I execute ifup eth1 it succeeds but the IP details are assigned to eth0 and eth1 has no IP details as shown below:

Code:
eth0      Link encap:Ethernet  HWaddr 00:50:56:XX:XX:XX  
          inet addr:X.X.X.X  Bcast:X.X.X.X  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:16073098 errors:0 dropped:0 overruns:0 frame:0
          TX packets:12947041 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:3523869151 (3.2 GiB)  TX bytes:3595458089 (3.3 GiB)

eth1      Link encap:Ethernet  HWaddr 00:50:56:XX:XX:XX  
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:203710 errors:0 dropped:0 overruns:0 frame:0
          TX packets:13025 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:14763933 (14.0 MiB)  TX bytes:5191322 (4.9 MiB)

I've checked /etc/udev/rules.d/70-persistent-net.rules and the MAC addresses match what is in vSphere for the virtual hardware. I can't find anything else that appears weird or unexpected.

Does anyone have any ideas as to what I might have screwed up here?
 

10 More Discussions You Might Find Interesting

1. Red Hat

ifcfg-eth0 and eth1 is N/A

when i finish installed rhel 4.4 to my hp dl585 box, ifcfg-eth0 and ifcfg-eth1 is not available.when i ifconfig -a,i can not see the eth0 and eth1, only lo0 and si0. Unlike to the other server i found eth0 and eth1 files in /etc/sysconfig/network-scripts/. what will i do? (2 Replies)
Discussion started by: kenshinhimura
2 Replies

2. UNIX for Advanced & Expert Users

When is 'ifup' really done?

I have been looking in the scripts for interface management, in an effort to kick off a script of my own on any "significant network event" (I will qualify that in a bit) I managed to add a check to tell netplugd to run my script every time there is a hot-plug event. Now I need to make it so my... (0 Replies)
Discussion started by: jjinno
0 Replies

3. Shell Programming and Scripting

log in ifup

I have a little script in the /etc/network/if-up.d (debian). It should do something and write the output to a log file. But it doesn't seem to work. ifup wlan0 dosomething >> /var/log/dosomething.log I would like to add the date to the output, can somebody help me please? Thanks! (6 Replies)
Discussion started by: borobudur
6 Replies

4. UNIX for Dummies Questions & Answers

controlling traffic source from NIC eth0, eth1 in Linux

Hi Guys, is there a way to send traffic coming from the source iface (eth0, eth1)? i need to test traffic that will come from both eth0 and eth1 from a Linux box. Thanks, Martin (0 Replies)
Discussion started by: mdap
0 Replies

5. Solaris

Reg- eth0,eth1 (ethernet card)

Hi Guys, I am working as a L-1 support and i want to know that are the precaution need to take on eth0(Ethernet card) i heard on production server it is very much important, what are the steps need to observe on this tickets. (1 Reply)
Discussion started by: kurva
1 Replies

6. Red Hat

ifconfig , ifdown, ifup

hi there the ethernet wire was out of the pc when the system started. #ifconfig #ifconfig -a i did not get any ip for eth0. i plug the cable into the pc #ifdown eth0 #ifup eth0 now the ip address is assigned to eth0 Question is : IS this right way to bring ethernet down... (2 Replies)
Discussion started by: dplinux
2 Replies

7. Ubuntu

Ubunut iptable not routing trafic between eth1 and eth0

hello, first of all i am new to unix so maybe my problem is very easy for many of you but is very important to me. So the idea is that i want to use a ubuntu 10.4 machine as a router from eth0 to eth1. but the traffic routing is nor working properly i configured the 2 interfaces to be... (2 Replies)
Discussion started by: florin.bv
2 Replies

8. IP Networking

Problem in eth0 and eth1 sharing internet with other computers

hellow everbody. iam using 32 bit centos 6.2 on my desktop and iam new to linux. i have eth0 and eth1 on my desktop. so i have some problems i have menson here: i have edited: etc/sysctl.conf net.ipv4.ip_forward = 1 and i have edited iptables too # iptables -t nat -A... (2 Replies)
Discussion started by: paruhang
2 Replies

9. Red Hat

Wan on eth1 and Lan on eth0

I have a local network on dev eth0 Server has static IP of 10.0.0.1 Gateway is 10.0.0.1 and Dns is 10.0.0.1 I am using this network for imaging 500 plus computer... Now, Issue that I am having is that I need to update packages and I dont want to change the configuration on eth0 because I... (0 Replies)
Discussion started by: golpemortal
0 Replies

10. IP Networking

Why eth1 with auto dhcp disturbs pppoe over eth0?

Hi, I use ubuntu 16.04 desktop with ufw (default setup + 22, 80, 443 ports open). I connect directly to ISP using pppoe over eth0. I also have eth1 which when disabled the websites are accessible in browser. When starting eth1 with auto dhcp the websites are no longer accessible in browser (give... (3 Replies)
Discussion started by: adrhc
3 Replies
ROUTES(5)						       Network configuration							 ROUTES(5)

NAME
routes - configure the routing table SYNOPSIS
/etc/sysconfig/network/routes /etc/sysconfig/network/ifroute-* DESCRIPTION
The files /etc/sysconfig/network/routes and /etc/sysconfig/network/ifroute-config are parsed by the script /etc/sysconfig/net- work/scripts/ifup-route which sets up routing for an interface/configuration. ifup-route is used by /sbin/ifup, which is the command line user interface for setting up network interfaces. /etc/sysconfig/network/routes is used for every interface while /etc/sysconfig/network/ifroute-config is used only for the network inter- face configuration stored in /etc/sysconfig/network/ifcfg-config, that means only for a certain interface. (See a discussion of the notions configuration, interface and device in ifup(8).) At boot time /etc/init.d/network calls ifup for every existing configuration and uses ifup-route directly to set up special routes which do not belong to a certain interface. The current routes can be seen by issuing: /sbin/ip route list which will give the current routing table. Syntax The files /etc/sysconfig/network/routes and /etc/sysconfig/network/ifroute-config use the same syntax. The only difference is the interpre- tation of an empty interface field. See 4th column below. Lines beginning with # and blank lines are ignored. There are 5 columns with special meaning. Write a dash "-" if you want to omit an entry for a field. If all following fields in the line are empty too, you can even omit the dash. The first column gives the destination, written as the IP-address of a host or a network. The heading default indicates that the route is the default gateway. Do not use 0.0.0.0 for this purpose. A prefix-length (CIDR notation) can be used; e.g., 10.10.0.0/16 and also 10.10/16 are valid. The second column contains the gateway. Write here the regular IP-address of a host which routes the packets to a remote host or remote network. You can omit this information for rejecting routes. The third column gives the netmask for a remote host or remote network behind a gateway. For the default route or if you were using a pre- fix-length (CIDR notation) in the first column, you can omit it. The fourth column gives the name of the interface of the local networks (lo, eth0, eth1, isdn0, ppp0, dummy0, ...). If you leave this field empty the result depends on the file you are using. In /etc/sysconfig/network/routes the field is interpreted as no interface information available. That is sufficient for the most routes you may set up, but if you have multiple interfaces this route is set up with every single interface you activate. This may lead to error messages in the syslog. If you see such an error message which tells you "... this needs NOT to be AN ERROR" then check if you wrote the wrong ip addresses or if it occurs because it's being set up with the wrong interface. In the latter case you may want to use /etc/sysconfig/network/ifroute-config instead. Here an empty interface field is always replaced with the interface name that is currently being activated. This makes sense because this file is only used for one configuration (for one inter- face). Note: Static routes without explicit interfaces will also replace routes to the same destination (network) configured by dhcp clients on any interface! Static routes with explicit interface will also replace routes to the same destination (network) configured by dhcp clients on this inter- face. The fifth column can be used to specify the type of a route: unicast The route entry describes real paths to the destinations covered by the route prefix. local The destinations are assigned to this host. The packets are looped back and delivered locally. broadcast The destinations are broadcast addresses. The packets are sent as link broadcasts. multicast A special type used for multicast routing. It is not present in normal routing tables. throw A special control route used together with policy rules. If such a route is selected, lookup in this table is terminated pretending that no route was found. Without policy routing it is equivalent to the absence of the route in the routing table. The packets are dropped and the ICMP message net unreachable is generated. The local senders get an ENETUNREACH error. unreachable These destinations are unreachable. Packets are discarded silently. The local senders get an EINVAL error. prohibit These destinations are unreachable. Packets are discarded and the ICMP message communication administratively prohibited is gener- ated. The local senders get an EACCES error. blackhole These destinations are unreachable. Packets are discarded silently. The local senders get an EINVAL error. nat A special NAT route. Destinations covered by the prefix are considered to be dummy (or external) addresses which require translation to real (or internal) ones before forwarding. The addresses to translate to are selected with attribute 'via'. Any remaining columns, if given, are appended to the route command. This makes it possible to pass special options for this route. Columns which are not needed should contain a minus sign ( - ) to ensure that the parser correctly interprets the command. EXAMPLES
An example with common network interfaces and some static routes: # Destination Dummy/Gateway Netmask Interface # 127.0.0.0 0.0.0.0 255.255.255.0 lo 204.127.235.0 0.0.0.0 255.255.255.0 eth0 default 204.127.235.41 0.0.0.0 eth0 207.68.156.51 207.68.145.45 255.255.255.255 eth1 192.168.0.0 207.68.156.51 255.255.0.0 eth1 # --- same routes as above in CIDR notation: # Destination [Gateway] - Interface 127.0.0.0/8 - - lo 204.127.235.0/24 - - eth0 default 204.127.235.41 - eth0 207.68.156.51/32 207.68.145.45 - eth1 192.168.0.0/16 207.68.156.51 - eth1 # --- IPv6 routes are always using CIDR notation: # Destination [Gateway] - Interface 2001:DB8:100::/64 - - eth0 2001:DB8:100::/32 fe80::216:3eff:fe6d:c042 - eth0 An example for routing entries for synchronous ppp over a ISDN connection. # Destination Dummy/Gateway Netmask Interface # 127.0.0.0 0.0.0.0 255.255.255.0 lo 193.102.150.13 0.0.0.0 255.255.255.255 ippp0 default 193.102.150.13 0.0.0.0 ippp0 Note: Routes to directly connected network are created automatically (Linux kernel 2.4 and later) as soon as the IP address is assigned to the interface. For example, when the eth0 interface IP addresses are 204.127.235.42/24 and 2001:DB8:100::42/64, the following routes from above examples are created automatically: 204.127.235.0/24 - - eth0 2001:DB8:100::/64 - - eth0 and should be omitted. NOTES
SuSE Linux >= 8.0 uses the ip command from the iproute2 package to setup the network and routes. Please see the documentation distributed with this package for more information. FILES
/etc/sysconfig/network/routes /etc/sysconfig/network/ifroute-config AUTHOR
Michal Svec <msvec@suse.cz> Christian Zoz <zoz@suse.de> Mads Martin Joergensen <mmj@suse.de> Thanks to Werner Fink <werner@suse.de> for the old route.conf(5). Parts of the ip reference by Alexey Kuznetsov <kuznet@ms2.inr.ac.ru> were also used. SEE ALSO
init.d(7), init(8), inittab(5), the documentation for the iproute2 package and the SuSE Linux handbook, chapter The SuSE boot concept. sysconfig January 2003 ROUTES(5)
All times are GMT -4. The time now is 10:01 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy