I have a new Pi Zero W.
I'm trying to install a Debian (DietPi) onto it but it always fails.I don't have a keyboard and external monitor, so I choose a headless install with predefined wifi key and SSID.
The problem is absolutely wierd (wlan0 interface works for sure, because that's the only way now to reach it via SSH and it works):
Pinging an IP address works:
root@DietPi:~# ping 8.8.8.8PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.64 bytes from 8.8.8.8: icmp_seq=1 ttl=53 time=9.95 ms64 bytes from 8.8.8.8: icmp_seq=2 ttl=53 time=13.0 ms64 bytes from 8.8.8.8: icmp_seq=3 ttl=53 time=12.1 ms64 bytes from 8.8.8.8: icmp_seq=4 ttl=53 time=15.0 ms^C--- 8.8.8.8 ping statistics ---4 packets transmitted, 4 received, 0% packet loss, time 7msrtt min/avg/max/mdev = 9.949/12.523/15.039/1.829 ms
Pinging a domain name (using DNS) works too:
root@DietPi:~# ping google.comPING google.com (172.217.19.174) 56(84) bytes of data.64 bytes from zrh04s07-in-f14.1e100.net (172.217.19.174): icmp_seq=1 ttl=53 time=10.1 ms64 bytes from zrh04s07-in-f14.1e100.net (172.217.19.174): icmp_seq=2 ttl=53 time=12.7 ms64 bytes from zrh04s07-in-f14.1e100.net (172.217.19.174): icmp_seq=3 ttl=53 time=12.9 ms64 bytes from zrh04s07-in-f14.1e100.net (172.217.19.174): icmp_seq=4 ttl=53 time=13.2 ms^C--- google.com ping statistics ---4 packets transmitted, 4 received, 0% packet loss, time 7msrtt min/avg/max/mdev = 10.102/12.236/13.163/1.248 ms
Let's download a file from http (works too):
root@DietPi:~# wget http://archive.raspberrypi.org/debian/dists/buster/InRelease--2020-04-24 07:49:31-- http://archive.raspberrypi.org/debian/dists/buster/InReleaseResolving archive.raspberrypi.org (archive.raspberrypi.org)... 176.126.240.86, 46.235.231.151, 46.235.230.122, ...Connecting to archive.raspberrypi.org (archive.raspberrypi.org)|176.126.240.86|:80... connected.HTTP request sent, awaiting response... 200 OKLength: 25112 (25K)Saving to: ‘InRelease.1’InRelease.1 100%[========================================================================================================================================>] 24.52K --.-KB/s in 0.1s2020-04-24 07:49:32 (174 KB/s) - ‘InRelease.1’ saved [25112/25112]
Okay, now problem: let's download the same file from https:
root@DietPi:~# wget https://archive.raspberrypi.org/debian/dists/buster/InRelease--2020-04-24 07:49:37-- https://archive.raspberrypi.org/debian/dists/buster/InReleaseResolving archive.raspberrypi.org (archive.raspberrypi.org)... 93.93.135.117, 176.126.240.167, 46.235.231.111, ...Connecting to archive.raspberrypi.org (archive.raspberrypi.org)|93.93.135.117|:443... connected.
This one hangs forever and can not continue. Due to this apt
is not able upgrade or install anything.
I did one more step:
root@DietPi:~# wget -d https://archive.raspberrypi.org/debian/dists/buster/InReleaseDEBUG output created by Wget 1.20.1 on linux-gnueabihf.Reading HSTS entries from /root/.wget-hstsURI encoding = ‘UTF-8’Converted file name 'InRelease' (UTF-8) -> 'InRelease' (UTF-8)--2020-04-24 07:52:26-- https://archive.raspberrypi.org/debian/dists/buster/InReleaseCertificates loaded: 128Resolving archive.raspberrypi.org (archive.raspberrypi.org)... 176.126.240.86, 93.93.135.117, 176.126.240.167, ...Caching archive.raspberrypi.org => 176.126.240.86 93.93.135.117 176.126.240.167 46.235.231.111 93.93.135.118 46.235.227.39 176.126.240.84 46.235.231.145 46.235.230.122 46.235.231.151 2a00:1098:88:26::1 2a00:1098:88:26::1:1 2a00:1098:84:1e0::1 2a00:1098:82:47::1:1 2a00:1098:80:56::2:1 2a00:1098:88:26::2:1 2a00:1098:84:1e0::2 2a00:1098:80:56::1:1 2a00:1098:84:1e0::3 2a00:1098:82:47::1Connecting to archive.raspberrypi.org (archive.raspberrypi.org)|176.126.240.86|:443... connected.Created socket 3.Releasing 0x00f0a8d0 (new refcount 1).GnuTLS: Error in the pull function.Closed fd 3Unable to establish SSL connection.root@DietPi:~#
Two more additions:
- Same command works fine on another Pi (other physical location).
- From the same location where this PiZero is, I can open this link on my computer.
Update (based on comment)
Date seems okay on the Zero. (Although timezone is not yet setup)
Adding --no-check-certificate
does not help:
# wget -d --no-check-certificate https://archive.raspberrypi.org/debian/dists/buster/InReleaseSetting --check-certificate (checkcertificate) to 0Setting --check-certificate (checkcertificate) to 0DEBUG output created by Wget 1.20.1 on linux-gnueabihf.Reading HSTS entries from /root/.wget-hstsURI encoding = ‘UTF-8’Converted file name 'InRelease' (UTF-8) -> 'InRelease' (UTF-8)--2020-04-24 08:15:12-- https://archive.raspberrypi.org/debian/dists/buster/InReleaseCertificates loaded: 128Resolving archive.raspberrypi.org (archive.raspberrypi.org)... 46.235.231.151, 93.93.135.118, 176.126.240.86, ...Caching archive.raspberrypi.org => 46.235.231.151 93.93.135.118 176.126.240.86 46.235.230.122 46.235.227.39 46.235.231.111 46.235.231.145 176.126.240.84 93.93.135.117 176.126.240.167 2a00:1098:84:1e0::3 2a00:1098:88:26::2:1 2a00:1098:84:1e0::1 2a00:1098:82:47::1:1 2a00:1098:88:26::1 2a00:1098:80:56::2:1 2a00:1098:80:56::1:1 2a00:1098:82:47::1 2a00:1098:88:26::1:1 2a00:1098:84:1e0::2Connecting to archive.raspberrypi.org (archive.raspberrypi.org)|46.235.231.151|:443... connected.Created socket 3.Releasing 0x003018e8 (new refcount 1).
Curl seems to work without issues:
# curl https://archive.raspberrypi.org/debian/dists/buster/InRelease > InRelease % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed100 25112 100 25112 0 0 41032 0 --:--:-- --:--:-- --:--:-- 41099
Update2:
The main issue is that apt
fails:
# apt updateHit:1 http://raspbian.raspberrypi.org/raspbian buster InReleaseIgn:2 https://archive.raspberrypi.org/debian buster InReleaseErr:3 https://archive.raspberrypi.org/debian buster Release Could not wait for server fd - select (11: Resource temporarily unavailable) [IP: 93.93.135.117 443]Reading package lists... DoneE: The repository 'https://archive.raspberrypi.org/debian buster Release' does not have a Release file.N: Updating from such a repository can't be done securely, and is therefore disabled by default.N: See apt-secure(8) manpage for repository creation and user configuration details.
This is I believe has the same root cause as the wget's one.