# dhcp won`t start

## bin-doph

Hi there,

I've installed net-misc/dhcp (3.0_p2) and used my old config-file on my gentoo 1.4_rc4 box, but if I want to start the daemon I get the following error:

```

 * Starting dhcpd...

Internet Software Consortium DHCP Server V3.0pl2

Copyright 1995-2003 Internet Software Consortium.

All rights reserved.

For info, please visit http://www.isc.org/products/DHCP

Wrote 0 leases to leases file.

socket: Protocol not available - make sure

CONFIG_PACKET (Packet socket) and CONFIG_FILTER

(Socket Filtering) are enabled in your kernel

configuration!

...blablabla...

exiting.

```

but my kernel includes those modules

```

odie dhcp-3.0_p2 # cat /proc/config | egrep "CONFIG_PACKET|CONFIG_FILTER"

CONFIG_PACKET=y

CONFIG_FILTER=y

```

and the configurationfiles seem to be ok too, I guess

/etc/conf.d/dhcp:

```

IFACE="eth0" # This is the correct interface, which dhcpd should use

DHCPD_OPTS=""

```

thx for any piece of advice

cheers

fe

----------

## jkcunningham

Is it possible you changed your USE flags in some way that is preventing support from being compiled into the kernel?  Its the only thing I can think of.

----------

## hotpotato

Did you recompile your kernel to add these options in?

Not sure of the exact notation in /proc/config, but perhaps you need to load these if you compiled them as modules.

It is kind of puzziling... I had a similar problem, recompiled the kernel with these options, copied the bzImage to /boot and bingo, worked fine.

Can't think of anything else.

Hopefully this is of some help.

----------

## bin-doph

 *jkcunningham wrote:*   

> Is it possible you changed your USE flags in some way that is preventing support from being compiled into the kernel?  Its the only thing I can think of.

 

No I didn't. In what way should that prevent the dhcpd from starting?

----------

## bin-doph

 *hotpotato wrote:*   

> Did you recompile your kernel to add these options in?
> 
> Not sure of the exact notation in /proc/config, but perhaps you need to load these if you compiled them as modules.
> 
> It is kind of puzziling... I had a similar problem, recompiled the kernel with these options, copied the bzImage to /boot and bingo, worked fine.
> ...

 

I compiled those stuff in the kernel. The notation is

  y  for compiled in

  m for module

and thats it and if both says y in /proc/config then it means that the running kernel has this modules. So this cant be the problem I guess.

----------

## jkcunningham

Which daemon are you trying to start? dhcpcd or dhcpd?

----------

## bin-doph

as I wrote. isc dhcpd

