Dnsmasq 2.80 no ip obtain

Kernels & Hardware, configuring network, installing services

Dnsmasq 2.80 no ip obtain

Postby alberto280 » 2020-09-14 18:22

dnsmasq: started, version 2.80 cache size 150
dnsmasq: build options: IPv6 GNU-getopt DBus i18n IDN DHCP DHCPv6 non-Lua TFTP conntrack ipset auth DNSSEC loop-detect inotify dumpfile
dnsmasq-dhcp: DHCP, IP range 192.168.0.10 - 192.168.0.200, lease time 8h
dnsmasq: using server name 1.0.0.1 # 53
dnsmasq: using server name 1.1.1.1 # 53
dnsmasq: addresses / etc / hosts - 1 read


dnsmasq does not grant ip to the device I have this configuration:

no-resolv
interface=wlan0
dhcp-range=192.168.0.10,192.168.0.200,8h
dhcp-option=3,192.168.0.1
dhcp-option=6,192.168.0.1
server=1.1.1.1
server=1.0.0.1
log-queries
log-dhcp


in host this
/etc/host
192.168.0.1 gateway


in resolv this

# Generated by NetworkManager
nameserver 192.168.43.1



it still works but it doesn't give ip, do you have to put some ip to the interface or configure the ip in the network administrator?
If so, can you tell me how to do it?


Thanks
alberto280
 
Posts: 2
Joined: 2020-09-14 15:28

Re: Dnsmasq 2.80 no ip obtain

Postby sickpig » 2020-09-15 00:13

One way to do it is Debian's native ifup tool to bring up your nic with dhcp-client.
disable/mask systemd-resolved.service and NetworkManager.service.
Add
Code: Select all
supersede domain-name-servers 127.0.0.1;

to /etc/dhcp/dhclient.conf.

I use unbound and use the above to get localhost assigned as the nameserver in /etc/resolv.conf and it works error free.

further reading -
https://manpages.debian.org/buster/ifupdown/ifup.8.en.html
https://wiki.archlinux.org/index.php/dnsmasq
User avatar
sickpig
 
Posts: 474
Joined: 2019-01-23 10:34

Re: Dnsmasq 2.80 no ip obtain

Postby alberto280 » 2020-09-15 13:46

mi problem is the after run script hostapd "dnsmasq failed the address is already in use"
script mode monitor wlan2 but start dnsmasq dnsmasq failed the address is already in use
help
alberto280
 
Posts: 2
Joined: 2020-09-14 15:28

Re: Dnsmasq 2.80 no ip obtain

Postby sickpig » 2020-09-16 02:46

alberto280 wrote:"dnsmasq failed the address is already in use"

that is bound to happen if port 53 is already in use.
User avatar
sickpig
 
Posts: 474
Joined: 2019-01-23 10:34

Re: Dnsmasq 2.80 no ip obtain

Postby LostZimbo » 2020-09-17 07:56

Usually on a fresh start with dnsmaq and hostapd on my Espressobin Armbian, the service "systemd-resolved" is using port 53 preventing dnsmasq from starting. I remove this service "systemd disable systemd-resolved" and directly associate the DNS server in the systemd network file "/etc/systemd/network/10-wlan0" and that solves the problem.
LostZimbo
 
Posts: 4
Joined: 2020-09-15 11:37


Return to System configuration

Who is online

Users browsing this forum: No registered users and 10 guests

fashionable