说说 update 和 upgrade 的区别

对于一个运维站长来说更新和升级是个绕不开的工作,update和upgrade这两个单词一定是都不陌生的,虽然都是升级或者更新的意思,很多站长很难搞懂两个单词到底有什么区别(其实在软件更新方面两个是可以通用的)。最基本的讲,update是“更新”的意思,而upgrade则是“升级”的意思。

updateupgrade2.jpg

upgrade V.S. update:英文解释

update:

  • to make sth more modern by adding new parts
  • to give sb the most recent information about sth

upgrade:

  • to make a piece of machinery, computer system, etc. more powerful
  • to give sb a more important job
  • to give sb a better seat on a plane, room in a hotel, etc. than the one that they have paid for

updateupgrade.jpg

update和upgrade的主要区别

update是更新的意思,主要是为原有的东西增加新功能,或者对已有的部分做出更改等。比如,有人告诉你他换了新手机号码,你在你的手机上删掉了原有的号码并换成新的号码,那么就是update,而不能用upgrade

upgrade是升级的意思,是指从较低级版本升级到高级的版本,这种升级往往伴有新功能的增加,因此也有update的意思。但是,如果是给予某人升职、坐飞机时的升舱等,只能用upgrade,而不能用update。

因此在计算机领域,软件、系统的更新和升级往往是同一个意思,在这种环境中update和upgrade是可以通用的。只是往细了说update是量上的变化,而upgrade质上的变化。

updateupgrade.png

yum updateupgrade的区别?

首先yum updateyum upgrade的功能是一样的,都是将需要更新的package更新至软件源中的最新版。

唯一不同是:yum upgrade会删除旧版本的package,而yum update则会保留。

注意!如果你的某些软件依赖旧版本的package,请使用yum update

附赠关于yum updateupgrade的区别英文最全解释:

yum update originally just did upgrades of packages to new versions.
If, for example, foo-awesome obsoleted foo, yum update wouldn't offer
to upgrade from foo to foo-awesome. Adding the --obsoletes flag to yum
update made it do the extra checks to also offer that upgrade path.
yum upgrade was added as (essentially) an alias for yum --obsoletes
update. Since this is the behavior that almost everyone wants all of
the time, the configuration option obsoletes=1 was added to the
default /etc/yum.conf, making yum update and yum upgrade equivalent on
any recent, stock, Fedora/RHEL/CentOS/etc.

If you want to avoid kernel updates when you're running yum update,
you can just do yum --exclude=kernel* update. If you want automatic
updates on, but you want to avoid automatic kernel upgrades, then
adding the exclude to yum.conf is probably the right answer.

There probably isn't a Right Answer for your question. RHEL and
RHEL-based distributions don't have the same philosophy as the Debian
developers when it comes to updates, so the tools don't encourage the
same sorts of behavior.

最后修改:2018 年 04 月 09 日 11 : 23 AM
如果觉得我的文章对你有用,请随意赞赏

发表评论

7 条评论

  1. GavinZheng

    我只想问问您博客点击出字的插件是哪一款?顺便挂个友链?

    1. 明月登楼
      @GavinZheng

      友链的话,建议到友情链接页面发评论申请即可!目前首页友链已经满了,只能加到内页友链“推荐友链”了!

    2. 明月登楼
      @GavinZheng

      这是一段JS代码,不是插件实现的!你可以参考我博客文章:https://www.imydl.com/wp/5358.html

  2. Koolight

    安卓软件的upgrade,我都禁用了。

    1. 明月登楼
      @Koolight

      呵呵,手机上的感觉该更新还是要更新的!毕竟更新一般都是为了修补漏洞的!

  3. 夏日博客

    很熟悉的两个英语,见到的地方太多了。

    1. 明月登楼
      @夏日博客

      是的,很常见,但是很多人都说不清楚具体的区别!