Karl ([info]illubrious) wrote in [info]linux,
@ 2003-06-21 18:40:00
Previous Entry  Add to memories!  Tell a Friend!  Next Entry
DHCPd
I was pondering a few things about my local internal networks's dhcpd configuration, and I have two rather simple questions for anyone familar with the software that has a moment.

Question one; is there a way to assign ips based upon mac adresses? Simply put I want the mac adress ip assignment process for orginization in relation to which machine is which. I do not run bind or any other internal dns software on my network, therefore, I have to remeber machines by ip (I only have six to keep track of, should not be hard).

Question two; I am purchasing a wifi router tonight and I want place it behind my routing computer. Thus becuase of that topology the device's built in ip scheme will be nullified because it will be placed on 10.x.x.x and not the 192.168.x.x schema ussually reserved for consumer based routers (like my linksys).So how would I go about the assignment of a unique ip for the wifi router via hdcpd?

Thanks in advance. If you want to throw any verbose documentation my way that would be great as well. No need to leech of anyone when I can just rtfm =-D



(Post a new comment)


[info]alien88
2003-06-21 03:58 pm UTC (link)
man dhcpd.conf

(Reply to this)


[info]drchase
2003-06-21 04:39 pm UTC (link)
You can configure the network address on Linksys Wifi routers to fit your 10.x.x.x schema.

(Reply to this)


[info]anthraxfairy
2003-06-21 05:28 pm UTC (link)
if your going to the trouble to setup dhcpd to assign "dynamic" ip address based on mac addresses.. why don't you just set those systems as static?

(Reply to this) (Thread)


[info]illubrious
2003-06-21 09:09 pm UTC (link)
Good point. Becuase I have only four systems
on my network that need static, and three that
do not and will be assigned a new ip each time.
I guess I could make those staic as well
because there is no need to have them as dynamic.
I guess it was acham's razor on that, no need
to over complicate things. Heh, as I think about it that was pretty obvious as well. Thanks again.

(Reply to this) (Parent)

DHCPD 4 U
[info]exileinparadise
2003-06-21 05:33 pm UTC (link)
For your question one:

DHCP is a super-set of the BOOTP protocol which assigns fixed IPs by MAC, which means DHCP can do that as well.

Add a block like this after the header blocks of your dhcpd.conf will allow fixed IP assignments to dhcpd clients:


host hostname {
hardware ehternet 00:01:02:0a:0b:0c;
fixed-address IPX.Y.Z.A;
}


That client will still honor lease times and renewals.

Be aware my example is from memory, and the manpage for dhcpd.conf can fix anything I am mistyping here or give you lots you could add.

This can also pass kickstart filenames to booting kickstart clients by adding a
filename "/kickstart"; line to the block above.

For question 2:
Yes, your WiFi access point should still be able to DHCP an address... check its manual to be sure, but my D-Link does.... so I knowit can be done cheaply, leading me to think its a standard feechur.

It did take some twiddling bits in the DLink AP manager to get it all working well, so expect some experimentation at first.

(Reply to this) (Thread)

Re: DHCPD 4 U
[info]illubrious
2003-06-21 09:19 pm UTC (link)
Whoa! Thanks for all of the information. I
was not expecting someone to answer my questions,
just inform me if it could be done (as that would
be leeching, when I could find out myself). However, thank you much the same for your very
detailed compitant explicit answer! I will apply
it to my problem along with the manual.

(Reply to this) (Parent)

DHCP
[info]al3k
2003-06-22 12:10 pm UTC (link)
and what if I want to assign IPs only to some particular MAC addresses ,not "IP per MAC" ,but a pool of IPs for a pool of MAC ?
anybody have managed to setup it ?

(Reply to this) (Parent)(Thread)


[info]illubrious
2003-06-22 12:52 pm UTC (link)
I can't say that I comprehend your question in full.
What exactly is a "pool of mac"? Unless you wanted to do a range of mac's I guess you could think of that as a pool. However, mac #s are burned onto the rom of the card - you would need to get something like seawolf in bsd, or tell ifconfig to assign a new one at boot time.

(Reply to this) (Parent)(Thread)


[info]al3k
2003-06-23 01:33 pm UTC (link)
Hi ! Yes,by "pool of MAC" i meant range of MACs.
I will try to describe my problem more briefly.
I got people with laptops ,they travel all the time .
I got MACs of their ethernet adapters .
so i want my DHCP to give out IPs only to these particular MACs
and I don't want to make it with "fixed-name" otherwise I can go to static IPs.
I have read that it is possible with ISC DHCPd ,but didn't find any exemples of implamantations :(

(Reply to this) (Parent)(Thread)


[info]illubrious
2003-06-23 02:57 pm UTC (link)
So yoiu want to give out ips only to people with those particular pool of mac adresses? Comcast as well as alot of other cable companies do this. However, mac adresses where only meant to be used as a means of identification - not authentication. It is really easy to change your mac adress via software. Infact the redhat network scripts (/etc/rc.d/network ?) allow you to change it on boot time, as well as the ifconfig command. However, I do not get a feel that is what you are asking. I can not really make out your explination all that well. Sorry.

(Reply to this) (Parent)

Not I
[info]exileinparadise
2003-06-23 03:16 pm UTC (link)
I haven't really considered it.
It sounds like you want 2 different DHCP pools... one "first come first served" standard DHCP, then a limited DHCP pool for a small pool of MACs.

I have only done the two major ways... free for all random assign, or pass a specific IP to a specific MAC...

Not sure I can see why you need to have a set of macs only get a small set of random DHCP... why can you just assign a fixed IP per MAC?

(Reply to this) (Parent)


Create an Account
Forgot your login or password?
Login w/ OpenID
English • Español • Deutsch • Русский…