I've turned on Internet Sharing on MacOS via WiFi.
How could I list all the connected IP addresses to the Internet Sharing?
(I need to connect to the RaspberryPi via SSH and I need to find out its IP address)
CodePudding user response:
Thanks to Joachim's comment, I found a proper solution for my usecase. I'm currently on MacOS Big Sur and the solution was a following command:
cat /private/var/db/dhcpd_leases
When I connect a raspberry, the raspberry IP address can be found at the top.
Here is an example of the file:
{
name=raspberrypi
ip_address=192.168.2.8
hw_address=1,e4:5f:1:68:25:58
identifier=1,e4:5f:1:68:25:58
lease=0x618d916c
}