D H C P D (I dont think you're stupid, I got mixed up too)

----------

## karl420

I had the same problem. I just compiled support into the kernel, rebooted, then it worked fine.

Is it possible you compiled one as a module, and its not loaded?

Karl

----------

## bin-doph

 *karl420 wrote:*   

> I had the same problem. I just compiled support into the kernel, rebooted, then it worked fine.
> 
> Is it possible you compiled one as a module, and its not loaded?
> 
> Karl

 

What support did you compile into your kernel? No I didnt compile CONFIG_PACKET or CONFIG_FILTER as modules as you can read in the previous postings

```

odie root # egrep "CONFIG_PACKET|CONFIG_FILTER" /proc/config 

CONFIG_PACKET=y

CONFIG_FILTER=y

```

----------

## jkcunningham

You should read this thread:

https://forums.gentoo.org/viewtopic.php?t=63577

Might help.

----------

## bin-doph

seems like it has anything to do with multiple NIC's. If got almost the same setup on another box with only one NIC and dhcp works fine... is anybody running dhcp on a box with multiple NIC's? Does anybody had the same problem?

cheers

----------

## sandro123

 *bin-doph wrote:*   

> seems like it has anything to do with multiple NIC's. If got almost the same setup on another box with only one NIC and dhcp works fine... is anybody running dhcp on a box with multiple NIC's? Does anybody had the same problem?
> 
> cheers

 

Yes i have the same Problem, but had not time right now to go further in this problem. But i have the same error and two nics.

Ciao

      Alessandro

When i find something i will tell you

----------

## JaquesStrap

Multi-Homed box, with CONFIG_PACKET and CONFIG_FILTER support compiled into the kernel. I even recompiled for good measure, no success.

I thought maybe it was a grsecurity issue, but I removed all grsecurity support and no luck.

Life would sure be good if I could get dhcpd working on this Gentoo server. So if anyone has any suggestions they are appreciated.

Regards,

Jaques

----------

## bin-doph

Hi there all people watching this thread with the same problem, here is your solution. Update to the latest vanilla-sources, which is for me

```
*  sys-kernel/vanilla-sources

      Latest version available: 2.4.22

```

and dhcpd will work.

have fun

https://bugs.gentoo.org/show_bug.cgi?id=31455

----------

## docfab

Hi, I had the same problem, trying to emulate your solution but getting nowhere. Rather much of a beginner and pretty sure I am missing a step here...

was running linux-2.4.20-gentoo-r5

did an emerge sys-kernel/vanilla-sources

copied my .config over and did a make oldconfig

point /usr/src/linux to the new tree

make dep && make clean bzImage

fails on ksyms.c (not the faintest idea what that is) while making bzImage. 

Am I missing something?

----------

## dma

I use something like this:

```
# dhcpd.conf

#

# Configuration file for ISC dhcpd

# dmatech.org

#

# Default options and option definitions common

# to all supported networks...

option domain-name "private.dmatech.org";

option proxy-definition-url code 252 = string;

ddns-update-style interim;

default-lease-time 604800;      # Exactly one week.

max-lease-time 604800;          # Exactly one week.

# If this DHCP server is the official DHCP server for the local

# network, the authoritative directive should be uncommented.

authoritative;

# Wireless portion of the network.

# This portion of the network is connected via interface eth1.

subnet 192.168.1.0 netmask 255.255.255.0 {

  range 192.168.1.2 192.168.1.253;

  option ip-forwarding off;

  option domain-name "wireless.dmatech.org";

  option domain-name-servers 192.168.1.1;

  option routers 192.168.1.1;

#  option proxy-definition-url "http://192.168.1.1/wpad.dat";

}

# Wired portion of the network.

# This portion of the network is connected via interface eth2.

subnet 192.168.2.0 netmask 255.255.255.0 {

  range 192.168.2.2 192.168.2.253;

  option ip-forwarding off;

  option domain-name "lab.dmatech.org";

  option domain-name-servers 192.168.2.1;

  option routers 192.168.2.1;

#  option proxy-definition-url "http://192.168.2.1/wpad.dat";

}
```

When I start it, I get this:

```
 * Starting chrooted dhcpd...

Internet Software Consortium DHCP Server V3.0pl2

Copyright 1995-2003 Internet Software Consortium.

All rights reserved.

For info, please visit http://www.isc.org/products/DHCP

Wrote 4 leases to leases file.

Listening on LPF/eth2/00:09:5b:1a:9f:e0/192.168.2.0/24

Sending on   LPF/eth2/00:09:5b:1a:9f:e0/192.168.2.0/24

Listening on LPF/eth1/00:e0:18:9c:25:45/192.168.1.0/24

Sending on   LPF/eth1/00:e0:18:9c:25:45/192.168.1.0/24

Sending on   Socket/fallback/fallback-net                                 [ ok ]

```

It seems to work here.  (I have both of those set to "y" as well).

----------

## bin-doph

 *docfab wrote:*   

> 
> 
> was running linux-2.4.20-gentoo-r5
> 
> did an emerge sys-kernel/vanilla-sources
> ...

 

what version are ur vanilla-sources?

first READ the README, then compile ur kernel 

```

cd /usr/src/linux

cp /where/ur/config/is/.config .

make oldconfig

## now u propably have to answer some answers about new features

## read the questions and answer that way

make modules modules_install bzImage

## make sure /boot is mounted

mv /boot/bzImage /boot/bzImage.backup

cp arch/i386/boot/bzImage /boot/

## check /etc/lilo.conf and create/modify a section to point to ur new 

## kernel-image at /boot/bzImage and run lilo

lilo

unmount /boot

## done, now reboot
```

----------

## dkaplowitz

 *bin-doph wrote:*   

> 
> 
> first READ the README, then compile ur kernel 
> 
> 

 

Which README are you talking about?

----------

