Ubuntu Server 24.04.1 LTS fresh install errors in apt install and upgrade

Bo Berglund bo.berglund at gmail.com
Fri Jan 31 15:02:34 UTC 2025


On Wed, 29 Jan 2025 12:47:52 -0600, Keith via ubuntu-users
<ubuntu-users at lists.ubuntu.com> wrote:

>On 1/29/25 6:20 AM, Bo Berglund wrote:
>> Everything seemed OK until I installed:
>> 
>> sudo apt install mosquitto mosquitto-clients
>> 
>> At the end of that I got to this message:
>> 
>> Could not execute systemctl:  at /usr/bin/deb-systemd-invoke line 148.
>> 
---
>> 
>> Why does mosquitto not install and how can I get all packages up-to-date?
>> 

>
>You might try reinstalling just the mosquitto package by itself and see 
>if the problem persists. If the mosquitto.service does fail to start 
>again, then I'd purge (sudo apt autopurge mosquitto) the package making 
>sure all config files are deleted and then attempt a reinstall.
>

After a lot of checking I found the problem:
There was already a mosquitto running and it had grabbed the default port number
on the NIC. And apt did not see that when I asked it to install mosquitto...
So the new installed mosquitto could not start since the port was occupied...

But how could that have happened?

Turns out that the extra install was a "snap" and so was not seen by apt, which
went ahead and installed it again....
Very strange since this was a fresh install of the Ubuntu Server 24.04.1 system.

So after I did a snap remove mosquitto and apt remove mosquitto I could install
it again normally with apt.

And I also found out how to activate PRO using my subscription, so now I am
pretty much up-to-date and can move forward with the rest of
install/configuration to get my new system a functional replacement for my older
system.
 

-- 
Bo Berglund
Developer in Sweden





More information about the ubuntu-users mailing list