Tls oversized record received with length 20527


#1
error: cannot install "hello-world": Post https://api.snapcraft.io/v2/snaps/refresh: proxyconnect
tcp: tls: oversized record received with length 20527

When I try to run an Ubuntu 18.10 upgrade it says it can’t reach the Snap server. So, I tried installing a snap manually and encountered the above error message when running snap install hello-world

I’ve set up my proxy in /etc/environment and even tried adding /etc/systemd/system/snapd.service.d/proxy.conf with my http_proxy and https_proxy (both using an http:// address)

Anything else I should try or look into for debugging this issue?

Thanks!
Stephen


#2

That error seems to appear when you set https_proxy=https://<something> when it should be https_proxy=http://<something>.


#3

No, my proxy is set to http://

(sorry for the late reply; I completely forgot about my post for a while)


#4

If you’re still having the issue, could you show us the contents of /etc/systemd/system/snapd.service.d/proxy.conf and of /etc/environment, as well as the output of snap version?


#5

/etc/systemd/system/snapd.service.d/proxy.conf

[Service]
Environment=http_proxy=http://:8080
Environment=https_proxy=http://:8080

/etc/environment

PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games"
http_proxy=“http://:8080/”
https_proxy=“http://:8080/”

snap version

snap 2.34.2+18.04
snapd 2.34.2+18.04
series 16
ubuntu 18.04
kernel 4.15.0-43-generic


#6

Nevermind, I had an https:// in the /etc/environment file, changed it, and it didn’t fix it so I still posted the previous message. But figured I should reboot just in case and it seems to be working now.

Thanks for your help.


#7

By the way, a lot of tools need a hostname before the port. go doesn’t, so snapd and snap are ok, but as you put it in /etc/environment every shell will have this in it, so curl, wget, and lwp-request are going to be very unhappy (each in their own way), to name the three I checked. Make it http://localhost:8080/ and it should be fine.


#8

I have the same error, but I couldn’t fix it. Please help me.
I am getting nothing for “curl -D- -s https://postman-echo.com/status/200” also.
this is what i have in /etc/environment
"
PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games"
http_proxy=“http://:8080/”
https_proxy=“https://:8080/”
ftp_proxy=“ftp://:8080/”
socks_proxy=“socks://:8080/”

Please help me

"