ip neigh
whose MAC is thatip neigh lists what the host has learned about the machines on its own segment: which MAC answers for which IP address, and how fresh that answer is. It is the ARP cache and its IPv6 equivalent in one table, and it is where on-link delivery succeeds or fails.
Routing picks the next hop by IP — but the frame is addressed to a MAC from this table.
At the terminal
Read the session first, then the notes: each numbered line in the output is answered by the note with the same number.
What the numbered lines are telling you
The gateway at 192.168.1.1 answered within the last few tens of seconds. lladdr is the link-layer address frames for it are sent to.
The entry has not been confirmed lately. The kernel will still use it and quietly re-check it the next time a packet goes that way.
There is no lladdr because no host claimed 192.168.1.90. The machine is off, on another VLAN, or the address is simply unused.
The MAC matches the first line: this is the gateway seen through neighbour discovery. "router" records that it sent router advertisements.
Switches
A switch changes how the command behaves. These are the ones used day to day; man ip lists the rest. Single-letter switches can usually be joined, so -l -a may be written -la.
-4- Show only IPv4 neighbours — the ARP table.
-6- Show only IPv6 neighbours — the NDP table.
-s- Add statistics: how long ago each entry was used and confirmed.
-c- Colour the output.
-j- Print JSON, for scripts.
Variations worth knowing
The same tool, pointed at a narrower question. These four cover most of what it is reached for day to day.
ip neigh show dev eth0Only the neighbours learned on one interface.
ip neigh flush dev eth0Empties the cache for that interface, forcing every mapping to be re-learned. The first thing to try after a device was swapped.
ip neigh replace 192.168.1.1 lladdr 3c:84:6a:12:f0:01 dev eth0 nud permanentPins the gateway's MAC so no ARP reply can change it.
ip -s neighAdds how long ago each entry was used, confirmed and updated.
In cybersecurity
ARP has no authentication: a host believes whichever reply arrived last. This table is where that trust is recorded, and where its abuse shows up.
A neighbour that answers for the gateway's IP inserts itself into every conversation leaving the segment.
The same lladdr against the gateway and against another host is the classic signature of a poisoned cache.
Note the legitimate value once. A different one tomorrow is either new hardware or an interception.
A permanent entry for the gateway cannot be overwritten by a forged reply — practical on servers, tedious on laptops.
Dynamic ARP inspection and DHCP snooping drop forged replies before any host sees them. The real fix is in the switch.
Neighbour discovery can be spoofed just as ARP can. RA guard and ND inspection are the equivalents.