LinuxQuestions.org
Help answer threads with 0 replies.
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 03-25-2008, 01:54 PM   #1
sudoku
LQ Newbie
 
Registered: Mar 2008
Posts: 3

Rep: Reputation: 0
subneting + dhcp3


1st of all

One big HELLO to all and each of every member of this comunity (aka 1st post)

now here i go with my problem:

To put it on a slammer scale.. lets say i have like ... 3 machines

- 1 debian4 (server )
- 2 winxp (clients)

i want to use 3 subnets
- 1 for servers
- 2 for separate networks


so here i go

dhcp.conf:

PHP Code:
server-identifier 192.168.5.1;

ddns-update-style none;

autoritative;

log-facility local7;

option domain-name-servers 193.231.236.30;
option routers 192.168.5.1;

### 00:0c:29:29:19:e3
#00:0c:29:35:9b:88
#00:0c:29:54:ad:36

### ### ###

class "srvs" {
match option dhcp-client-identifier;
# lease limit 2;
}

class 
"wm1" {
match option dhcp-client-identifier;
# lease limit 2;
}

class 
"wm2" {
match option dhcp-client-identifier;
# lease limit 2;
}

subclass "srvs" 1:00:0c:29:29:19:e3;

subclass "wm1" 1:00:0c:29:35:9b:88;

subclass "wm2" 1:00:0c:29:54:ad:36;

shared-network s-b-t-{

subnet 192.168.5.0 netmask 255.255.255.224 # s
option broadcast-address 192.168.2.31;
default-
lease-time 120;
max-lease-time 120;
}

subnet 192.168.5.32 netmask 255.255.255.224 # b
option broadcast-address 192.168.2.63;
default-
lease-time 120;
max-lease-time 120;
}

subnet 192.168.5.64 netmask 255.255.255.224 # f
option broadcast-address 192.168.2.95;
default-
lease-time 120;
max-lease-time 120;
}

pool {
range 192.168.5.1 192.168.5.30;
allow members of "srvs";
deny members of "wm1";
deny members of "wm2";
deny unknown-clients;
}

pool {
range 192.168.5.33 192.168.5.62;
allow members of "srvs";
allow members of "wm1";
deny members of "wm2";
deny unknown-clients;
}

pool {
range 192.168.5.65 192.168.5.94;
allow members of "srvs";
deny members of "wm1";
allow members of "wm2";
deny unknown-clients;
}

syslog

PHP Code:
debianTST:~# tail -n 20 /var/log/syslog
Mar 13 01:46:42 debianTST dhcpdCopyright 2004-2006 Internet Systems Consortium.
Mar 13 01:46:42 debianTST dhcpdAll rights reserved.
Mar 13 01:46:42 debianTST dhcpd: For infoplease visit ]
Mar 13 01:46:42 debianTST dhcpdInternet Systems Consortium DHCP Server V3.0.4
Mar 13 01
:46:42 debianTST dhcpdCopyright 2004-2006 Internet Systems Consortium.
Mar 13 01:46:42 debianTST dhcpdAll rights reserved.
Mar 13 01:46:42 debianTST dhcpd: For infoplease visit 
Mar 13 01
:47:15 debianTST dhcpdInternet Systems Consortium DHCP Server V3.0.4
Mar 13 01
:47:15 debianTST dhcpdCopyright 2004-2006 Internet Systems Consortium.
Mar 13 01:47:15 debianTST dhcpdAll rights reserved.
Mar 13 01:47:15 debianTST dhcpd: For infoplease visit 
Mar 13 01
:47:15 debianTST dhcpdInternet Systems Consortium DHCP Server V3.0.4
Mar 13 01
:47:15 debianTST dhcpdCopyright 2004-2006 Internet Systems Consortium.
Mar 13 01:47:15 debianTST dhcpdAll rights reserved.
Mar 13 01:47:15 debianTST dhcpd: For infoplease visit 
Mar 13 01
:47:15 debianTST dhcpdInternet Systems Consortium DHCP Server V3.0.4
Mar 13 01
:47:15 debianTST dhcpdCopyright 2004-2006 Internet Systems Consortium.
Mar 13 01:47:15 debianTST dhcpdAll rights reserved.
Mar 13 01:47:15 debianTST dhcpd: For infoplease visit 
Mar 13 01
:47:15 debianTST dhcpdWrote 0 leases to leases file.
debianTST:~
dhcp.leases

