LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 08-08-2007, 06:02 AM   #1
soroccoheaven
Member
 
Registered: Jul 2007
Distribution: mandrake Mandriva Redhat CentOS Slackware
Posts: 221

Rep: Reputation: 30
dhcp server configueation


hi,
I have configured DHCP on mandriva and having a doubt about the config.
As there is nothing about the ethernet which will act as dhcp server (provide IP )
Say ..i am having two NIC one with 192.168.2.2 static IP, for Internet access and other in with 192.168.3.1 static IP and using IP forwarding ..now when i configured the dhcp server which eth is going to serve as dhcp ?..i am using 192.168.3.0/24 network in my dhcpp.conf
with 192.168.3.1 as default gateway and using my ISP's dns .
( This is because i am getting following messages in my var/log/messages ..

Aug 8 16:26:33 server1 dhcpd: Not searching LDAP since ldap-server, ldap-port and ldap-base-dn were not specified in the config file
Aug 8 16:26:33 server1 dhcpd: Wrote 0 deleted host decls to leases file.
Aug 8 16:26:33 server1 dhcpd: Wrote 0 new dynamic host decls to leases file.
Aug 8 16:26:33 server1 dhcpd: Wrote 0 leases to leases file.
Aug 8 16:26:33 server1 dhcpd:
Aug 8 16:26:33 server1 dhcpd: No subnet declaration for eth0 (192.168.2.2).
Aug 8 16:26:33 server1 dhcpd: ** Ignoring requests on eth0. If this is not what
Aug 8 16:26:33 server1 dhcpd: you want, please write a subnet declaration
Aug 8 16:26:33 server1 dhcpd: in your dhcpd.conf file for the network segment
Aug 8 16:26:33 server1 dhcpd: to which interface eth0 is attached. **
Aug 8 16:26:33 server1 dhcpd:
[root@server1 ~]#

As you can see it is asking subnet for eth0 but eth0 is connected to my access-point for internet access..eth1 is the ethernet which should delever the IP's to the pc's connected to the switch.
pls. advice.
 
Old 08-08-2007, 06:26 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
You can use
Code:
/usr/sbin/dhcpd eth1
so dhcpd uses only eth1.
You may also edit your dhcpd startup script accordingly.
 
Old 08-08-2007, 06:37 AM   #3
soroccoheaven
Member
 
Registered: Jul 2007
Distribution: mandrake Mandriva Redhat CentOS Slackware
Posts: 221

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by bathory
You can use
Code:
/usr/sbin/dhcpd eth1
so dhcpd uses only eth1.
You may also edit your dhcpd startup script accordingly.
i am not able to understand will you pls make it little clear ..
 
Old 08-08-2007, 07:14 AM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
I'm, not familiar with Mandriva startup scripts, but I guess there are under /etc/init.d, or /etc/rc.d.
For testing, stop the service and run manually the command I gave you. If that works, kill the dhcpd daemon and then look there for a file named dhcpd or similar in the above locations and edit it (after making a backup first) so the line that contains "/usr/sbin/dhcpd" becomes "/usr/sbin/dhcpd eth1"
 
Old 08-08-2007, 07:30 AM   #5
TylerD75
Member
 
Registered: Aug 2004
Location: Norway
Distribution: Gentoo
Posts: 96

Rep: Reputation: 18
I believe that warning is only informational.
What it means is that the dhcp server will NOT give out IPs to requests from the internet side (on the external interface).
So it shouldn't be a problem

From what I could understand your internet access is through eth0? (with ip 192.168.2.2)
The declaration of the external net (192.168.2.0) has no subnetmask defined in the dhcpd.conf, and thus has no idea of what broadcast address to use.
So the log message just states that it can not use eth0 for distributing ips (which is what you want, from what I can understand).
 
Old 08-08-2007, 11:56 AM   #6
soroccoheaven
Member
 
Registered: Jul 2007
Distribution: mandrake Mandriva Redhat CentOS Slackware
Posts: 221

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by TylerD75
I believe that warning is only informational.
What it means is that the dhcp server will NOT give out IPs to requests from the internet side (on the external interface).
So it shouldn't be a problem


From what I could understand your internet access is through eth0? (with ip 192.168.2.2)
The declaration of the external net (192.168.2.0) has no subnetmask defined in the dhcpd.conf, and thus has no idea of what broadcast address to use.
So the log message just states that it can not use eth0 for distributing ips (which is what you want, from what I can understand).
thaks to TylerD75 and bathory
Yeah.. you are right but when i gave subnet declaration for 192.168.2.0 networkin dhcp.conf (for testing only ) but i was getting the same error ....
i am not getting it right now ..any way my dhcp is working now ..i am geting IP from it no more prob..

Thanks
 
  


Reply



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
DHCP server and DHCP client in same box Eicos Linux - Networking 3 03-03-2007 01:28 PM
How To know if a host configured with DHCP has obtained IP address from DHCP server? Prassanta SUSE / openSUSE 1 06-29-2006 09:48 AM
eth0 ip assigned by dhcp , how would i know the ip address of the dhcp server where.. kublador Linux - Networking 14 05-16-2006 06:33 AM
how can a DHCP client get the DHCP server IP? AshesOfTime Linux - Networking 3 11-24-2004 06:50 AM
XP Pro Build 2600/sp1 v.1105 DHCP Client to Redhat 8.0 DHCP Server - Problems atomant Linux - Networking 5 06-28-2003 11:24 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 01:48 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