Adding Landscape PPA failing / Ubuntu Server 26.04 LTS

Ubuntu Version

Ubuntu 26.04 LTS

Desktop Environment (if applicable)

None (server/headless)

Problem Description

Adding PPA repository for Landscape fails with connection timeout

Relevant System Information

Ubuntu Server 26.04 LTS running on new install VM with updates run

Error Messages / Logs

$ sudo add-apt-repository -y ppa:landscape/self-hosted-26.04Traceback (most recent call last):File “/usr/bin/add-apt-repository”, line 632, in sys.exit(0 if addaptrepo.main() else 1)~~~~~~~~~~~~~~~^^File “/usr/bin/add-apt-repository”, line 615, in mainshortcut = handler(source, **shortcut_params)File “/usr/lib/python3/dist-packages/softwareproperties/shortcuts.py”, line 40, in shortcut_handlerreturn handler(shortcut, **kwargs)File “/usr/lib/python3/dist-packages/softwareproperties/ppa.py”, line 89, in initif self.lpppa.publish_debug_symbols:^^^^^^^^^^File “/usr/lib/python3/dist-packages/softwareproperties/ppa.py”, line 133, in lpppaself._lpppa = self.lpteam.getPPAByName(name=self.ppaname)^^^^^^^^^^^File “/usr/lib/python3/dist-packages/softwareproperties/ppa.py”, line 120, in lpteamself._lpteam = self.lp.people(self.teamname)^^^^^^^File “/usr/lib/python3/dist-packages/softwareproperties/ppa.py”, line 111, in lpself._lp = login_func(“%s.%s” % (self.module, self.class.name),~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^service_root=‘production’,^^^^^^^^^^^^^^^^^^^^^^^^^^version=‘devel’)^^^^^^^^^^^^^^^^File “/usr/lib/python3/dist-packages/launchpadlib/launchpad.py”, line 487, in login_anonymouslyreturn cls(credentials,…<6 lines>…version=version,)File “/usr/lib/python3/dist-packages/launchpadlib/launchpad.py”, line 223, in initsuper().init(~~~~~~~~~~~~~~~~^credentials, service_root, cache, timeout, proxy_info, version^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^)^File “/usr/lib/python3/dist-packages/lazr/restfulclient/resource.py”, line 511, in initself._wadl = self._browser.get_wadl_application(self._root_uri)~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^File “/usr/lib/python3/dist-packages/lazr/restfulclient/_browser.py”, line 502, in get_wadl_applicationresponse, content = self._request(url, media_type=wadl_type)~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^File “/usr/lib/python3/dist-packages/lazr/restfulclient/_browser.py”, line 441, in _requestresponse, content = self._request_and_retry(~~~~~~~~~~~~~~~~~~~~~~~^str(url), method=method, body=data, headers=headers^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^)^File “/usr/lib/python3/dist-packages/lazr/restfulclient/_browser.py”, line 400, in _request_and_retryresponse, content = self._connection.request(~~~~~~~~~~~~~~~~~~~~~~~~^url, method=method, body=body, headers=headers^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^)^File “/usr/lib/python3/dist-packages/httplib2/init.py”, line 1752, in request(response, content) = self._request(~~~~~~~~~~~~~^conn, authority, uri, request_uri, method, body, headers, redirections, cachekey,^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^)^File “/usr/lib/python3/dist-packages/launchpadlib/launchpad.py”, line 139, in _requestresponse, content = super()._request(*args)~~~~~~~~~~~~~~~~^^^^^^^File “/usr/lib/python3/dist-packages/lazr/restfulclient/_browser.py”, line 204, in _requestreturn super(RestfulHttp, self)._request(~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^conn,^^^^^…<7 lines>…cachekey,^^^^^^^^^)^File “/usr/lib/python3/dist-packages/httplib2/init.py”, line 1472, in _request(response, content) = self._conn_request(conn, request_uri, method, body, headers)~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File “/usr/lib/python3/dist-packages/httplib2/init.py”, line 1394, in _conn_requestconn.connect()~~~~~~~~~~~~^^File “/usr/lib/python3/dist-packages/httplib2/init.py”, line 1159, in connectsock.connect((self.host, self.port))~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^TimeoutError: [Errno 110] Connection timed out

What I’ve Tried

I am working my way though installing Ubuntu Landscape following their official instructions: How to install Landscape Server with quickstart mode - Landscape documentation

