Install on Ubuntu 20.04 - unmet dependencies: icinga2 : Depends: icinga2-bin (= 2.12.0-1.xenial)

I’m simply trying to install icinga2 on Ubuntu 20.04 server and I can’t seem to get pass this depency error.
My focal-icinga.list has
deb https://packages.icinga.com/ubuntu icinga-focal main
deb-src https://packages.icinga.com/ubuntu icinga-focal main

But I 'm getting:

sudo apt-get install -y icinga2
Reading package lists… Done
Building dependency tree
Reading state information… Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
icinga2 : Depends: icinga2-bin (= 2.12.0-1.xenial) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

I’ve tried alteady installing icinga2-bin manually although I suppose I 'm not supposed to, but they springs a new set of errors.

Is this a known issue ? Should I install from another package or downgrade my Ubuntu ?

thanks for any input.

Is this a fresh install of 20.04 or did you do a upgrade from 18.04?
Are any(this) packages placed on hold? apt-mark showhold

Fresh install (nothing shows on hold)

Hi !

Can you specify what ubuntu release it is ?
Is it the Ubuntu 20.04.1 Server (64-bit) or is it the desktop version ?

Regards

David

Server (64) (running in VM - if that matters)

Distributor ID: Ubuntu
Description: Ubuntu 20.04.1 LTS
Release: 20.04
Codename: focal

5.4.0-48-generic #52-Ubuntu SMP Thu Sep 10 10:58:49 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux

No, VM doesn’t matter. I just needed to know if it is server or desktop version. and the minor release number which you already gave. thanks for that.

I investigate why this might be happening.

Regards

David

