On 30 Jan 2004 22:22:51 +1300, Cameron Kerr <cameron.kerr@paradise.net.nz>
wrote:
> Robert B. <rpbyc@nospam.op.pl> wrote:
>> Hi,
>>
>> I have a small network with 4 Linux machines. Every machine has 2 NIC's.
>> The first NIC's are configured for an internal network (192.168.1.0),
>> the
>> second - for an external (say, 1.2.3.0).
>
> What is the reason for all this dual-homing? Is is some kind of research
> network, or cluster?
Yes, exactly, the external IP's are bind to 100Mb/s NICs and the internal
network is to be the fast one and the internal IPs are bind to the 1Gb/s
NICs.
The internal network is going to be used for clustering.
>
>> Every machine is running an sshd. Sometimes, when I want to connect from
>> one machine to another by ssh, I get "Connection timed out".
>
> Are you specify a hostname or IP address when you try to connect?
I've noticed that whether I specify a hostname or IP address, it behaves
without any changes.
>
> It seems to me that this happens when there are two (or more) machines
> responding to the same IP address, and therefore you have a MAC
> resolution race condition.
>
>> But then, If I just send, say 3 pings to the machine and try to ssh to
>> it again, it succeeds!
>
> Have a look on each machine (locally!) at the output of "arp -n" (will
> be in /usr/sbin or /sbin).
Well, it looks you are right... For instance, at the klaster2 node arp -n
gives:
192.168.1.1 ether 00:04:23:46:FC:BF C
eth0
1.2.3.4 ether 00:04:23:46:FC:BF C eth1
So, both interfaces have the same MAC configured! (What was with me for I
didn't
see that earlier?!)
:::::::
But: how do I fix it now? My ifcfg-eth0 and ifcfg-eth1 looks allright (I
hope):
:::::::
cat /etc/sysconfig/network-scripts/ifcfg-eth0:
# Intel Corp.|82540EM Gigabit Ethernet Controller
DEVICE=eth0
BOOTPROTO=none
BROADCAST=192.168.1.255
HWADDR=00:04:23:46:FC:AC
IPADDR=192.168.1.1
NETMASK=255.255.255.0
NETWORK=192.168.1.0
ONBOOT=yes
TYPE=Ethernet
USERCTL=no
PEERDNS=no
cat /etc/sysconfig/network-scripts/ifcfg-eth1:
# Intel Corp.|82557/8/9 [Ethernet Pro 100]
DEVICE=eth1
BOOTPROTO=none
BROADCAST=1.2.3.255
HWADDR=00:04:23:46:FC:BF
IPADDR=1.2.3.4
NETMASK=255.255.255.0
NETWORK=1.2.3.0
ONBOOT=yes
TYPE=Ethernet
USERCTL=no
PEERDNS=no
GATEWAY=1.2.3.100
Also, on the other machines, no MAC is repeated in the above 2 config
files,
so for now I don't know the cause of this situation.
>> Every linux was installed on one machine, and then the HDD was put
>> into appriopriate other machine, so after the installation, when the
>> network services were going down, there was a message about problems
>> with MAC address.
>
> Are you saying that you cloned each machine?
>
> What process did you use to achieve that?
No, I didn't clone the machines. It's just the only machine equipped with
the CDROM,
so I put the HDD into this machine, install Linux, and remount the HDD in
its own
machine.
>
> Are the IP addresses of the machines unique?
>
Yes.
>> But I think I repaired that, using MAC address got from the arp
>> command to put them into /etc/sysconfig/network-scripts/ifcfg-ethX.
>> Maybe it was not the good solution?
>
> You should not (ever, generally) specify a different MAC address (they
> are supposed to be unique).
>
I did not change the MAC address in the hardware, but I'm not sure how to
determine
the real, hardware MAC address. Then it should be inserted into ifcfg-eth0
and 1, shouldn't
it?
> Is there a DNS server it might also be querying?
Yes, there is.
Sorry for such a long message, but the problem isn't so simple as well
(for me...)
--
Regards,
Robert B.
rpbyc@op.pl