PHP Code:
debianTST:~# tail -n 20 /var/lib/dhcp3/dhcpd.leases
# All times in this file are in UTC (GMT), not your local timezone. This is
# not a bug, so please don't ask about it. There is no portable way to
# store leases in the local timezone, so please don't request this as a
# feature. If this is inconvenient or confusing to you, we sincerely
# apologize. Seriously, though - don't ask.
# The format of this file is documented in the dhcpd.leases(5) manual page.
# This lease file was written by isc-dhcp-V3.0.4

debianTST:~

/etc/network/interfaces

PHP Code:
DebWM:~# tail -n 20 /etc/network/interfaces
iface eth0 inet static
        
address 192.168.1.10
        netmask 255.255.255.0
        network 192.168.1.0
        broadcast 192.168.1.255
        gateway 192.168.1.1
        
# dns-* options are implemented by the reseolconf package, if installed
        
dns-nameserver 193.231.236.30

# The secodary eth
auto eth1
#iface eth1 inet dhcp
iface eth1 inet static
        
address 192.168.5.1
        netmask 255.255.255.224
        network 192.168.5.0
        broadcast 192.168.5.31
        
#gateway 192.168.1.1
        # dns-* options are implemented by the reseolconf package, if installed
        #dns-nameserver 193.231.236.30
DebWM:~

in all this text somethin is wrong for sure.. couse my clients would not take ip's unless i tell the conf file that i want to allow unknowwn-clients;

si mi mind suspects the class/subclass syntax of being uncomplete somehow..

i am sincerly expecting replyes..

10x in advance..
 
Old 03-25-2008, 05:51 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
well you haven't actually listed any known clients. e.g.
Code:
group {
  filename "Xncd19r";
  next-server ncd-booter;

  host ncd1 { hardware ethernet 0:c0:c3:49:2b:57; }
  host ncd4 { hardware ethernet 0:c0:c3:80:fc:32; }
  host ncd8 { hardware ethernet 0:c0:c3:22:46:81; }
}
 
Old 03-28-2008, 08:16 AM   #3
sudoku
LQ Newbie
 
Registered: Mar 2008
Posts: 3

Original Poster
Rep: Reputation: 0
10x for youre reply mate, i solved my problem ....
there are known clients defined in the subclass statements.... what is wrong there is that every pool end's with deny unknown clients;, and by default unknown clients are denied.. so.. that statement should be erased and everyting works well.. i have to test alltough is some machine is staticaly setted with an ip from one of the pools how the subnet rescts...

tnx again.. good luck
 
Old 03-28-2008, 08:27 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
huh? that makes no sense... what else did you think "deny unknown clients" meant??

Last edited by acid_kewpie; 03-29-2008 at 01:31 PM.
 
Old 03-29-2008, 12:29 PM   #5
sudoku
LQ Newbie
 
Registered: Mar 2008
Posts: 3

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by acid_kewpie View Post
huh? that makes no sense... what else did you think "deny known clients" meant??

when i think at clients from classes i think of them like they are known clients...

unknown clients i think that theyarn't defined anywhere... .. so...
 
Old 03-29-2008, 01:32 PM   #6
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
heh, managed to miss the "un" out there in "unknown"... kinda critical typo methinks...
 
Old 06-23-2010, 02:15 PM   #7
fdelval
Member
 
Registered: Feb 2010
Posts: 107

Rep: Reputation: 15
is it necessary to connect each lan to a separated interface, or can you connect all pc's to the same router?
 
Old 06-23-2010, 03:03 PM   #8
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 don't understand what you're asking there. If you have different subnets then you either need to listen directly on each subnet or have a DHCP relay agent on each subnet if they are not directly connected.
 
  


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
Setup dhcp3 realnoname Linux - Networking 4 03-21-2008 02:41 PM
dhcp3 server config geden Debian 1 03-17-2006 08:31 PM
DHCP3 Mac Filter linx win Debian 2 07-28-2005 11:50 AM
advance ip subneting sqn General 0 03-25-2004 07:08 AM
dhcp3-client ph33r Linux - Networking 1 05-19-2002 10:24 PM

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

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