1

The WiFi access is set up in my Pi 3-B using hostapd as shown in this link. I'm able to connect to it through WiFi, but don't know how to SSH into it.

Previously, it was possible to connect to it over SSH through a common WiFi network by using its allotted wlan0 IP, but as I made it into an AP, I am not able to do that.

Is there any way to SSH (or any mode of remote access) to the Pi in which you are connected as an AP-client?

  • What happens when you try to connect to the Raspberry Pi's IP? Do you reach the login screen or does the connection timeout before that? Also check your firewall/iptables rules. Make sure port 22 is open. – Abdul Mueid Jul 31 '16 at 15:22
  • Thanks for trying, @AbdulMueid. But the problem is solved now. It happens to be the problem with the DHCP connection setup. – Ébe Isaac Jul 31 '16 at 15:31
1

Solved! The problem was with the DHCP setup. After following this post, I was able to connect to it by specifying the static IP address specified to the wlan0.

The method uses udhcpd package for DHCP management (not sure as to why dnsmasq never worked for me).

The static address was specified in the /etc/network/interfaces file like so

iface wlan0 inet static
  address 192.168.43.2
  netmask 255.255.255.0

Hence it was possible to access it through the client system (which was connected to it using the Pi-3's own in-built WiFi) using this IP address

$ ssh pi@192.168.43.2
pi@192.168.43.2's password: 

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Sun Jul 31 15:21:56 2016 from 192.168.42.20
pi@raspberry:~ $ 

I am also able to do this even without the Ethernet connected.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.