凝望长空 发表于 2012-01-14 22:20

更新你的OEL


更新你的OEL







windows下有自动更新的功能,linux下也有,对应的RHL你需要有购买服务,CentOS则免费更新,那么OEL呢,也是有的,只要你配置好了。
参考:http://docs.oracle.com/cd/E21928_01/html/821-3629/gkgfr.html。我使用的是第2种方式:使用 Oracle 公共 yum 服务器和 yum 客户机来安装更新,注意这个方式只能按照原有安装包内包含的内容,如果你需要安装而外的包和内容的话,采用第1中方式,掏钱吧。
# cat /etc/issue
Oracle Linux Server release 5.7
Kernel \r on an \m

# cd cd /etc/yum.repos.d
-bash: cd: cd: 没有那个文件或目录
# cd /etc/yum.repos.d
# wget http://public-yum.oracle.com/public-yum-el5.repo
--2012-01-14 15:30:49--http://public-yum.oracle.com/public-yum-el5.repo
正在解析主机 public-yum.oracle.com... 141.146.44.34
Connecting to public-yum.oracle.com|141.146.44.34|:80... 已连接。
已发出 HTTP 请求,正在等待回应... 200 OK
长度:2533 (2.5K)
Saving to: `public-yum-el5.repo'

100%[==========================================================================>] 2,533       --.-K/s   in 0s      

2012-01-14 15:30:50 (155 MB/s) - `public-yum-el5.repo' saved

# ls
public-yum-el5.repo
将public-yum-el5.repo文件中的enabled=0改成enabled=1保存退出vi,这个地方最好只把你需要使用的更新源修改启用即可。
# yum list
将开始更新资料库,这个过程可以需要花费几分钟的时间,更新完成后就可以安装了,比如我要安装vsftpd。
# rpm -qa | grep vsftpd
# yum install vsftpd
Loaded plugins: rhnplugin, security
This system is not registered with ULN.
ULN support will be disabled.
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package vsftpd.i386 0:2.0.5-21.el5 set to be updated
ol5_u7_base/filelists                                                                                                                                          | 2.8 MB   03:07   
--> Finished Dependency Resolution

Dependencies Resolved

======================================================================================================================================================================================
Package                                  Arch                                 Version                                          Repository                                     Size
======================================================================================================================================================================================
Installing:
vsftpd                                 i386                                 2.0.5-21.el5                                     ol5_u7_base                                 142 k

Transaction Summary
======================================================================================================================================================================================
Install       1 Package(s)
Upgrade       0 Package(s)

Total download size: 142 k
Is this ok :
Downloading Packages:
vsftpd-2.0.5-21.el5.i386.rpm                                                                                                                                 | 142 kB   00:07   
warning: rpmts_HdrFromFdno: Header V3 DSA signature: NOKEY, key ID 1e5e0159
ol5_u7_base/gpgkey                                                                                                                                             | 1.4 kB   00:00   
Importing GPG key 0x1E5E0159 "Oracle OSS group (Open Source Software group) <build@oss.oracle.com>" from http://public-yum.oracle.com/RPM-GPG-KEY-oracle-el5
Is this ok : y
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
   Installing   : vsftpd                                                                                                                                                         1/1

Installed:
   vsftpd.i386 0:2.0.5-21.el5                                                                                                                                                         

Complete!
ok,已经安装完成了,检查下:
# rpm -qa | grep vsftpd
vsftpd-2.0.5-21.el5
#
cool,这样再也不用到处找安装包了吧,而且还可以自动解决依赖性的问题。
-The End-

如果有一天21 发表于 2012-01-19 21:57

谢谢分享
页: [1]
查看完整版本: 更新你的OEL