zoukankan      html  css  js  c++  java
  • 包末安装完全时,出错信息解决办法

    包末安装完全时,出错信息解决办法

    有的问题 apt-get 解决不了,必须使用 aptitude 解决,有的问题,用 aptitude 解决不了,必须使用 apt-get

    aptitude 解决得更好的地方: install, remove, reinstall(apt-get无此功能), show(apt-get无此功能), search(apt-get无此功能), hold(apt-get无此功能), unhold(apt-get无此功能),

    apt-get 解决得更好的地方: source(aptitude无此功能), build-dep (低版本的aptitude没有build-dep功能)

    apt-get 跟 aptitude 没什么区别的地方:update, upgrade (apt-get upgrade=aptitude safe-upgrade, apt-get dist-upgrade=aptitude full-upgrgade)

    其实差不多,不存在谁解决依赖关系更好的说法,apt-get的source更方便,aptiude的hold/unhold比较方便


    apt-get的action
    代码:
    autoclean        build-dep        clean            dselect-upgrade  purge            source           upgrade
    autoremove       check            dist-upgrade     install          remove           update           


    apt-get的option,reinstall是可以的
    代码:
    --assume-yes             --dry-run                --list-cleanup           --print-uris             --tar-only
    --auto-remove            --fix-broken             --no-act                 --purge                  --trivial-only
    --build                  --fix-missing            --no-download            --quiet                  --version
    --compile                --force-yes              --no-install-recommends  --recon                  --yes
    --config-file            --help                   --no-remove              --reinstall             
    --default-release        --ignore-hold            --no-upgrade             --show-upgraded         
    --diff-only              --ignore-missing         --only-source            --simulate               
    --download-only          --just-print             --option                 --target-release   



    aptitude的action
    代码:
    autoclean       dist-upgrade    full-upgrade    markauto        safe-upgrade    unmarkauto      why-not         
    build-dep       download        hold            purge           search          update         
    changelog       forbid-version  install         reinstall       show            upgrade         
    clean           forget-new      keep-all        remove          unhold          why


    aptitude的option
    代码:
    --assume-yes          --prompt              --show-versions       --verbose             --without-suggests
    --display-format      --purge-unused        --simulate            --version             --with-recommends
    --download-only       --schedule-only       --sort                --width               --with-suggests
    --help                --show-deps           --target-release      --without-recommends 

    问题情况:安装某个软件包时,发现某个软件包的依赖包未按装。但是这个时候不大算安装该软件包,通过apt-get update发现仍在提示需安装该软件包的依赖。

    用aptitude unhold停止该安装。

    ubunto linux 下包未安装完全导致的错误,例如java


    You might want to run `apt-get -f install' to correct these:
    The following packages have unmet dependencies:
    sun-java6-jre: Depends: sun-java6-bin (= 6-00-2ubuntu2) but it is not going to be installed or
                              ia32-sun-java6-bin (= 6-00-2ubuntu2) but it is not installable
    E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

    解决方法:
    sudo apt-get install -f


    apt-get使用参考:

    apt-cache search # ——(package 搜索包)
    apt-cache show #——(package 获取包的相关信息,如说明、大小、版本等)
    sudo apt-get install # ——(package 安装包)
    sudo apt-get install # —–(package - - reinstall 重新安装包)
    sudo apt-get -f install # —–(强制安装?#”-f = –fix-missing”当是修复安装吧…)
    sudo apt-get remove #—–(package 删除包)
    sudo apt-get remove - - purge # ——(package 删除包,包括删除配置文件等)
    sudo apt-get autoremove –purge # —-(package 删除包及其依赖的软件包+配置文件等(只对6.10有效,强烈推荐))
    sudo apt-get update #——更新源
    sudo apt-get upgrade #——更新已安装的包
    sudo apt-get dist-upgrade # ———升级系统
    sudo apt-get dselect-upgrade #——使用 dselect 升级
    apt-cache depends #——-(package 了解使用依赖)
    apt-cache rdepends # ——(package 了解某个具体的依赖?#当是查看该包被哪些包依赖吧…)
    sudo apt-get build-dep # ——(package 安装相关的编译环境)
    apt-get source #——(package 下载该包的源代码)
    sudo apt-get clean && sudo apt-get autoclean # ——–清理下载文件的存档 && 只清理过时的包
    sudo apt-get check #——-检查是否有损坏的依赖

  • 相关阅读:
    Python代码优化概要
    OllyDbg 使用笔记 (一)
    Java报表FineReport在医院院长查询分析系统中有什么用
    MongoDB下载安装測试及使用
    你不可能讲清楚的4个开源协议!!!
    MR之SequenceFile具体解释
    深入浅出AOP(四)--AOP的实现步骤
    SRM 587 Div II L3:ThreeColorabilityEasyy
    转义及编码(u, x)
    转义及编码(u, x)
  • 原文地址:https://www.cnblogs.com/alphaqiu/p/2475510.html
Copyright © 2011-2022 走看看