Not automatically connect to wifi unless login -freshly installed Kali Linux RaspberryPi 2021.1
hi everyone,
I just freshly new installation on Pi4 with Kali Linux RaspberryPi 2021.1. everything smooth and fine.
the problem is that:
the pi can not automatically connect to wifi (without LAN cable plugin ) when the login screen shownup. So no ping to this device because no network connection established. If I manually login as a user then wifi is auto connected and showed in networkmanager icon.
If I plug in the LAN cable and startup, I can ping and SSH this PI sucessfully on boot without the need to login.
How can I make the Pi automatically connect to wifi once I plug in the power cable and then I can SSH this PI with wifi connection?
Sorry for my poor English. I have already added these scripts in /etc/network/interfaces
auto wlan0
allow-hotplug wlan0
iface wlan0 inet dhcp
Help is needed and I am grateful^_^