> For the complete documentation index, see [llms.txt](https://fashaun.gitbook.io/gw-feature/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://fashaun.gitbook.io/gw-feature/dnsmasq_251.md).

# dnsmasq 2.51

**For DNS usage**

Debug by run program in foreground

Generally in Linux .

* We can add internal din \\/etc\\/hosts.dns, \\/etc\\/hosts by ($(dnsmasq -H ${file\_path}))
* OR it will reference the \\/etc\\/resolv.conf

**For DHCP server usage**

```
DMSMASQ_CMD=/sbin/dnsmasq
DNSMASQ_DNS_PARAM="--port=0  --bind-interfaces -i wapm --dhcp-script=/ramfs/bin/dhcpdCallBack.sh --pid-file=/var/run/dnsmasq-wapm.pid --conf-file=/etc/dnsmasq-wapm.conf -5 -K --log-facility=/dev/null"

* kill -TERM $(< ${DNSMASQ_PID_FILE})
* rm ${DNSMASQ_PID_FILE}

$DMSMASQ_CMD $DNSMASQ_DNS_PARAM
```
