Skip to main content
Engineering LibreTexts

11-G.7: Software Dependency Troubleshooting

  • Page ID
    41984
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \) \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)\(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\) \(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\)\(\newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    EXAM OBJECTIVES COVERED
    4.4 Given a scenario, analyze and troubleshoot application and hardware issues.

    Troubleshooting Dependency Issues

    Even with all the tools that have been discussed, there come times when a package does not compile, or may not load, or perhaps doesn't run properly because of some dependency issues. These problems can be as simple as downloading some small package, or it may require a lot of digging through documentation, log files and web searches. Sometimes the best thing to do is to remove the package and start all over again.

    If the package is being built from scratch, verify that the proper compiler version and supporting libraries are installed. If there are issues with a particular version of a compiler or library it often will mention that in a README, or INSTALL text file, which you should read prior to attempting any build.

    Sometimes access to a remote server gets dropped in the middle of a download, and even though the download appears to complete, there may be issues with the file that was downloaded. Checking the checksum files once the download is complete can save a lot of time.

    yum and apt Dependencies

    When using a package manager it might be best to configure it to automatically download all dependencies, so that you don't run into surprises when you attempt to run the software. Otherwise the person installing the software needs to be diligent to know which version of which software needs to be installed. This creates a lot of extra work, and increases the opportunity for dependency issues to wreak havoc.

    Dependency Issue Guidelines

    Software Dependency and Repository Issues

    Use the tools provided by the package manager to troubleshoot dependencies and repositories:

    • rpm -V [ PACKAGE_NAME ] will verify that all of the required pieces of the package are installed.
    • rpm -qR [ PACKAGE_NAME ] or yum deplist [ PACKAGE_NAME ] can be used to discover the dependencies.
    • apt show [ PACKAGE_NAME ] will provide a LOT of information...maybe a bit too much, but it does show the dependencies.
    • There is apt-cache depends [ PACKAGE_NAME ] which provides more succinct output of the packages' dependencies.
    • apt-rdepends -r [ PACKAGE_NAME ] is a command that provides dependency information AND reverse dependency information - what other packages rely on this one.
    • dpkg -I path_to_deb_file will determine the dependency for a .deb file.

    Patch and Update Issues

    Most software providers will, at various times, provide patches and updates. Be aware of apply patches without understanding what they do, what problems they resolve, and whether your system needs to apply the patch.

    • Read whatever documentation the patch contains, and make sure you know the issue(s) the patch resolves. Check to see if you can recreate the problem before you add a patch.
    • If you have the capability apply the patch and test it prior to applying the patch to a production system.
    • Always know how to back out of a patch, or have a plan in case there are unforeseen issues after applying the patch.
    • Make sure to check software versions if any are specified in the patch documentation.

    Compiler and Library Issues

    • As stated above, read the documentation for any known compiler or library issues. Ensure the system has the proper versions of the compiler, libraries and other software.
    • System level software may have kernel dependencies, and may require you to be root to install/update software.
    • Use the ldd command previously discussed.
    • If there is the capability, compile and test the software on a test system prior to loading it on a production system.

    This page titled 11-G.7: Software Dependency Troubleshooting is shared under a CC BY-NC 4.0 license and was authored, remixed, and/or curated by Patrick McClanahan.

    • Was this article helpful?