# Failed to bring eth0 up

## termee

After doing a install with a 2.6.1 kernel built with genkernel, I get this error message on boot:

Failed to bring eth0 up

ERROR:  Problem starting needed services.

             "netmount" was not started.

What do I do to make it work? On the LiveCD, it appears to be using the tulip module.

----------

## lghman

Is the tulip module loaded now?  Did you add it to your modules autoload file?

--sonik

----------

## termee

How do I do that?

----------

## lghman

```
lsmod
```

See if tulip shows up.  If not then 

```
modprobe tulip
```

That should do it for ya, then just restart your net.eth0 script.

--sonik

----------

## termee

When I run modprobe tulip, it says:

FATAL: Module tulip not found.

----------

## lghman

```
lifeafter2am $lsmod

Module                  Size  Used by    Not tainted

tulip                  43104   1 

```

Its definatly called tulip.

Oops, looks like genkernel didnt compile the module for your ethernet card.  I dont use genkernel so I cant tell you how to fix that, short of you compiling your own kernel.   :Wink: 

I can give you some links on that subject if you like.

--sonik

----------

## termee

Ok, that would be nice.

----------

## termee

Is it just a matter of booting from the livecd, running

make menuconfig

and then changing grub.conf?

----------

## lghman

http://www.techtv.com/screensavers/linux/story/0,24330,2433297,00.html

Yea, pretty much.

The big thing that you are looking for is under drivers --> network devices --> ethernet 10 or 100mbit --> tulip.  This is its own little directory and has several options for different tulip options.  If you want you can just select them all as modules and they will just load as needed with the tulip module.

--sonik

----------

## termee

Do I have to build my own kernel? Is there any way around this?

----------

## lghman

Not that I know of.  Like I said, I have never used genkernel so i dont know how it really works.  Maybe looking through the man page for genkernel there is an option to inject a certain module??  I really dont know....

--sonik

----------

## termee

OK, I build the kernel, and it boots. Here's the error message I get when it tries to load the driver:

```
modproble: FATAL: Error inserting tulip (/lib/modules/2.6.1-gentoo/kernel/drivers/net/tulip/tulip.ko): Invalid module format
```

A bunch of these messages come up. What do I do?

----------

## termee

What can I do about this?

----------

## lghman

When you made your kernel you did the standerd:

```
make clean && make && make modules_install
```

Also your linux diretory in /usr/src is linked to your current kernel right?  Another thing you could try is compiling support directly into your kernel instead of using a module.  I had a simular problem with my alsa drivers, and compiling them in ended up fixing it.

--sonik

----------

## termee

I didn't do the make clean, and it looks like my new kernel overwrote the old one, so the links should be set up properly.

Should I compile the kernel with the tulip support compiled in? Or is there something else I should do?

----------

## lghman

```
 $ ls -l /usr/src

total 32467

lrwxrwxrwx    1 root     root           12 Jan 20 01:24 linux -> linux-2.6.0/

drwxr-xr-x   16 root     root          624 Dec 20 18:41 linux-2.4.22-gentoo-r1

drwxrwxr-x   19 1046     1046         1184 Jan 21 12:14 linux-2.6.0

```

Your link should look like my first entry.  I would try compiling them in the kernel.  I cant see any reason that the module shouldnt load though.....Is that the only error message you get when you do the modprobe?  What about your logs?  dmesg maybe tells you more?

--sonik

----------

## termee

interesting... in the dmesg output is this:

```
tulip: version magic '2.6.1-gentoo preempt PENTIUMII gcc-3.2' should be '2.6.1-gentoo preempt PENTIMUM4 gcc-3.2'
```

I know I did change the processor in menuconfig to Pentium II from Pentium 4, because that's what this runs on. Should I change it back or something?

----------

## lghman

That almost makes me think something was wrong during the compile or something.  Go ahead and JUST run a 

```
make clean && make && make install
```

 and copy over your necessory files.  If that dosent work, then try compiling tulip directly into the kernel.  

--sonik

----------

## termee

 *sonikntails wrote:*   

>  copy over your necessory files.

 

What?

----------

## lghman

Your bzImage and your System.map files.

--sonik

----------

## termee

Wait a second, I copied the vmlinux not the bzimage last time. Let me try that first.

----------

## termee

Darn it, no good. I'm gonna compile it in and see what happens.

----------

## termee

Ugh. Back to the beginning. I don't get an errors in dmesg, but the same message I posted at the beginning appears. I have hotplug, does this matter?

----------

## lghman

What does 

```
ifconfig -a
```

 show you?  Look in your dmesg again, towards the beggining I would guess, for where the tulip loaded and post it.

--sonik

----------

## termee

There is nothing at all about the ethernet card or tulip in dmesg. All ifconfig shows is lo. I'd prefer not to have to post it because it obviously isn't on my network now and typing it is kind of tedious.

----------

## lghman

The only thing i can guess is that maybe there is something wrong with the tulip driver in the gentoo patched kernel??  Short of that I really dont know.  I use a vanilla kernel on my system with the tulip network adapter.  Anyone else have any ideas???   :Confused: 

--sonik

----------

## termee

I have a D-Link ethernet card... I'm gonna try that.

----------

## termee

Crud, now I get this:

modprobe: FATAL: Error inserting 8139too (/lib/modules/2.6.1-gentoo/kernel/drivers/net/8139too.ko): Invalid module format

Please don't tell me I have to recompile the kernel again  :Smile: 

----------

## lghman

No, okay, something is seriously wrong here.  Well, as far as I see it you have 2 choices, try a 2.4.xx series kernel or (what i would do) grab a vanailla kernel from kernel.org and use that.  Its just hard to diagnose problems with kenels that have all kinds of patchs on them.  (imo)  :Wink: 

You get props on my end for not givin up though!   :Cool: 

--sonik

----------

## termee

Should i use genkernel or build my own? And should I enable support as modules or compiled in?

----------

## lghman

You should build your own, it would be better.  I personally would compile them as modules, but the choice is utilmitaly yours.  

--sonik

----------

## termee

OK. I just noticed that my ethernet cable had come loose; I'll see if that's the problem before continuing. Thanks for the help BTW.

----------

## lghman

n/p  I hope you get it working.

--sonik

----------

## termee

Hmmm. I have hotplug installed, could this make a difference?

----------

## termee

Well I disabled hotplug and am recompiling the kernel again! I'm trying it on P4 mode; it might work. Should I load all of the tulip modules (if it lets me  :Smile:  ) ?

----------

## josh

I might just be beating a dead horse here, but I had a lot of problems with ethernet when I started using Gentoo.

When you configure your kernel, make sure that processor thing is ok. (make sure it's set to your processor type). Then when I compile I do:

```
make clean bzImage modules modules_install
```

then make sure your /boot directory is mounted (#mount /boot), then backup your old kernel (incase things go awry) and copy over your new kernel and System.map:

```
mount /boot

cp /boot/bzImage /boot/bzImage.old

cp /usr/src/linux/arch/i386/boot/bzImage /boot/bzImage

cp /usr/src/linux/System.map /boot/System.map

umount /boot
```

Again, these are just common problems I had. I also had a problem with the /usr/src/linux symlink, but sonik already covered that (and everything else I said for that matter). But maybe that'll help. And I'm NOT calling you a dead horse. Good Luck!

----------

## termee

OK, I've made progress. I can modprobe tulip, but how do I permanently install it?

----------

## termee

Yay it works! I had to put it in the autoload file! Thanks for all the help!

----------

