[Dnsmasq-discuss] dhcp unknown vs. known

Mogens Melander mogens at fumlersoft.dk
Mon Aug 27 14:27:47 BST 2007


Hi all.

I'm trying to get dnsmasq to handle 2 dhcp-ranges. One for
MAC addresses i know, and another for MAC's i dont know.

I want to assign 192.168.1.8 - 192.168.1.16 to unknown MAC's and
192.168.1.18 - 192.168.1.200 to known MAC's.

My idea was to redirect all unknown http trafic to a local web-server,
where users assigned a login/password can register, and a script can
generate a config file with a dhcp-host entry for that MAC.

I did "kinda" work. Using and old win 98 labtop i got assigned
an ip in the unknown range. After creation of dhcp-host in a file,
a ipconfig /renew gave me an ip in known range. I'm unable to get
out of the known segment. Even when removing the config file for
this MAC, dnsmasq continues to assing the ip the client ask for.

And, i can't get the redirection to work either.

Hope this rant make sense to someone.

I'm shure i've seen this setup somewhere, but i just can't find
that site again.

Hints, ideas are more than welcome :)

Files in /etc/dnsmasq/hosts containing entries like:

dhcp-host=id:00:60:08:03:07:30,192.168.1.9

/etc/dnsmasq.conf

bogus-priv
filterwin2k
local=/localnet/wifi-net/wifi-unknown/wifi-known/
address=/wifi-unknown/192.168.1.2
user=daemon
group=daemon
interface=eth0
listen-address=192.168.1.2
no-dhcp-interface=eth1
bind-interfaces
expand-hosts
domain=example.com
dhcp-range=wifi-unknown,192.168.1.8,192.168.1.17,0
dhcp-range=wifi-known,192.168.1.18,192.168.1.250,6h
dhcp-leasefile=/etc/dnsmasq/dnsmasq.leases
log-queries
log-dhcp
conf-dir=/etc/dnsmasq/hosts


-- 
Later

Mogens Melander
+45 40 85 71 38
+66 870 133 224



-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.




More information about the Dnsmasq-discuss mailing list