Since you can't add the repository, you can always add them from a terminal using the command line. Browse to the list of the repositories at the WebUpd8 Website. Copy down the address of the master repository, which is Master Repository. You want to add this one because it contains all the others.
sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup
sudo gedit /etc/apt/sources.list
- Visit Master Repository in a Web Browser.
- Find the Dropdown Arrow that reads:
Technical Details about this PPA
- Click Your Ubuntu Version in the List Labeled Choose Your Version
- Add the resulting output into the file in Step 2.
- Save the File
sudo apt-get update
. This update command should now fetch the Private Keys of the new Repository. If you receive the error as you stated in your comment, then this repository has no private key. You may want to contact the PPA maintainer at that point who will either give you the key, or tell you to ignore the Warning.
In order to make this permanent, open your /etc/sysctl.conf
file using sudo
sudo nano /etc/sysctl.conf
Add the line at the bottom of the file:
net.ipv6.conf.all.disable_ipv6=1
After that you may reboot your machine or run
sudo sysctl -p
Alternatively, you may instruct your ssh client to use ipv4 only. To do so, open ~/.ssh/config
using vi
or nano
and add the following:
Host *
AddressFamily inet
AddressFamily
in the ssh config instructs which type of address to use when connecting via ssh. Valid choices are any
, inet
, inet6
. Selecting to use inet
makes sure ssh does not use ipv6 at all.
Git (commands) use either ssh or http protocol when communicating over a network. Since you are most likely using ssh protocol for your git commands, and making ssh protocol only use ipv4, it resolves the slow connectivity issue related to ipv6.
Unfortunately, this alternative approach won't fix your add-apt-repository ppa
Best Answer
I temporarily disabled IPv6 system-wide.
It seems to be a DNS routing issue. I was able to use the hotspot on my phone to troubleshoot and the problems went away.
sudo sysctl net.ipv6.conf.all.disable_ipv6=1
disables IPv6 until reboot.