LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 10-04-2004, 08:11 PM   #1
lumbrjackedpcj
Member
 
Registered: May 2004
Posts: 45

Rep: Reputation: 15
setting up dhcp server? help please!!!!


Ive read alot on setting up a dhcp server but I just cant seem to get it working.

The ip of the dhcp server is 128.xxx.xxx.39. The subnet mask for this computer is 255.255.255.128. The default gateway is 128.xxx.xxx.1. I want to have another computer get an ip address from this computer using dhcp. The ip address I want to give out is 10.xxx.xxx.42. Below is what i have so far for my dhcpd.conf file. What should I put for option routers and everything else. Im just really confused.

subnet 10.227.237.0 netmask 255.255.255.128 {

# --- default gateway
range 10.xxx.xxx.42 10.xxx.xxx.42;
option routers ???.???.???.???;
option subnet-mask 255.255.255.128;

option domain-name "xxx.xxx.edu";
option domain-name-servers xxx.xxx.xxx.24,xxx.xxx.xxx.1,xxx.xxx.xxx.51;

default-lease-time 86400; #one day
max-lease-time 604800; #one week

host euclid {
hardware ethernet xxxxxxxxxxxx;
fixed-address 10.xxx.xxx.42;
}
}

When i start dhcpd it says:

Wrote 0 deleted host decls to leases file.
Wrote 0 new dynamic host decls to leases file.
Wrote 0 leases to leases file.

No subnet declaration for eth0 (128.xxx.xxx.39).
** Ignoring requests on eth0. If this is not what
you want, please write a subnet declaration
in your dhcpd.conf file for the network segment
to which interface eth0 is attached. **

Any help would be greatly apprecated!!!
Paul
 
Old 10-04-2004, 10:44 PM   #2
Tap-Out
Member
 
Registered: Oct 2002
Location: Halifax, NS
Distribution: Ubuntu, Mepis, Debian
Posts: 130

Rep: Reputation: 15
It looks to me like in your haste you forgot to create a dhcpd.leases file. DHCP needs this file to start up.

Code:
su
enter the root password
touch /var/lib/dhcp/dhcpd.leases
/etc/init.d/dhcpd restart
That should fix your problem. You may still get the error about ignoring the requests on eth0, but your clients should now be able to pick up dhcp addresses.

Cheers

Tap
 
Old 10-05-2004, 07:10 AM   #3
nordickiwi
Member
 
Registered: Oct 2004
Location: Stockholm Sweden
Distribution: Fedora 1-8,Familiar v0,7.2, Redhat 9.0, Knoppix, CentOS, Windows 2003,2000,XP,98,95, Exc
Posts: 39

Rep: Reputation: 15
Here you should put your default gateway IP address.

option routers ???.???.???.???;

/nordickiwi
 
Old 10-05-2004, 12:54 PM   #4
lumbrjackedpcj
Member
 
Registered: May 2004
Posts: 45

Original Poster
Rep: Reputation: 15
Unhappy still not workign

ok the dhcpd.leases file was there and now i have correctly added by gateway ip address. When i try and start the server it says:

[root@apollo dhcp]# /etc/init.d/dhcpd restart
Shutting down dhcpd: [FAILED]
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 deleted host decls to leases file.
Wrote 0 new dynamic host decls to leases file.
Wrote 0 leases to leases file.

No subnet declaration for eth0 (xxx.xxx.xxx.39).
** Ignoring requests on eth0. If this is not what
you want, please write a subnet declaration
in your dhcpd.conf file for the network segment
to which interface eth0 is attached. **

Any other suggestions?
Thanks,
Paul J
 
Old 10-05-2004, 01:28 PM   #5
ropbo
LQ Newbie
 
Registered: Aug 2004
Location: Vancouver, Canada
Posts: 5

Rep: Reputation: 0
Is it Debian ? If so, have you checked /etc/default/dhcp out ? Make sure you're using the correct Ethernet adapter.

INTERFACES="eth0"

You may also wanna play with /etc/init.d/dhcp

Also try:

/usr/sbin/dhcpd eth0


Rodrigo Otavio Paes de Barros Otaviano

Last edited by ropbo; 10-05-2004 at 01:32 PM.
 
Old 10-05-2004, 01:44 PM   #6
lumbrjackedpcj
Member
 
Registered: May 2004
Posts: 45

Original Poster
Rep: Reputation: 15
sorry, I am using fedora core 1.

Oh and the error message also says at the end(i cut it out before):

Not configured to listen on any interfaces!

Thanks,
paul J
 
Old 10-05-2004, 10:24 PM   #7
evilmrhenry
Member
 
Registered: Oct 2003
Distribution: Knoppix
Posts: 103

Rep: Reputation: 15
What does ifconfig look like? I was having the same problem till I actually set up eth0.
 
Old 10-06-2004, 11:01 PM   #8
ropbo
LQ Newbie
 
Registered: Aug 2004
Location: Vancouver, Canada
Posts: 5

Rep: Reputation: 0
Quote:
Originally posted by lumbrjackedpcj
Oh and the error message also says at the end(i cut it out before):

Not configured to listen on any interfaces!
Hum, so try this:

/usr/sbin/dhcpd eth0

Rodrigo Otavio Paes de Barros Otaviano
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Setting up a DHCP server MasterCephus Linux - Newbie 9 06-26-2005 07:41 AM
Setting up a DHCP server w/ the server on a wireless network Ionexchange Linux - Wireless Networking 0 05-08-2004 10:56 AM
Setting up DHCP server. joshnya Linux - Networking 1 10-12-2003 03:15 PM
Setting up a dhcp server PlatinumRik Linux - Networking 4 05-22-2003 01:50 AM
Setting up a DHCP Server bselzler Linux - Networking 2 08-07-2001 04:28 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 05:31 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration