# Networking problems - need stable install procedure [solved]

## snunezcr

Hello everyone,

These days I've been installing a sparc cluster with Gentoo. Everything goes smooth until configuring the networking part. There are things that I've done:

a. Compiled the kernel with built in adequate nic support (avoiding module loading for both eth0 and eth1)

b. No ACPI present that generates conflicts

b. Updated base layout

c. Unmerged udev->devfsd (knowing that sparc uses a 2.4 kernel)

d. Checked net.eh0, net.eth1 -> net.lo

Sympthoms:

The dhcpcd client just hangs after invocation with no status/error message. I read the threads related to the subject, but only once I got good results applying the solutions in different orders. Also, my clients are unable to dhcp the server. The problem is that I can't replicate the results (I've tried many things).

Question:

What is the correct order that must be followed (if any) in order to get compatibility with neworking in a stable installation procedure?

I plan to NFS the portage tree to eliminate traffic, but I'd like to hear suggestions on this.

 Are there conflicts between NFS and say PVFS or OpenAFS if I install previously NFS?

Thanks

----------

## overkll

snunezcr,

I've never done either a sparc or cluster install, but I think more info from your end is needed for others to help you.

 *Quote:*   

> These days I've been installing a sparc cluster with Gentoo. Everything goes smooth until configuring the networking part. 

 

1.  Are you referring to the installation, or post installation setup?

2.  Can you post "emerge info"

3.  Is this sparc32 or 64

4.  Which installation .iso are you using?

5.  Which stage are you using?

 *Quote:*   

> here are things that I've done:
> 
> a. Compiled the kernel with built in adequate nic support (avoiding module loading for both eth0 and eth1)
> 
> b. No ACPI present that generates conflicts
> ...

 

1.  This is the server, right?

2.  Which kernel are you using?

3.  Guessing this is post installation since you've updated baselayout and unmerged udev.

4.  If you used the sparc install medium, why would udev be installed if sparc uses a 2.4 series kernel?

5.  Is this machine a dhcp server, client or both.

6.  What are the interfaces primary functions?  eth0 -> internet, eth1 -> local net, dhcpd or dhcp client on ethX?

8.  Post your /etc/conf.d/net and probably and dhcp config info.

9.  What brand(s) and model(s) of ethernet adapters?

10.  Which kernel driver(s) is selected for the ethernet adapters?

11.  Have you tried static ip's to test if the ethernet adapters are working?

12.  Do you have dhcp client and or server installed?  If so, which package?

As you can see, more specific information would be useful.   :Wink: 

----------

## snunezcr

Thanks for posting back

 *overkll wrote:*   

> snunezcr,
> 
> I've never done either a sparc or cluster install, but I think more info from your end is needed for others to help you.
> 
>  *Quote:*   These days I've been installing a sparc cluster with Gentoo. Everything goes smooth until configuring the networking part.  
> ...

 

1. Exactly after rebooting and post installation process

2. Yes, as soon as I get tomorrow to the lab

3. Sparc64

4. Minimal install

5. Stage 3

 *overkll wrote:*   

> 
> 
> 1.  This is the server, right?
> 
> 2.  Which kernel are you using?
> ...

 

1. Yes, it's the server

2. Kernel 2.4.32 sparc-sources

3. Yes, it's the post installation

4. According to the gentoo sparc install handook, it is part of the installation. Even though, I did notice the first time that emerge said effectively that udev was not installed, so I later didn't do it. I just listed it as one of the steps I tried.

5,6 . The machine is a dhcpd server for clients (eth1) and internet dhcp client (eth0)

7. ??? (Entering the realm of lost numbers...  :Shocked:  ...  :Wink:  )

