RE: Default Route question when there are two nic cards

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



"Styma, Robert E (Robert)" <stymar@xxxxxxxxxx> wrote:

Mine is set in /etc/sysconfig/network

GATEWAY=148.197.29.254

but sometimes appears in all of the
/etc/sysconfig/network-scripts/ifcfg-ethx's

Don't think there is any harm in having it in all of them - provided it
says the same thing!

That did the trick.  That an removing the erroneous one from ifcfg-eth1.
Turns out the last one processed won.

The default route is tried last. I end up with the following routing table using the ifcfg-ethX files below:

[root@fraud ~]# netstat -n -r
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface 72.19.169.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth1 192.168.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth1 0.0.0.0 72.19.169.1 0.0.0.0 UG 0 0 0 eth0
[root@fraud ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
# 3Com Corporation 3c905C-TX/TX-M [Tornado]
DEVICE=eth0
ONBOOT=yes
BOOTPROTO=static
IPADDR=72.19.169.230 <-- My external IP address
NETMASK=255.255.255.0
GATEWAY=72.19.169.1 <-- My ISP's gateway
[root@fraud ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth1
DEVICE=eth1
ONBOOT=yes
BOOTPROTO=none
IPADDR=192.168.255.254
NETMASK=255.255.0.0
GATEWAY=72.19.169.230 <-- Set GW for internal NIC to external IP address
TYPE=Ethernet
USERCTL=no
IPV6INIT=no
PEERDNS=yes
MTU=9000

Internal traffic from the server goes out eth1 since that route gets tried before the default route.

Cheers,
Dave

--
Politics, n. Strife of interests masquerading as a contest of principles.
-- Ambrose Bierce

--
fedora-list mailing list
fedora-list@xxxxxxxxxx
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [Fedora Magazine]     [Fedora News]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Maintainers]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Legacy]     [Fedora Desktop]     [Fedora Fonts]     [ATA RAID]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [SSH]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Centos]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Tux]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Asterisk PBX]     [Fedora Sparc]     [Fedora Universal Network Connector]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux