1

Temat: DHCP flooding

Zauważyłem na na routerze problem opisany tutaj

https://wiki.openwrt.org/doc/howto/dhcp.dnsmasq

"log continuously filled with DHCPINFORM / DHCPACK

Windows 7 among others ask for proxy settings using DHCP. The issue is that they do not stop asking until they have received an answer. This results in that the log contains a lot information about these requests, an example can be found below (thanks for http://wiki.excito.org for the info).

Jul 1 06:34:09 MorganB3 dnsmasq-dhcp[1638]: DHCPINFORM(br0) 10.69.10.59 00:23:14:c5:33:fc
Jul 1 06:34:09 MorganB3 dnsmasq-dhcp[1638]: DHCPACK(br0) 10.69.10.59 00:23:14:c5:33:fc MorgansVaioF12Z

To solve this, edit /etc/dnsmasq.conf and add the following lines:

# This will tell DHCP clients to not ask for proxy information
# Some clients, like Windows 7, will constantly ask if not told NO
dhcp-option=252,"\n"

and restart dnsmasq with /etc/init.d/dnsmasq restart
"

Problem jest jedna taki że

https://wiki.openwrt.org/doc/uci/dhcp

"Using plain dnsmasq.conf

It is possible to mix the traditional /etc/dnsmasq.conf configuration file with the options found in /etc/config/dhcp.

The dnsmasq.conf file does not exist by default but will be processed by dnsmasq on startup if it is present. Note that options in /etc/config/dhcp take precendence over dnsmasq.conf since they are translated to command line arguments.

You can have dnsmasq execute a script on every action:

dhcp-script=/sbin/action.sh"

dlatego wolałbym dodać wpis dhcp-option=252,"\n" do /etc/config/dhcp jednak nie wiem jak poprawie powinien on wyglądać w tym pliku
Czy wpis
list dhcp_option 252,"\n"
zgodnie z tym
https://dev.openwrt.org/ticket/19348
będzie prawidłowy ?

2

Odp: DHCP flooding

Dodanie w LUCI wpisu w polu "Opcje DHCP" przypisanego do interfejsu
spowodowało wygenerowanie wpisów w /etc/config/dhcp

config dhcp 'lan'
    option interface 'lan'
    option start '100'
    option limit '150'
    option leasetime '12h'
    list dhcp_option 'dhcp-option=252,"\n"'

Czy to jest prawidłowa konfiguracja ?

3

Odp: DHCP flooding

Tak to wygląda: http://eko.one.pl/?p=openwrt-konfigurac … lientwdhcp

więc

list dhcp_option 252,"\n"

jak już.

Masz niepotrzebny router, uszkodzony czy nie - chętnie przygarnę go.

4

Odp: DHCP flooding

Więc błąd jest w LUCI czy należy w jakiś szczególny sposób wpisać tą dodatkową opcję w GUI aby pojawiła się prawidłowa składnia w /etc/config/dhcp ?

5

Odp: DHCP flooding

Jak błąd? Po prostu wpisałeś wartość inaczej.

Masz niepotrzebny router, uszkodzony czy nie - chętnie przygarnę go.

6

Odp: DHCP flooding

Wpisałem
dhcp-option=252,"\n"
w pliku /etc/config/dhcp pojawiło się
list dhcp_option 'dhcp-option=252,"\n"'

7

Odp: DHCP flooding

No a dlaczego nie wpisałeś samego 252,"\n"  skoro same "opcje dhcp" robią właśne dhcp_option?

Masz niepotrzebny router, uszkodzony czy nie - chętnie przygarnę go.