View Full Version : IP address binding
erazmus
03-12-2007, 05:39 PM
I have a box with two ethernet ports. Port 1 is the outside world, with multiple IP addresses bound to it. port 2 is on a private network with a single IP address bound to it. The machine keeps forgetting about the second port. I have a /etc/sysconfig/network-scripts/ifcfg-eth1 script which runs at boot time, but sometime later the port disappears. Also, the extra IPs added from the GUI aren't in the /etc/sysconfig/network-scripts directory. Where are they stored? What file do I edit to set up the IP address for the second interface??
Jeremy
03-13-2007, 03:13 AM
what does your ifcfg-eth1 look like?
I think they might put it in the /etc/rc.d/ but im not sure.
I have a box with two ethernet ports. Port 1 is the outside world, with multiple IP addresses bound to it. port 2 is on a private network with a single IP address bound to it. The machine keeps forgetting about the second port. I have a /etc/sysconfig/network-scripts/ifcfg-eth1 script which runs at boot time, but sometime later the port disappears. Also, the extra IPs added from the GUI aren't in the /etc/sysconfig/network-scripts directory. Where are they stored? What file do I edit to set up the IP address for the second interface??
You can find the ip addresses within the /var/db/dsm/conf/ips file and our bound using the route command.
erazmus
03-13-2007, 11:34 PM
You can find the ip addresses within the /var/db/dsm/conf/ips file and our bound using the route command.
Thank you Paul. Unfortunately, this doesn't help. In the file, I can see all of my IP addresses that I have defined in the GUI. They show up when I do a 'ifconfig' from the shell. Unfortunately, there doesn't seem to be a machanism to define which physical ethernet card to bind the address to. I have a second card defined as follows in /etc/sysconfig/network-scripts:
NETMASK=255.255.255.0
BOOTPROTO=none
IPADDR=10.1.1.1
NETMASK=255.255.255.0
HWADDR=00:11:09:8c:31:cb
ONBOOT=yes
TYPE=Ethernet
DEVICE=eth1
By the time the GUI comes up, the interface disappears from a 'ifconfig' list. I can manually do a 'ifup eth1' and it'll appear again, but any tinkering of the IP addresses in the GUI seem to make eth1 disappear. Any ideas??
erazmus
03-13-2007, 11:35 PM
(I forgot to mention in the last post that the full filename of the quoted script is /etc/sysconfig/network-scripts/ifcfg-eth1)
Jeremy
03-16-2007, 01:44 AM
BOOTPROTO=static
Jeremy
03-16-2007, 01:50 AM
Press send to quick.
what does dmesg say when the internal ip stops responding?
erazmus
03-20-2007, 04:05 PM
Press send to quick.
what does dmesg say when the internal ip stops responding?
The last few dmesg lines to do with eth1 are:
eth1: Media Link On 100mbps full-duplex
eth1: no IPv6 routers present
eth1: Media Link Off
eth1: Media Link On 100mbps full-duplex
The link off and on is because we changed from a crossover cable to a full switch between the two machines. The switch didn't solve the problem. As I mentioned before (I think) ifconfig shows eth1 completely missing. 'ifup eth1'
brings the interface back up, but it then disappears within 48 hours. I have many, many machines running fc6 with dual NICs and I've never encountered this problem!
erazmus
03-21-2007, 12:21 PM
Thanks to some pointers from Zervex support, I've got somewhere with this. For anyone who is interested, there is a Zervex-created file /etc/rc.d/init.d/aliases that walks the /var/db/dsm/conf/ips file to create virtual interfaces for anything that's changed in the GUI. However, when run with 'restart' it downs all interfaces, not just eth0 with all of the virtual interfaces. This makes eth1, etc disappear. I've asked for a patch - we'll see what happens.
Jeremy
04-04-2007, 01:58 AM
Well if it were me.
I like the GUI but for me i like to know where and whats going on, so i do it by hand. I would remove what the GUI has added and just use ifcfg-eth1 file for your needs.
Thanks for the heads up. =)
vBulletin v3.5.1, Copyright ©2000-2010, Jelsoft Enterprises Ltd.