I know this question has been asked many times, however I still could not find a solution to my problem. I'm using an Ethernet cable to connect to the pi, however when I use nmap to find the ip address, it only shows the ip of my laptop. The pi has a static ip address, I tried to connect through ssh, but it waits for a while and then fails due to time out. I tried to change the IPv4 Method to share with others and this is what I get when I run ifconfig in the terminal:
br-1a1e47adcf33 Link encap:Ethernet Hardware Adresse 02:42:34:71:17:13 inet Adresse:172.18.0.1 Bcast:0.0.0.0 Maske:255.255.0.0 UP BROADCAST MULTICAST MTU:1500 Metrik:1 RX-Pakete:0 Fehler:0 Verloren:0 Überläufe:0 Fenster:0 TX-Pakete:0 Fehler:0 Verloren:0 Überläufe:0 Träger:0 Kollisionen:0 Sendewarteschlangenlänge:0 RX-Bytes:0 (0.0 B) TX-Bytes:0 (0.0 B) docker0 Link encap:Ethernet Hardware Adresse 02:42:9f:82:c6:d0 inet Adresse:172.17.0.1 Bcast:0.0.0.0 Maske:255.255.0.0 UP BROADCAST MULTICAST MTU:1500 Metrik:1 RX-Pakete:0 Fehler:0 Verloren:0 Überläufe:0 Fenster:0 TX-Pakete:0 Fehler:0 Verloren:0 Überläufe:0 Träger:0 Kollisionen:0 Sendewarteschlangenlänge:0 RX-Bytes:0 (0.0 B) TX-Bytes:0 (0.0 B) lo Link encap:Lokale Schleife inet Adresse:127.0.0.1 Maske:255.0.0.0 inet6-Adresse: ::1/128 Gültigkeitsbereich:Maschine UP LOOPBACK RUNNING MTU:65536 Metrik:1 RX-Pakete:11707 Fehler:0 Verloren:0 Überläufe:0 Fenster:0 TX-Pakete:11707 Fehler:0 Verloren:0 Überläufe:0 Träger:0 Kollisionen:0 Sendewarteschlangenlänge:1000 RX-Bytes:9581079 (9.5 MB) TX-Bytes:9581079 (9.5 MB) wlp2s0 Link encap:Ethernet Hardware Adresse 28:16:ad:a7:e7:a2 inet Adresse:10.42.0.1 Bcast:10.42.0.255 Maske:255.255.255.0 inet6-Adresse: 2003:85:ce44:7735:4029:15a9:c486:5b62/64 Gültigkeitsbereich:Global inet6-Adresse: fe80::26d1:7518:9508:8a33/64 Gültigkeitsbereich:Verbindung UP BROADCAST RUNNING MULTICAST MTU:1500 Metrik:1 RX-Pakete:13601 Fehler:0 Verloren:0 Überläufe:0 Fenster:0 TX-Pakete:7762 Fehler:0 Verloren:0 Überläufe:0 Träger:0 Kollisionen:0 Sendewarteschlangenlänge:1000 RX-Bytes:13973295 (13.9 MB) TX-Bytes:1837473 (1.8 MB) When I try to scan for other addresses, this is what I get:
$nmap -n -sP 10.42.0.255/24 Starting Nmap 7.01 ( https://nmap.org ) at 2017-10-04 22:30 CEST Nmap scan report for 10.42.0.1 Host is up (0.0010s latency). Nmap done: 256 IP addresses (1 host up) scanned in 2.82 seconds Same happens when I change Ip into 10.42.0.0.
This is what happens when I connect to the pi with its static ip and with normal network conncetion:
$ssh -Y [email protected] ssh: connect to host 192.168.1.2 port 22: Connection timed out I tried the same command on another machine and it worked perfectly fine.
Bcast:0.0.0.0. 2. And you try to ssh to an IP address that isn't showing up in the output fromifconfig. 3. And what happens if you try to ssh to10.42.0.1?10.42.0.1is my own laptop, it just enters the terminal when I ssh to it. And the reason why I usedifconfigis to retrieve an ip for scanning with nmap. I don't know what to say about the docker, I changed its ip from localhost to172.17.0.1, but I don't think it should have an effect on the broadcast10.42.0.1is from the WiFi interface from yourifconfigoutput. You have to check your network configuration!