Score:0

Can't connect to snap servers

cy flag

This is my first time setting up a server, and I'm already facing a huge Problem: I can't install software via snap! I'm using the latest version of Ubuntu server.

When I try to sudo snap install Nextcloud, or anything else(like refreshing snapd) i get this response:

error: cannot install "nextcloud": persistent network error: Post
"https://api.snapcraft.io/v2/snaps/refresh": dial tcp 185.125.188.59:443: connect: network is unreachable

I tried disabling ufw, deleting the proxy using sudo snap unset system proxy.https and sudo snap unset system proxy.https

When i ping snapcraft.io, it's valid, but api.snapcraft.io is unreachable.

Mahler avatar
in flag
It happens from time to time. Just wait.
lemoana avatar
ao flag
guess the problem most likely is in the network. Maybe you are using a proxy? Or there are some limits on your network? Anyway, the first necessary step is to be able to ping to `api.snapcraft.io`. btw, are you in China? ifso, you may need a VPN to access to the network
Joosl avatar
cy flag
Ok so I tried it several times and it still doesn't work. The issue isn't just with snapcraft. It's with many different installers like Minecraft or steam. I can't ping java.net, but i can ping java.com. i tried disabling the firewall, DNS is set to googles 8.8.8.8 and 8.8.4.4 and no, I am not in China
Daniele B avatar
mx flag
@Joosl I have the same issue. Were you able to solve the problem?
Joosl avatar
cy flag
@DanieleB Yes, you have to specify the routers ip adress / gateway in the netplan config https://netplan.readthedocs.io/en/stable/netplan-tutorial/#showing-your-current-netplan-configuration
Daniele B avatar
mx flag
@Joosl I found out in my case the reason was the server just had an IPv6 address, and not IPv4 address. Currently Snap doesn't support IPv6 addresses: https://bugs.launchpad.net/snapstore-server/+bug/1710022 So, I had to take an IPv4 address
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.