0

Recently I had to reinstall Ubuntu. After returning to Ubuntu 22.04 I restored my /usr/local/ and var folders which caused huge mess in terms of packages being written as installed although when one tries to type the command in terminal they don't seem installed.

Normally I follow the advice from here and it fixes the mess but this time I think I made a bigger mess. As Pinta could not be installed due to mono-runtime not configured I removed them both from the system. Now mono-runtime seems to be installed but not configured: when I type sudo apt install mono-runtime I get

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
mono-runtime is already the newest version (6.8.0.105+dfsg-3.2).
mono-runtime set to manually installed.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
4 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.

but then when I type Y I get

Setting up mono-runtime (6.8.0.105+dfsg-3.2) ...
update-alternatives: error: alternative path /usr/bin/mono doesn't exist
dpkg: error processing package mono-runtime (--configure):
 installed mono-runtime package post-installation script subprocess returned error exit status 2
dpkg: dependency problems prevent configuration of libmono-i18n4.0-cil:
 libmono-i18n4.0-cil depends on mono-runtime (>= 6.8.0.105); however:
  Package mono-runtime is not configured yet.
 libmono-i18n4.0-cil depends on mono-runtime (<< 6.8.0.106); however:
  Package mono-runtime is not configured yet.

dpkg: error processing package libmono-i18n4.0-cil (--configure): dependency problems - leaving unconfigured dpkg: dependency problems prevent configuration of libmono-i18n-west4.0-cil: libmono-i18n-west4.0-cil depends on libmono-i18n4.0-cil (>= 4.0.0~alpha1); however: Package libmono-i18n4.0-cil is not configured yet.

dpkg: error processing package libmono-i18n-west4.0-cil (--configure): dependency problems - leaving unconfigured dpkg: dependency problems prevent configuration of libmono-corlib4.5-cil: libmono-corlib4.5-cil depends on mono-runtime (>= 6.8.0.105); however: Package mono-runtime is not configured yet. libmono-corlib4.5-cil dependNo apport report written because the error message indicates its a followup error from a previous failure. No apport report written because the error message indicates its a followup error from a previous failure. No apport report written because MaxReports is reached already s on mono-runtime (<< 6.8.0.106); however: Package mono-runtime is not configured yet.

dpkg: error processing package libmono-corlib4.5-cil (--configure): dependency problems - leaving unconfigured Errors were encountered while processing: mono-runtime libmono-i18n4.0-cil libmono-i18n-west4.0-cil libmono-corlib4.5-cil

Does anybody has the slightest idea how to solve this problem without formatting the system all over again?

  • try the suggestions from this website. This is a mess and the easiest way to get out of it is probably to reinstall and not mess up installed packages by copy-pasting things where they don't belong. Some of the commands in the linked page may, however, fix some of the inconsistencies with your system – Esther Jun 20 '22 at 14:06
  • @Esther thanks. Tried them all. None worked. So that means I need to re-format all again? – Denis Marcinkov Jun 20 '22 at 14:11
  • for this specifically, you can try installing with --reinstall to see if it installs "from scratch". You can also try --reinstalling all of its dependencies using this answer. However, it is quite possible that apt is so broken it is harder to fix than to reinstall, and you will likely come across these kinds of issues again and again even if you get it working this time – Esther Jun 20 '22 at 14:15
  • @Esther thanks a lot. I didn't think on apt-cache at all. That resurrected mono-runtime indeed. I guess this "plaster" should suffice for now. – Denis Marcinkov Jun 20 '22 at 14:24

0 Answers0