Ubuntu中apt-get用法
来源:互联网 发布:用手机网络给电脑上网 编辑:程序博客网 时间:2024/06/06 20:38
Ubuntu中apt-get用法
如何在ubuntu下面直接查找想要安装的软件。比如我想安装tomcat.但是我又不知道里
面有哪种版本,也不知道都需要装什么,但是我能 确认我装的是tomcat那么我就可以用搜索命令:例如:$apt-cache search
tomcat,这样就知道ubuntu的软件库里面有tomcat5,那么就可以用$apt-get install tomcat5去安装了APT 源自 Debian GNU/Linux,Debian 在同一个版本编号下,依套件成熟度又分 stable、testing、unstable。
若我们现在用的是 Debina 3.0r2 stable,使用 apt-get upgrade
就可以升级for stable 的软件,而使用 apt-get dist-upgrade 则可以选择将系统由 stable 升级到 testing 或是 unstable,
使用 apt-get upgrade 和 apt-get dist-upgrade 的结果,基本上是一样的,不过apt-get
dist-upgrade 在升级的同时会为了解决相依性而安装新套件,而 apt-get upgrade 并不会,因此要升级的话,建议还是用
apt-get dist-upgrade 较佳
apt-cache search
搜寻:我们可以用这个指令来搜寻升级包,
例如:apt-cache search httpd,
apt-cache depends
相依性:我们可以用这个指令来看到软件包的所有相依性档案,
例如:apt-cache depends httpd,
apt-get install
安装:安装软件包,
例如:apt-get install httpd,这样 apt 就会自动上网下载httpd 回来安装,若httpd 有相依性套件的时候,apt 也会自动下载安装
apt-get clean
清除:当使用 apt-get install 指令安装套件,下载下来的 rpm 会放置於 /var/cache/apt/archives,使用 apt-get clean 指令可以将之清除,避免占用硬碟空间
apt-get remove
移除:例如:apt-get remove httpd,就会移除 httpd 了,假如有相依性套件的时候,apt 也会一并移除
以上这几个指令应该就够用了,若想要得到更进一步的指令,请善用 man:)
apt-get update
更新:这指令是用来取得记录在 /etc/apt/sources.list 内的远端服务器的套件档案清单 在使用 「apt-get dist-upgrade」指令升级套件前,一定要记得先用这条指令将套件档案清单更新
apt-get dist-upgrade
升级:这里的升级主要是根据已有的软件包更新而言,并不是更新整个系统,也可以使用图形界面的新立得包管理器:)
如果没有安装这个管理器的话,可以执行以下指令
apt-get install synaptic
安装完毕后,直接在命令行上敲入synaptic就可以启动了。
如何在ubuntu下面直接查找想要安装的软件。比如我想安装tomcat.但是我又不知道里
面有哪种版本,也不知道都需要装什么,但是我能 确认我装的是tomcat那么我就可以用搜索命令:例如:$apt-cache search
tomcat,这样就知道ubuntu的软件库里面有tomcat5,那么就可以用$apt-get install tomcat5去安装了APT 源自 Debian GNU/Linux,Debian 在同一个版本编号下,依套件成熟度又分 stable、testing、unstable。
若我们现在用的是 Debina 3.0r2 stable,使用 apt-get upgrade
就可以升级for stable 的软件,而使用 apt-get dist-upgrade 则可以选择将系统由 stable 升级到 testing 或是 unstable,
使用 apt-get upgrade 和 apt-get dist-upgrade 的结果,基本上是一样的,不过apt-get
dist-upgrade 在升级的同时会为了解决相依性而安装新套件,而 apt-get upgrade 并不会,因此要升级的话,建议还是用
apt-get dist-upgrade 较佳
apt-cache search
搜寻:我们可以用这个指令来搜寻升级包,
例如:apt-cache search httpd,
apt-cache depends
相依性:我们可以用这个指令来看到软件包的所有相依性档案,
例如:apt-cache depends httpd,
apt-get install
安装:安装软件包,
例如:apt-get install httpd,这样 apt 就会自动上网下载httpd 回来安装,若httpd 有相依性套件的时候,apt 也会自动下载安装
apt-get clean
清除:当使用 apt-get install 指令安装套件,下载下来的 rpm 会放置於 /var/cache/apt/archives,使用 apt-get clean 指令可以将之清除,避免占用硬碟空间
apt-get remove
移除:例如:apt-get remove httpd,就会移除 httpd 了,假如有相依性套件的时候,apt 也会一并移除
以上这几个指令应该就够用了,若想要得到更进一步的指令,请善用 man:)
apt-get update
更新:这指令是用来取得记录在 /etc/apt/sources.list 内的远端服务器的套件档案清单 在使用 「apt-get dist-upgrade」指令升级套件前,一定要记得先用这条指令将套件档案清单更新
apt-get dist-upgrade
升级:这里的升级主要是根据已有的软件包更新而言,并不是更新整个系统,也可以使用图形界面的新立得包管理器:)
如果没有安装这个管理器的话,可以执行以下指令
apt-get install synaptic
安装完毕后,直接在命令行上敲入synaptic就可以启动了。
0 0
- Ubuntu中apt-get用法
- Ubuntu中apt-get用法
- Ubuntu中apt-get用法
- Ubuntu中apt-get用法
- Ubuntu中apt-get用法
- Ubuntu中apt-get用法(转)
- Ubuntu中apt-get的用法
- ubuntu apt-get用法
- ubuntu apt-get用法
- ubuntu apt-get用法
- ubuntu apt-get 用法介绍
- Ubuntu下 apt-get的用法
- Ubuntu下apt-get的用法
- Ubuntu下apt-get的用法
- ubuntu apt-get install 的用法
- ubuntu中apt-get设置网络代理
- Ubuntu中apt-get命令详解
- ubuntu中,apt-get的常用命令
- 解决linux eclipse c++找不到符号或者~~~name a type的问题 && c++11
- NET BEANS 显示英文的界面
- #297 (div.2) C. Ilya and Sticks
- 这篇文章主要介绍了Apache2.4.x版wampserver本地php服务器如何让外网访问及启用.htaccess,需要的朋友可以参考下
- html5读取网页视频时长
- Ubuntu中apt-get用法
- GCD 高级用法(一) dispatch after
- 第四周项目三:用对象数组操作长方柱类
- Android:自定义ProgressBar的样式(背景色/一级、二级进度条颜色)
- android手机网络抓包のfiddler
- 编程范式随课笔记(一)
- 快捷键用法
- java遍历json对象
- vs2010、CUDA5.5、win7 32位配置的一些注意