4

Running apt-cache unmet outputs a 1.2 MB file of missing dependencies of packages, none of which exist (the packages themselves).

This is possibly due to restoring old configurations to a fresh install of Ubuntu. I have tried removing, cleaning and purging any related configuration.

Can confirm that the packages do not exist. Any suggestions to make apt-cache know that I don't have these packages already, hence no dependencies flags should exist ?

  • On my system, it's about 4MB output (>87.000 lines)... I guess this command is designed to print all unmet dependencies of all installable packages, instead of only those packages which are actually installed. – Byte Commander Jan 7 '16 at 17:03
  • @ByteCommander I have tested on a live install and indeed it is the case. It has generated about 1.3MB of output. I'll close the question. – egy Jan 7 '16 at 17:47
2

On my system, it's about 4MB output (>87.000 lines).
Found out using apt-cache unmet | wc -c for number of bytes and apt-cache unmet | wc -l for number of lines.

I did not learn much from having a quick glance at the source code, but I strongly guess this command is designed to print all unmet dependencies of all installable packages, instead of only those packages which are actually installed.

The manpage man apt-cache is in my opinion not unambiguously worded, but here are the important snippets:

   unmet
       unmet displays a summary of all unmet dependencies in the package cache.

   -i, --important
       Print only important dependencies; for use with unmet and depends. Causes only Depends and Pre-Depends relations to
       be printed. Configuration Item: APT::Cache::Important.

So you can also narrow down the output somehow if you add the -i argument. I am not sure what exactly this filters out, but it results in less than about 10%, roughly 7.000 lines in my case.

$ apt-cache unmet -i | wc -l
7096
  • That's indeed the case, man apt-cache confirms that. – kos Jan 7 '16 at 17:54
  • 1
    It is indeed the case as you have said. Thanks for the wc -l though ;) – egy Jan 7 '16 at 17:55
  • 1
    @egy See my edit about the -i option. – Byte Commander Jan 7 '16 at 18:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.