You are not logged in.

#1 2020-04-17 12:24:24

Tropicananass
Member
Registered: 2020-04-17
Posts: 2

PXE : dnsmasq dhcp proxy not answering [SOLVED]

Hi,
I'm currently trying to run a "pxe server" under archlinux. As I can't disable or configure correctly the DHCP of my internet provider router, I wanted to use dnsmasq as DHCP proxy for sending tftp informations.
I followed this doc to configure dnsmasq https://wiki.archlinux.org/index.php/Dn … FTP_server, but I didn't saw any answer to the "DHCP Discover" by dnsmasq. I tried reproduce the config on virtualbox with a vm under arch acting as server and an other vm trying to make pxe boot from it.

First, with dnsmasq acting as only dhcp on the network, it worked well.
etc/dnsmasq.conf :

# disable dns
port=0

# dhcp
log-dhcp
interface=enp0s8
bind-dynamic

# gateway
dhcp-option=3,192.168.56.1

# dynamic range
dhcp-range=192.168.56.101,192.168.56.150,12h
dhcp-boot=netboot.xyz.kpxe

# tftp server
enable-tftp
tftp-root=/srv/tftp

When I try to enable virtualbox host-network dhcp and tell dnsmasq to act as proxy dhcp :
/etc/dnsmasq.conf :

# disable dns
port=0

# dhcp
log-dhcp
interface=enp0s8
bind-dynamic

# proxy dhcp
dhcp-range=192.168.56.2,proxy
dhcp-boot=netboot.xyz.kpxe

# tftp server
enable-tftp
tftp-root=/srv/tftp

"journalctl -efu dnsmasq" output :

Apr 17 13:32:30 arch-nw dnsmasq[662]: started, version 2.81 DNS disabled
Apr 17 13:32:30 arch-nw systemd[1]: Stopping A lightweight DHCP and caching DNS server...
Apr 17 13:32:30 arch-nw dnsmasq[660]: dnsmasq: syntax check OK.
Apr 17 13:32:30 arch-nw dnsmasq[662]: compile time options: IPv6 GNU-getopt DBus no-UBus i18n IDN2 DHCP DHCPv6 no-Lua TFTP conntrack ipset auth DNSSEC loop-detect inotify dumpfile
Apr 17 13:32:30 arch-nw dnsmasq[662]: DBus support enabled: connected to system bus
Apr 17 13:32:30 arch-nw dnsmasq-dhcp[662]: DHCP, proxy on subnet 192.168.56.2
Apr 17 13:32:30 arch-nw dnsmasq-dhcp[662]: DHCP, sockets bound exclusively to interface enp0s8
Apr 17 13:32:30 arch-nw dnsmasq-tftp[662]: TFTP root is /srv/tftp
Apr 17 13:32:30 arch-nw systemd[1]: dnsmasq.service: Succeeded.
Apr 17 13:32:30 arch-nw systemd[1]: Stopped A lightweight DHCP and caching DNS server.
Apr 17 13:32:30 arch-nw systemd[1]: Starting A lightweight DHCP and caching DNS server...
Apr 17 13:32:30 arch-nw systemd[1]: Started A lightweight DHCP and caching DNS server.
Apr 17 13:32:48 arch-nw dnsmasq-dhcp[662]: 674129955 available DHCP subnet: 192.168.56.2/255.255.255.0
Apr 17 13:32:48 arch-nw dnsmasq-dhcp[662]: 674129955 vendor class: PXEClient:Arch:00000:UNDI:002001
Apr 17 13:32:50 arch-nw dnsmasq-dhcp[662]: 690907171 available DHCP subnet: 192.168.56.2/255.255.255.0
Apr 17 13:32:50 arch-nw dnsmasq-dhcp[662]: 690907171 vendor class: PXEClient:Arch:00000:UNDI:002001
Apr 17 13:32:54 arch-nw dnsmasq-dhcp[662]: 707684387 available DHCP subnet: 192.168.56.2/255.255.255.0
Apr 17 13:32:54 arch-nw dnsmasq-dhcp[662]: 707684387 vendor class: PXEClient:Arch:00000:UNDI:002001
Apr 17 13:33:02 arch-nw dnsmasq-dhcp[662]: 724461603 available DHCP subnet: 192.168.56.2/255.255.255.0
Apr 17 13:33:02 arch-nw dnsmasq-dhcp[662]: 724461603 vendor class: PXEClient:Arch:00000:UNDI:002001

I don't see any answer from dnsmasq using wireshark on the host or tcpdump on server machine ...

Am I missing something ?

Last edited by Tropicananass (2020-06-27 11:44:43)

Offline

#2 2020-06-27 11:43:53

Tropicananass
Member
Registered: 2020-04-17
Posts: 2

Re: PXE : dnsmasq dhcp proxy not answering [SOLVED]

I was definitively missing something !
The pxe service of dnsmasq was not enabled on my conf file. I just added the line :

pxe-service=net:#ipxe,x86PC, "splashtop by richud.com", netboot.xyz.kpxe

Not sure yet about the meaning of every fields, but my dhcp proxy started answering request and my pxe client could boot to netboot.xyz.kpxe !
I found my answer thanks to this page : https://www.richud.com/wiki/Network_iPX … s_PXE_BOOT , I hope this could help someone else !

Offline

Board footer

Powered by FluxBB