LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
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 09-06-2012, 12:04 AM   #1
varan
LQ Newbie
 
Registered: Sep 2012
Posts: 22

Rep: Reputation: Disabled
DHCP server


i am new use of centOs and i have a problem regarding dhcp server i will mention full detail so it will be helpful for you all to guide me
i have an internet in organization from private address as there is alos a centOs already running in the organizaiton
i have 2 network cards on the system and my ip on eth0 is 10.10.9.133
with 255.0.0.0 subnet
and i have give ip 10.10.29.1 to my eth1 card as a options routes as i have mention this ip in my dhcpd configuration file for my options routes so my cleint pc will get this as default gateway
here is my dhcp.conf file


subnet 10.10.0.0 netmask 255.0.0.0 {

# --- default gateway
option routers 10.10.29.1;
option subnet-mask 255.0.0.0;

option nis-domain "domain.org";
option domain-name "domain.org";
option domain-name-servers 10.10.29.1;

option time-offset -18000; # Eastern Standard Time
# option ntp-servers 192.168.1.1;
# option netbios-name-servers 192.168.1.1;
# --- Selects point-to-point node (default is hybrid). Don't change this unless
# -- you understand Netbios very well
# option netbios-node-type 2;

range dynamic-bootp 10.10.33.0 10.10.33.5;
default-lease-time 21600;
max-lease-time 43200;



afer this file i have restart dhcpd service it works fine and also chkconfig service to on dhcpd on all levels it also works fine

i connect my another pc to eth1 card as i want to run dhcp on it for test and then i will run squid but problem start when i get ip 10.10.33.5 and i want to ping this ip from my server error appears destionation host unreachable and from the system which get dhcp ip i want to ping my optios routes ip i-e 10.10.29.1 erros come ot request time out why this is so and if i change my network cables on server mean eth0 to eth1 and eth1 to eth0 ping commands work on both systems mean on client as well on server but after doing this internet on server vanish i also edit file
/etc/sysconfig/dhcpd
where i put
DHCPDARGS=
eth1
to listen on this card for dhcp but not works
i have also edited file /etc/sysconfig/dhcrelay bit it also not works
please let me know how i will fix this problem so my ping result work on both client and server so next i will run squid on server for net sharing on my client pc for practice.

Last edited by varan; 09-06-2012 at 12:48 AM.
 
Old 09-06-2012, 05:42 PM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
you're running a /8 netmask??? That's just plain ridiculous! Also ridiculous is having two separate NICS on the same subnet, don't do that, it's not correct, and leads to very broken environments.
 
Old 09-10-2012, 08:15 AM   #3
varan
LQ Newbie
 
Registered: Sep 2012
Posts: 22

Original Poster
Rep: Reputation: Disabled
what i will do know if i will change option routess and all other setting dhcpd error occurrs
 
Old 09-10-2012, 08:17 AM   #4
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
I'm sorry, I don't understand your comment there.
 
Old 09-10-2012, 08:40 AM   #5
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,842

Rep: Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308
just change it, show the settings and post also the error messages
 
Old 09-10-2012, 08:51 AM   #6
varan
LQ Newbie
 
Registered: Sep 2012
Posts: 22

Original Poster
Rep: Reputation: Disabled
subnet 150.150.0.0 netmask 255.255.0.0 {

# --- default gateway
option routers 150.150.29.1;
option subnet-mask 255.255.0.0;

option nis-domain "domain.org";
option domain-name "domain.org";
option domain-name-servers 150.150.29.1;

option time-offset -18000; # Eastern Standard Time
# option ntp-servers 192.168.1.1;
# option netbios-name-servers 192.168.1.1;
# --- Selects point-to-point node (default is hybrid). Don't change this unless
# -- you understand Netbios very well
# option netbios-node-type 2;

range dynamic-bootp 150.150.33.0 150.150.33.5;
default-lease-time 21600;
max-lease-time


i have made changes to my dhcpd.conf file as above shown and as soon as i saved them and service dhcpd start it shows FAILED
mean my dhcpd server not working
i have eth0 as discussed previous 10.10.9.133 with subnet 255.0.0.0
i have just question why this not work as now i have change my dhcpd server setting now what i give address to my 2nd nic
please help me out
 
Old 09-10-2012, 09:17 AM   #7
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
150.150.0.0/16?? That's another very very bizarre network choice, it's public for a start, so you can't use it on a private network at all.

If something has failed, check /var/log/messages for the reason why.

It's very hard to work out what you might actually want here at all, maybe a drawing of yoru network would be useful, and let us work out what you need from that? Why are you using 2 nics for a start? a normal DHCP server would have no use for this if you're only serving a single subnet.
 
Old 09-10-2012, 09:50 AM   #8
varan
LQ Newbie
 
Registered: Sep 2012
Posts: 22

Original Poster
Rep: Reputation: Disabled
first of all i am realy thankful for kind reply
ok i want to clear it all so easy for me to understand as well i want to tell you so it will be easy for you to reply
i want to make a dhcpd server then i want to make a squid so i can make my own lab of single pc or may be 5 so what i do for that i have 2 nics for the purpose that on eth0 i will my internet from organization and from eth1 my lab pc local requests come to my server so i will run internet on my lab pcs from my server thats my scenario is
kindly tell me what sequence i will use for dhcpd server

Last edited by varan; 09-10-2012 at 09:51 AM. Reason: later came in mind
 
  


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
Baffling DNS from a DHCP server problem. Appears to be ignoring dhcp.conf royce2020 Linux - Networking 1 02-16-2010 12:40 PM
Problem on acquiring IP addr. on client from dhcp server through dhcp relay server haariseshu Linux - Server 5 08-10-2009 01:20 AM
Instead of Router DHCP Server, Pass DHCP Server control to Slackware orbit Slackware 6 05-11-2009 02:00 AM
How to bypass DHCP of IPCop relay to Windows DHCP Server gclimbo Linux - Software 3 06-08-2008 08:30 PM
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 - Networking

All times are GMT -5. The time now is 06:34 PM.

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