8. /etc/conf.d/net (configured according to gentoo hcp how-to: http://www.gentoo.org/doc/en/hpc-howto.xml)

# dhcp from internet

iface_eth0="dhcp"

# lan internal ip

iface_eth1="10.0.1.50 netmask 255.255.255.0 broadcast 10.0.1.255"

9. Brand: Sun

Model eth0:  HappyMeal Ethernet 10/100

Model eth1: GEM 10/100/1000

10. The selected kernel drivers where those matching the latter NICs. They where built-in the kernel to avoid module loading.

11. Yes, I tried static IP addressing. No results unless using the install cd

12. Server: dhcp (don't remember the version right now)

Clients: dhclient and dhcpcd

I hope this may be much more explicit. Thanks again for your commitment and patience.

----------

## overkll

I have more questions.

Which Gentoo install version is this?  2005.1?

Which version of baselayout do you have installed?

The reason I ask is that

```
# dhcp from internet

iface_eth0="dhcp"

# lan internal ip

iface_eth1="10.0.1.50 netmask 255.255.255.0 broadcast 10.0.1.255"
```

is outdated for a 2005.1 install and new stable baselayout.  Perhaps the hpc guide was for a 2005.0 or earlier install?  The new format is like this:

```
config_eth0=( "dhcp" )

#dhcpcd_eth0="your dhcpcd options go here"

config_eth1=( "10.0.1.50 netmask 255.255.255.0 brd 10.0.1.255" )

routes_eth1=( "default gw your.gate.way.ip" )
```

You can look at /etc/conf.d/net.example for implicit instructions.

I suggest you revisit the appropriate gentoo sparc handbook and verify *ALL* your network settings.

Also, if this machine will be acting as a gateway, you'll need to enable ip forwarding.  Don't know how to do that the gentoo way, but if you dig around, Im sure youll find it.  I think the manual method is

```
echo "1"  > /proc/sys/net/ipv4/ip_forward
```

which will be lost on every reboot.

One more thing, and its important..... If this machine is the only thing separating your internal net from the internet, make sure to set up a firewall on the external interface or on an appliance/firewall in front of the external interface.

----------

## snunezcr

Gentoo install is 2005.1

Baselayout 1.11.14-r2

I changed the network settings according to your suggesitions, but no success.

Here is the emerge info data:

 *Quote:*   

> 
> 
> Gentoo Base System version 1.6.14
> 
> Portage 2.0.51.22-r2 (default-linux/sparc/sparc64/2005.1, gcc-3.3.5-20050130, glibc-2.3.3.20040420-r2, 2.4.31-sparc sparc64)
> ...

 

and the 

```
ifconfig -a
```

 when booting from the install cd

 *Quote:*   

> 
> 
> eth0      Link encap:Ethernet  HWaddr 00:03:BA:1D:98:C8  
> 
>           inet addr:10.3.254.249  Bcast:10.3.255.255  Mask:255.255.0.0
> ...

 

Something that I notice is that both eth0 and eth1 have the same hardware address, is this normal? Isn't it supposed that each card has its own haddr?

Another thing is that when I reboot normally, NICs are switched

eth0 -> HappyMeal

eth1 -> Gem

But this is a  *Quote:*   

> dmesg | grep "eth0"

  while running from the cd

 *Quote:*   

> 
> 
> eth%d: MII PHY ID: 437420 Enable Semiconductor
> 
> eth0: Sun GEM (PCI) 10/100/1000BaseT Ethernet 00:03:ba:1d:98:c8 
> ...

 

I'm really puzzled because of this network behaviour.

I also was thinking on some iptables config for doing the firewall stuff. Is it enough?

Thanks again.

----------

## snunezcr

After some reading/digging time about networking on sparc systems I found that by default in Blade 100 the NICs are assigned a unique system MAC address. This can be disabled with the command

```

[b]ok[/b] > setenv local-mac-address? true

```

which enables each NIC to use its own MAC address. And there are conflicts if the IP's assigned to both NICs are on different subnets (hmm...).

I changed such parameter, but still gentoo is assigning (and recognizes during boot) the same MAC for both cards, and still no ip address is given to it by dhcpcd. According to SUN's documentation, there is no other way to do it (some hidden switch or sort of).

If anyone knows something about it I will be very grateful.

Thanks.

----------

## overkll

Weird, haven't heard of that before.  You may want to contact Sun to report that their fix doesnt work for you and see if they have an alternate solution.

There may be a workaround.  What happens if you set both the the same subnet with static ip's and then set the external ethX to a pseudo interface?  Something like:

```
# external

config_eth0=( 

         "10.0.1.51 netmast 255.255.255.0 brd 10.0.1.255"

         "dhcp"

)

# internal

config_eth1=( "10.0.1.50 netmask 255.255.255.0 brd 10.0.1.255" )

routes_eth1=( "default gw your.gate.way.ip" )
```

That way, both interfaces are on the same subnet and eth0:1 would be dhcp.

You could use iptables to block the traffic between eth0 (10.x.x.x adress, not the dhcp) and eth1.

----------

## snunezcr

I did some test and found this:

1. The NIC is ok

2. Here I have a NetBDS install disc and it does recognizes both separate mac addresses.

So, following Sherlock Holmes reasoning, when possible and improbable assumptions fail, then we must consider the impossible.

I will report this as a bug. Thanks again.

----------

## overkll

 *snunezcr wrote:*   

> After some reading/digging time about networking on sparc systems I found that by default in Blade 100 the NICs are assigned a unique system MAC address. This can be disabled with the command
> 
> ```
> 
> [b]ok[/b] > setenv local-mac-address? true
> ...

 

Is that really the command, or is it a BBCode typo?  Looks like the command should be

```
setenv local-mac-address true
```

Did the command work, then is lost on reboot?

----------

## snunezcr

No, I did also thought that the first time, but local-mac-address is a boolean state variable. OpenBoot requires the ? to distiguish between boolean and non-boolean,

----------

