Chinaunix首页 | 论坛 | 博客
  • 博客访问: 374045
  • 博文数量: 49
  • 博客积分: 3380
  • 博客等级: 中校
  • 技术积分: 610
  • 用 户 组: 普通用户
  • 注册时间: 2009-03-10 19:56
文章分类

全部博文(49)

文章存档

2011年(18)

2010年(1)

2009年(30)

我的朋友

分类: LINUX

2009-04-05 15:57:31

  软件包管理工具apt-get原来在ubuntu下面用过一段时间,感觉比较好用,比手动安装软件包要那么多关联需求好多了。最近使用RHEL4,装软件很是不爽,上网搜了搜,果然是有redhat下的apt-get,于是就移植过来用用了。

  安装APT工具:
  # wget
 # rpm -Uvh apt.i386.rpm

  其它的主要就 是设置sources.list的问题了。进入/etc/apt/sources.list.d/目录下设置一些源就OK了。

  网上找的一些源如下:

#dag.list
rpm afs/italia/project/linux/cern/slc302/i386/apt os updates extras
rpm redhat/dag/el3/i386 dag
rpm-src redhat/dag/el3/i386 dag
rpm redhat/el3/en/i386 dag
rpm-src redhat/el3/en/i386 dag

如果是KDE的一些软件,下面的源比较有用:

#kde.list
rpm apt/fedora/3.0 stable
rpm apt/fedora/all stable
rpm apt/kde-redhat/3.0 stable unstable
rpm apt/kde-redhat/all stable unstable

如果需要更多Java相关软件,则:

#vi /etc/apt/sources.list.d/jpackage.list

rpm redhat/jpackage/redhat-es-3/i386 free devel
rpm-src redhat/jpackage/redhat-es-3/i386 free devel
rpm redhat/jpackage/redhat-es-3/generic free devel
rpm-src redhat/jpackage/redhat-es-3/generic free devel

比较好用的是CERN的linux站点,如下:

rpm cern/slc30X/i386/apt os updates extras
rpm-src cern/slc30X/i386/apt os updates extras
rpm Linux/packages/scientificlinux/30x/i386/apt-rpm os updates
rpm-src Linux/packages/scientificlinux/30x/i386/apt-rpm os updates
rpm Linux/distributions/scientificlinux/30x/i386/apt-rpm os updates
rpm-src Linux/distributions/scientificlinux/30x/i386/apt-rpm os updates
rpm ftp/mirror/scientificlinux/30x/i386/apt-rpm os updates
rpm-src ftp/mirror/scientificlinux/30x/i386/apt-rpm os updates
rpm /linux/scientific/30x/i386/apt-rpm os updates
rpm-src /linux/scientific/30x/i386/apt-rpm os updates

保存退出后

#apt-get update
#apt-get upgrade
#apt-get check  //检查依赖性
#apt-get -f install // 解决依赖性问题

然后apt-get install XXX 就可以安装需要的软件包啦。

如果要安装某工具,比如说iftop,可以这样:
#apt-cache search iftop   
#apt-get install iftop
apt自动解决依赖性问题,方便得很。

阅读(23307) | 评论(1) | 转发(0) |
给主人留下些什么吧!~~

q_T_p2012-01-16 10:29:12

wget http://redhat.uni-klu.ac.at/el3/apt.i386.rpm
--2012-01-15 21:23:45--  http://redhat.uni-klu.ac.at/el3/apt.i386.rpm
Resolving redhat.uni-klu.ac.at... failed: Name or service not known.
wget: unable to resolve host address “redhat.uni-klu.ac.at”