I was following this Raspberry Pi documentation (https://www.raspberrypi.org/documentation/configuration/wireless/wireless-cli.md) about connecting to wireless connection. My SSID and password are correct.
Whenever I use the command:
It has an inet addr value.
I used the command:
sudo iwlist wlan0 scan
It displays all the available WiFi connections.
But when I try using the command:
sudo wpa_cli -i wlan0 reconfigure
It says "Failed to connect to non-global ctrl_ifname: wlan0 error: No such file or directory"
Any of you have encountered this? I followed the documentation and all but it doesn't seem to tackle this problem.