I am having difficulties at step: “Install landscape-server-quickstart”. All previous steps are completed without issues.

I am new to Ubuntu so not familiar with the specifics of PPA. VM has network connectivity and DNS confirmed functional.

I have done a TCP dump and initial indications are its an issue contacting the remote server on IP address 185.125.189.225. A lookup shows this is owned by Canonical Ltd. It is not responding to a ping.

It is possible to configure machines to not respond to ICMP packets (like e.g. ping). This makes sense for machines you expect to take a heavy load. Since trying the address in a web browser gives an error about the certificate not being valid for the address but for quite a lot of names and you do get a response when you tell Firefox to disregard the problem, I think what you’re seeing is probably a temporary problem with the server being under heavy load (which would be a reason for the timeout you’re seeing).

Thanks for the feedback. You must be getting a different result with the expired SSL certificate because I observed TCP retransmit which falls at a lower level.

Turning off ICMP is one of a list of popular misinformation things I see online which gets computer hobbyists into problems they then blame on their ISP.

I have deployed more servers and client connections then I can count over 29 years of working in the Internet industry and never seen an issue attributable to having ICMP echo allowed.

I have lodged a fault with Canonical because whatever it is, network tests clearly show its at their end.

I know the traffic is getting through to the same /24 block because I can ping other addresses. This rules out internet issues.

Well, the PPA itself is there and accessible:

even on the archive level:

That resolves to the following IPv4 addresses which are different to the address I observed the communication via the CLI client:

Name: ppa.launchpadcontent.net
Address: 185.125.189.186
Name: ppa.launchpadcontent.net
Address: 185.125.189.187
Name: ppa.launchpadcontent.net
Address: 185.125.189.188

(IPv6 addresses removed for brevity)

I am new to Ubuntu so don’t know the finer details of the package manager. I assumed 443/tcp (HTTPS) and looked at this.

IIRC there is a loadbalancer in front of the system so your IPs will be randomly changing anyway …

While the servers do have https access in parallel to http, the package archives (and apt itself) do usually not use https (the packages Release file in the archive as well as each individual package already carry signatures so https transport would be overlkill), so 80/tcp (and using http instead of https in the /etc/apt/sources.list.d entry for apt) is fine as well …

When the command was run TCP dump showed traffic to port 443.

It’s not an error for an expired SSL-certificate. The certificate is not valid for 185.125.189.225 but is valid for various names in launchpad.net.
Also I didn’t say discarding ICMP packets is a security measure. It saves a minuscule amount of outgoing bandwidth and whatever processing power is needed for answering, so it saves a small bit of money and let’s the server work a small bit faster at it’s real job.

In any case you can just add the sources.list entry manually without using add-apt-repository, the details are shown when you expand the “Technical details about this PPA” on the first link I gave above …

Since the PPA is reachable and the content is fully browsable it could as well be an issue with the add-apt-repository tool …

2 Likes

Thanks to @ogra and @hdd-gehrke for the contributions :slight_smile: Having that Launchpad link gave me enough to get going on and work my way through the rest.

This is how I have resolved it. Since the original post I have changed this VM to 24.04 LTS for an unrelated reason, specifically:

For a manual installation on Ubuntu 26.04, RabbitMQ must run on a separate machine with Ubuntu 22.04 LTS or Ubuntu 24.04 LTS.

How to install Landscape manually - Landscape documentation

I added a file /etc/apt/sources.list.d/landscape-self-hosted.list with the following:

deb https://ppa.launchpadcontent.net/landscape/self-hosted-26.04/ubuntu noble main

APT gave a warning about a missing GPG key so I imported this:

gpg --keyserver keyserver.ubuntu.com --recv-keys 7340EF02FE30EDD8

and to save it to the right place:

gpg --export 7340EF02FE30EDD8 | sudo tee /etc/apt/trusted.gpg.d/launchpad-landscape-7340EF02FE30EDD8.gpg > /dev/null

(It appears APT doesn’t like the default format so needs to be exported?)

and set the permissions with:

sudo chmod 644 /etc/apt/trusted.gpg.d/launchpad-landscape-7340EF02FE30EDD8.gpg

I am new to Ubuntu and its package manager is very different from the BSD-like manual management I was used to so YMMV and if you have something to offer to improve my method please share :slight_smile:

2 Likes