Yum on Linux System

本文详细介绍了使用Yum命令从源码到安装CentOS软件包的全过程,包括下载文件、解压、安装RPM包、配置yum源、导入GPG密钥等步骤,最终测试安装成功。
Yum on Linux System

download the file
>wget http://www.parallels.com.cn/downloads/Prima/Tools/yum_forAS4.tar.gz

unzip the file
>tar zxvf yum_forAS4.tar.gz
>cd yum_forAS4

Install all the rpm packages
>sudo rpm -ivh *.rpm

copy the repo file to the right directory
>sudo cp CentOS-Base.repo /etc/yum.repos.d/

import the GPG key
>sudo rpm --import http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-4

try to download and install one software to test it.
>sudo yum install httpd-devel

references:
http://blog.youkuaiyun.com/wade23/article/details/5440633
http://peiyan.blog.51cto.com/344889/177666
### YUM Command Usage and Troubleshooting #### Understanding the Basics of YUM YUM (Yellowdog Updater Modified) serves as an interactive and automated update program for RPM-based systems like Red Hat Enterprise Linux, CentOS, Fedora, etc. This utility can be employed not only to maintain single installations but also manage server farms with thousands of computers. For daily operations, users often interact with `yum` through simple commands such as installing (`install`), updating (`update`), removing (`remove`) packages or groups of software, searching package databases (`search`), listing installed packages on your system (`list`), checking which updates are available (`check-update`), among others[^1]. #### Common Issues and Solutions Related to YUM Configuration Files When encountering issues related to YUM's configuration file format or path errors, it is crucial to inspect `/etc/yum.repos.d/*.repo`. These files define repositories from where you download packages. Errors within these configurations may prevent successful installation or updates due to malformed entries that do not conform to expected syntax rules specified by YUM. To resolve this issue: - Verify each line inside `.repo` files adheres strictly to key=value pairs without any extraneous characters. - Ensure all repository URLs point correctly towards valid sources accessible over network connections. - Remove duplicate definitions pointing at identical locations under different names since they might cause conflicts during synchronization processes. #### Using Man Pages Effectively The `man` command plays a pivotal role in providing access to extensive manuals covering almost every aspect concerning Linux distributions including those associated specifically with tools similar to YUM[^2]. By invoking `man yum`, one gains insight into official guidelines regarding proper utilization alongside advanced options less commonly known yet potentially beneficial depending upon specific administrative needs. ```bash $ man yum ``` This invocation opens up comprehensive documentation directly within terminal interfaces allowing administrators to browse sections pertinent to their current tasks efficiently while ensuring accuracy when executing subsequent actions based off acquired knowledge presented therein. --related questions-- 1. How does one verify the integrity of existing .repo files? 2. What steps should be taken before adding new custom repositories using YUM? 3. Can you provide examples demonstrating how to use some lesser-known flags supported by YUM? 4. In what scenarios would consulting MAN pages prove more advantageous compared against online resources?
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值