Page 1 of 1

Headless rpi3

Posted: Fri Sep 15, 2017 7:21 pm
by ImHarvol
Buenas, hasta hace poco, cuando instalaba el sistema operativo en mi micro SD (Raspbian Jessie), añadía una carpeta llamada ssh y creaba el wpa_supplicant, siguiendo este tutorial How To Setup Raspberry Pi Zero W Headless WiFi. Bueno, hoy he ido a hacer lo mismo de siempre, formatear la SD, he descargado el nuevo SO (RASPBIAN STRETCH LITE), y he creado la carpeta ssh y el wpa_supplicant. El problema es que al encender la rpi no se conecta a la red wifi, dudo mucho que haya puesto los datos mal, ya que lo he intentado varias veces fijándome en que los datos estén bien.

He supuesto dos posibles problemas, que en el nuevo SO (Raspbian Stretch) necesite algo mas para el wpa_suplicant. O tambien que al ser mi red WPA2, tenga que cambiar algo de esta linea

Code: Select all

key_mgmt=WPA-PSK

Re: Headless rpi3

Posted: Sat Sep 16, 2017 7:15 am
by ImHarvol
Vale, he encontrado la solucion en este post Raspbian Stretch: Wifi not starting on boot
ncguk wrote:
Thu Aug 17, 2017 11:02 pm
I've been fighting this all evening. My solution on a fresh Raspbian Lite install:

Make sure your wpa_supplicant.conf is in place then do

Code: Select all

sudo nano /etc/network/interfaces
and add

Code: Select all

allow-hotplug wlan0
iface wlan0 inet manual
    wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
to the end of the file. Then do

Code: Select all

sudo systemctl enable wpa_supplicant.service
Then reboot.

Re: Headless rpi3

Posted: Sat Sep 16, 2017 10:00 am
by camelot
There is a bug in the script which prevent wlan0 goiung up at boot
Please try

Code: Select all

--- /etc/wpa_supplicant/functions.sh
+++ /etc/wpa_supplicant/functions.sh
@@ -49,7 +49,7 @@

 # verbosity variables
 if [ -n "$IF_WPA_VERBOSITY" ] || [ "$VERBOSITY" = "1" ]; then
-       TO_NULL="/dev/stdout"
+       TO_NULL="&1"
        DAEMON_VERBOSITY="--verbose"
 else
        TO_NULL="/dev/null"
@@ -117,7 +117,7 @@
                        ;;
                "stderr")
                        shift
-                       echo "$WPA_SUP_PNAME: $@" >/dev/stderr
+                       echo "$WPA_SUP_PNAME: $@" >&2
                        ;;
                *)
                        ;;

Re: Headless rpi3

Posted: Tue Sep 26, 2017 1:38 am
by gray.rabbit
You need to setup a fake network in your wpa_supplicant.conf

Code: Select all

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=AU
#real network
network={
ssid="NetworkName"
psk="password"
key_mgmt=WPA-PSK
}
#fake network workaround for headless Raspberry Pi 3 / Zero for Stretch
network={
ssid="fakessid"
psk="fakepass"
key_mgmt=WPA-PSK
}
I have created an open source Windows project that creates this file with your settings on github
https://github.com/RabbitGray/Raspberry ... Setup-Tool