DHCP

From Indie IT Wiki
Jump to: navigation, search

Find DHCP Server On Network

sudo nmap --script broadcast-dhcp-discover -e <network-interface>

https://superuser.com/questions/750359/check-if-a-dhcp-server-existing-in-my-network-using-bash#1114078

sudo nmap -sU -p 67 --open 192.168.1.0/24

https://www.unix.com/ip-networking/171195-dhcp-server-discover.html

Monitor DHCP Traffic From Command Line

sudo tcpdump -i <network-interface> port 67 or port 68 -e -n

http://ask.xmodulo.com/monitor-dhcp-traffic-command-line-linux.html

HOWTO: VLANS

https://www.ossramblings.com/using-multiple-vlan-with-dhcp-ubuntu

https://community.spiceworks.com/topic/1331562-isc-dhcp-server-for-multiple-vlans

HOWTO: FIX: DNSMasq DHCP Server With UFW

 sudo ufw allow from any port 68 to any port 67 proto udp

HOWTO: List Leases On The Command Line

egrep "lease|hostname|hardware|\}" /var/lib/dhcp/dhcpd.leases

or

egrep "lease|hostname|hardware|\}" /var/lib/dhcpd/dhcpd.leases

Thanks - https://unix.stackexchange.com/questions/91799/command-to-list-assigned-dhcp-addresses/

LTSP and Vendor Classes

set vendor-string = option vendor-class-identifier;

http://chrisjrob.com/2009/04/14/determine-vendor-class-identifier/#comment-3962986253