使用Yum Update更新Fedora,CentOS,RHEL软件包

Yum is popular package management tools between rpm based distributions. In this tutorial we will simply look how update system packages for different distributions like Fedora, CentOS and RHEL .

Yum是基于rpm的发行版之间流行的软件包管理工具。 在本教程中,我们将简单地了解如何针对Fedora,CentOS和RHEL等不同发行版更新系统软件包。

列出已安装的软件包 (List Installed Packages)

Before installing any update best step is listing installed packages. We can list install packages with yum list installed command.

在安装任何更新之前,最好的步骤是列出已安装的软件包。 我们可以使用yum list installed命令列出安装软件包。

$ sudo yum update -y

列出可用更新 (List Available Updates)

We should review upcoming update before installed them into the production servers. We can also use update testing servers to see effects of new updates. We can list available update with the following command.

在将更新安装到生产服务器之前,我们应该查看它们。 我们还可以使用更新测试服务器来查看新更新的效果。 我们可以使用以下命令列出可用的更新。

$ yum list updates

更新百胜餐饮套餐 (Update Yum Packages)

Now the most important part. We will install updates provided by official and third party yum repositories. We will simply use yum update command to update all packages.

现在最重要的部分。 我们将安装官方和第三方yum存储库提供的更新。 我们将只使用yum update命令来更新所有软件包。

$ yum update

无提示更新百胜餐饮套餐 (Update Yum Packages without Prompt)

Previous example will update our packages but will ask if we are sure to update packages. We can simply provide y to this question. But there is more straightforward way where we will provide yes with the -y option to the yum update command like below. This will skip confirmation step and directly install updates.

前面的示例将更新我们的软件包,但会询问我们是否确定要更新软件包。 我们可以简单地向这个问题提供y 。 但是,还有更多直接的方式,我们将提供yes-y选项给yum update像下面的命令。 这将跳过确认步骤,并直接安装更新。

$ yum update -y

检查特定的软件包更新 (Check Specific Package Update)

By default update command will list or update all packages. We can strictly specify the packages we want to update or list like below. In this example we will only update package named ssh .

默认情况下, update命令将列出或更新所有软件包。 我们可以严格指定要更新或列出的软件包,如下所示。 在此示例中,我们将仅更新名为ssh软件包。

$ yum update ssh
LEARN MORE  How To Install and Upgrade RPM Packages In CentOS, RHEL, Fedora, Mandriva
了解更多如何在CentOS,RHEL,Fedora,Mandriva中安装和升级RPM软件包

翻译自: https://www.poftut.com/update-fedora-centos-rhel-packages-yum-update/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值