You can make any changes you like by using a custom config file
https://github.com/RMerl/asuswrt-merlin/wiki/Custom-config-files
pc_replace "dhcp-lease-max=253" "# option removed" $CONFIG
replace with a leading # to comment it out....Thanks. But it seems only "replace", "insert", "append", no delete option.
I want to comment it out with below command. But it has no effect.You could replace a string with spaces or make it a comment. i.e.
Code:pc_replace "dhcp-lease-max=253" "# option removed" $CONFIG
pc_replace "dhcp-option=28" "" $CONFIG
Thanks for your reply. Tried and no effect...Still got Option28Try this:
And your script (/jffs/scripts/dnsmasq.postconf). What are you using to create the script, vi?show your config file.
And your script (/jffs/scripts/dnsmasq.postconf). What are you using to create the script, vi?
You have rebooted the router?
#!/bin/sh
CONFIG=$1
source /usr/sbin/helper.sh
pc_append "dhcp-option-force=125,00:00:00:00:14:02:06:48:47:57:2d:43:54:0a:02:00:00:0b:02:00:55:0d:02:00:2e" $CONFIG
pc_replace "cache-size=1500" "cache-size=9999" $CONFIG
pc_replace "dhcp-option=28" "" $CONFIG
I think there is no option28 in my config file. It's not my custom option. Seems it's dnsmasq default option. When enable dnsmasq, option28 will be added.Try to modify dnsmasq-postconf with no comment out string. Do you have dhcp-option=28 in your dnsmasq config file ?
You can't edit a string that doesn't exist!I think there is no option28 in my config file. It's not my custom option. Seems it's dnsmasq default option. When enable dnsmasq, option28 will be added.
Correct.Seems it's dnsmasq default option. When enable dnsmasq, option28 will be added.
By default, dnsmasq sends some standard options to DHCP clients, the netmask and broadcast address are set to the same as the host running dnsmasq
Yes, I also find this. So we can't remove this broadcast address option?
No.So we can't remove this broadcast address option?
It sounds like a bug because dnsmasq is giving out the correct address, unless you have a non-standard network.One of my device will use this broadcast address and it will cause device no internet access. I don't know whether it's device fireware bug.
Actually, it looks like I was wrong! The dnsmasq CHANGELOG for release 2.6 says this:So we can't remove this broadcast address option?
So it looks like all you need isChanged the semantics of argument-less dhcp-options for the default-setting ones, ie 1, 3, 6 and 28. Now, doing eg, dhcp-option=3 stops dnsmasq from sending a default router option at all. Thanks to Scott Emmons for pointing out that this is useful.
dhcp-option=28
Thanks ColinTaylor. I will try it when back home.Actually, it looks like I was wrong! The dnsmasq CHANGELOG for release 2.6 says this:
So it looks like all you need isCode:dhcp-option=28
Amesome!!! It works. Thanks a lot.Actually, it looks like I was wrong! The dnsmasq CHANGELOG for release 2.6 says this:
So it looks like all you need isCode:dhcp-option=28
Welcome To SNBForums
SNBForums is a community for anyone who wants to learn about or discuss the latest in wireless routers, network storage and the ins and outs of building and maintaining a small network.
If you'd like to post a question, simply register and have at it!
While you're at it, please check out SmallNetBuilder for product reviews and our famous Router Charts, Ranker and plenty more!