I am looking for a command to discover all hosts on the same LAN segment from a host with unassigned IP, default gateway, and subnet. I know there's ping 255.255.255.255
but that operates at layer 3 and requires the sender have an IP address. Is there a simple Windows and Linux layer-2-only command to send a MAC broadcast FF:FF:FF:FF:FF:FF
?
Can this be done in 1 line, e.g. without arp
ping every possible IP address? I also tried the nmap broadcast-ping script but that doesn't work on my Linux hosts. )
Knowing the ARP packet structure helps.