[Quick Tip] Speed Up Installing (Downloading) Snap App in Ubuntu

This simple tutorial shows how to speed up the downloading process of snap application package by associating IP address with the snapcraft server in Ubuntu.

Snap is a containerized package format, that makes many great applications (e.g., Spotify, Skype, the latest Blender, and more) easy to install in Ubuntu 18.04 and higher.

However snap is LARGE in file size. Due to slow international network speed, downloading a snap in 20MB even take more than half an hour in my case.

1.) Open terminal either via Ctrl+Alt+T keyboard shortcut or by searching for ‘terminal’ from application menu. When terminal opens, run command:

dig fastly.cdn.snapcraft.io

In the terminal output, copy the IP address under ‘ANSWER SECTION’:

2.) Then run commands to edit the hosts file:

sudo gedit /etc/hosts

Type user password (no asterisk) when it prompts and hit Enter.

When the files opens in gedit text editor, paste following line:

151.101.42.217 fastly.cdn.snapcraft.io

Replace the IP address with which you got in step 1, and finally save the file.

That’s it. Enjoy!