thanks ! (I notice now I was a bit brief in my reply, apologies, I got distracted right before send :slightly_smiling_face:

Hi Dimitri!

As far as i have installed now the Ubuntu 20.04.1 System & Icinga 2 i’ve got no problems.

Here my short History of Steps done

    1  apt get update -y
    2  apt-get update -y
    3  apt-get upgrade -y
    4  wget -O - https://packages.icinga.com/icinga.key | apt-key add -
    5  vi /etc/apt/sources.list
    6  apt-get update -y
    7  apt-cache search nagios-plugins-all
    8  apt-cache search nagios-plugins
    9  apt install nagios-plugins-contrib -y
   10  apt install icinga2
   11  systemctl status icinga2
   12  history | less

Besides the typo with apt-get & adding the sources via “vi /etc/apt/sources.list” which is just adding the two lines at the end of the sources.list file

deb http://packages.icinga.com/ubuntu icinga-focal main
deb-src http://packages.icinga.com/ubuntu icinga-focal main

then updating via “apt-get update -y”

After that as a primary step installing the plugins with “nagios-plugins-contrib” and then installing icinga 2.

root@testserver:~# apt install icinga2
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  icinga2-bin icinga2-common icinga2-doc libboost-context1.71.0 libboost-coroutine1.71.0 libboost-filesystem1.71.0
  libboost-program-options1.71.0 libboost-regex1.71.0 libboost-thread1.71.0
Suggested packages:
  vim-icinga2
The following NEW packages will be installed:
  icinga2 icinga2-bin icinga2-common icinga2-doc libboost-context1.71.0 libboost-coroutine1.71.0 libboost-filesystem1.71.0
  libboost-program-options1.71.0 libboost-regex1.71.0 libboost-thread1.71.0
0 upgraded, 10 newly installed, 0 to remove and 3 not upgraded.
Need to get 11.6 MB of archives.
After this operation, 39.1 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://packages.icinga.com/ubuntu icinga-focal/main amd64 icinga2-common all 2.12.0-1.focal [66.3 kB]
Get:2 http://de.archive.ubuntu.com/ubuntu focal/main amd64 libboost-context1.71.0 amd64 1.71.0-6ubuntu6 [207 kB]
Get:3 http://packages.icinga.com/ubuntu icinga-focal/main amd64 icinga2-bin amd64 2.12.0-1.focal [3690 kB]
Get:4 http://de.archive.ubuntu.com/ubuntu focal/main amd64 libboost-thread1.71.0 amd64 1.71.0-6ubuntu6 [249 kB]
Get:5 http://de.archive.ubuntu.com/ubuntu focal/universe amd64 libboost-coroutine1.71.0 amd64 1.71.0-6ubuntu6 [219 kB]
Get:6 http://de.archive.ubuntu.com/ubuntu focal/main amd64 libboost-filesystem1.71.0 amd64 1.71.0-6ubuntu6 [242 kB]
Get:7 http://de.archive.ubuntu.com/ubuntu focal/main amd64 libboost-program-options1.71.0 amd64 1.71.0-6ubuntu6 [342 kB]
Get:8 http://de.archive.ubuntu.com/ubuntu focal/universe amd64 libboost-regex1.71.0 amd64 1.71.0-6ubuntu6 [471 kB]
Get:9 http://packages.icinga.com/ubuntu icinga-focal/main amd64 icinga2 amd64 2.12.0-1.focal [112 kB]
Get:10 http://packages.icinga.com/ubuntu icinga-focal/main amd64 icinga2-doc all 2.12.0-1.focal [6044 kB]
Fetched 11.6 MB in 7s (1706 kB/s)                                                                                                      
Selecting previously unselected package icinga2-common.
(Reading database ... 77819 files and directories currently installed.)
Preparing to unpack .../0-icinga2-common_2.12.0-1.focal_all.deb ...
Unpacking icinga2-common (2.12.0-1.focal) ...
Selecting previously unselected package libboost-context1.71.0:amd64.
Preparing to unpack .../1-libboost-context1.71.0_1.71.0-6ubuntu6_amd64.deb ...
Unpacking libboost-context1.71.0:amd64 (1.71.0-6ubuntu6) ...
Selecting previously unselected package libboost-thread1.71.0:amd64.
Preparing to unpack .../2-libboost-thread1.71.0_1.71.0-6ubuntu6_amd64.deb ...
Unpacking libboost-thread1.71.0:amd64 (1.71.0-6ubuntu6) ...
Selecting previously unselected package libboost-coroutine1.71.0:amd64.
Preparing to unpack .../3-libboost-coroutine1.71.0_1.71.0-6ubuntu6_amd64.deb ...
Unpacking libboost-coroutine1.71.0:amd64 (1.71.0-6ubuntu6) ...
Selecting previously unselected package libboost-filesystem1.71.0:amd64.
Preparing to unpack .../4-libboost-filesystem1.71.0_1.71.0-6ubuntu6_amd64.deb ...
Unpacking libboost-filesystem1.71.0:amd64 (1.71.0-6ubuntu6) ...
Selecting previously unselected package libboost-program-options1.71.0:amd64.
Preparing to unpack .../5-libboost-program-options1.71.0_1.71.0-6ubuntu6_amd64.deb ...
Unpacking libboost-program-options1.71.0:amd64 (1.71.0-6ubuntu6) ...
Selecting previously unselected package libboost-regex1.71.0:amd64.
Preparing to unpack .../6-libboost-regex1.71.0_1.71.0-6ubuntu6_amd64.deb ...
Unpacking libboost-regex1.71.0:amd64 (1.71.0-6ubuntu6) ...
Selecting previously unselected package icinga2-bin.
Preparing to unpack .../7-icinga2-bin_2.12.0-1.focal_amd64.deb ...
Unpacking icinga2-bin (2.12.0-1.focal) ...
Selecting previously unselected package icinga2.
Preparing to unpack .../8-icinga2_2.12.0-1.focal_amd64.deb ...
Unpacking icinga2 (2.12.0-1.focal) ...
Selecting previously unselected package icinga2-doc.
Preparing to unpack .../9-icinga2-doc_2.12.0-1.focal_all.deb ...
Unpacking icinga2-doc (2.12.0-1.focal) ...
Setting up icinga2-common (2.12.0-1.focal) ...
Adding system-user for nagios
Created symlink /etc/systemd/system/multi-user.target.wants/icinga2.service → /lib/systemd/system/icinga2.service.
Setting up libboost-filesystem1.71.0:amd64 (1.71.0-6ubuntu6) ...
Setting up icinga2-doc (2.12.0-1.focal) ...
Setting up libboost-regex1.71.0:amd64 (1.71.0-6ubuntu6) ...
Setting up libboost-thread1.71.0:amd64 (1.71.0-6ubuntu6) ...
Setting up libboost-context1.71.0:amd64 (1.71.0-6ubuntu6) ...
Setting up libboost-program-options1.71.0:amd64 (1.71.0-6ubuntu6) ...
Setting up libboost-coroutine1.71.0:amd64 (1.71.0-6ubuntu6) ...
Setting up icinga2-bin (2.12.0-1.focal) ...
enabling default icinga2 features
Enabling feature checker. Make sure to restart Icinga 2 for these changes to take effect.
Enabling feature notification. Make sure to restart Icinga 2 for these changes to take effect.
Enabling feature mainlog. Make sure to restart Icinga 2 for these changes to take effect.
Setting up icinga2 (2.12.0-1.focal) ...
Processing triggers for systemd (245.4-4ubuntu3.2) ...
Processing triggers for man-db (2.9.1-1) ...
Processing triggers for libc-bin (2.31-0ubuntu9.1) ...

And so far no error with the dependency and the the service is running fine.

Just to be sure ? It is not an In-Distro upgrade from an older version ? And therefore the old xenial stuff is popping up ?

Regards

David

Hey,
Thanks for all the work … i guess I 'll just delete everything and re-try.

No, I just downloaded from https://ubuntu.com/download/server
Installed it, and more or less performed the steps you did… it’s so basic that I 'm puzzled to what is going wrong or different.

1 Like

Maybe a hidden special character via c&p that sometimes occurs … who knows. From our side ATM all we can say it should work.

I tried now two times, no strange cache or proxy settings that i’ve found which intervene or present the wrong repository.

But please let us know if it is still occuring.

Regards

David

I believe I found what was wrong, my /etc/apt/sources.list still contained a reference to
deb-src http://packages.icinga.org/ubuntu icinga-xenial main
Changing that to deb-src Index of /ubuntu icinga-focal main…

Installer runs now, I think I can continue … thanks!

3 Likes

Sometimes it’s that simple!
Congrats that you found the culprit.

All the best

David