当前位置: 首页 > news >正文

使用freebsd-update 升级FreeBSD从FreeBSD 14.1-RELEASE-p5到FreeBSD 14.2-RELEASE

使用freebsd-update 升级FreeBSD从FreeBSD 14.1-RELEASE-p5到FreeBSD 14.2-RELEASE

先升级小版本

准备升级前,先把当前的小版本升级到顶,比如现在是FreeBSD 14.1-RELEASE-p5,先升级到最新的14.1版本,使用命令:

# freebsd-update fetch
# freebsd-update install

如果不顺利,可能需要源码更新。

几分钟之后升级完成。

但是uname -a看版本,还没变。那当然啊,还没重启啊.

升级到14.2版本

sudo freebsd-update upgrade -r 14.2-RELEASE

提示

src component not installed, skipped
Looking up update.FreeBSD.org mirrors... 3 mirrors found.
Fetching metadata signature for 14.1-RELEASE from update2.freebsd.org... done.
Fetching metadata index... done.
Fetching 1 metadata patches. done.
Applying metadata patches... done.
Inspecting system... done.

The following components of FreeBSD seem to be installed:
kernel/generic kernel/generic-dbg world/base world/lib32

The following components of FreeBSD do not seem to be installed:
world/base-dbg world/lib32-dbg

Does this look reasonable (y/n)? y

Fetching metadata signature for 14.2-RELEASE from update1.freebsd.org... done.
Fetching metadata index... done.
Fetching 1 metadata patches. done.
Applying metadata patches... done.
Fetching 1 metadata files... done.
Inspecting system... done.
Fetching files from 14.1-RELEASE for merging... done.
Preparing to download files... done.
Fetching 4047 patches.....10....20....30....40....50....60....70...

OK!升级完成!

The following files will be updated as part of updating to
14.2-RELEASE-p3:
/bin/[
/bin/cat
/bin/chflags
/bin/chio
/bin/chmod
/bin/cp
/bin/cpuset
/bin/csh
/bin/date
/bin/dd
/bin/df
/bin/domainname
/bin/echo
/bin/ed
/bin/expr
/bin/freebsd-version
/bin/getfacl
/bin/hostname
/bin/kenv
/bin/kill
/bin/link
/bin/ln
/bin/ls
/bin/mkdir
/bin/mv
/bin/nproc
/bin/pax
To install the downloaded upgrades, run 'freebsd-update [options] install'.

把最主要的资料打包备份

tar -xzvf backup.tar.gz backup/

scp backup.tar.gz 192.168.1.5:/home/xxx/

执行freebsd-update install

# freebsd-update install

重启!

# shutdown -r now

重启后uname -a 显示还是老版本:FreeBSD x250 14.1-RELEASE-p7 FreeBSD 14.1-RELEASE-p7 GENERIC amd64 。之所以这样,是因为重启之前忘记执行freebsd-update install 了。

总之在执行freebsd-update install之后还需要一次重启,重启之后还需要一次执行freebsd-update install

重启后再执行一次

# freebsd-update install

手册

官方升级手册:Chapter 26. Updating and Upgrading FreeBSD | FreeBSD Documentation Portal

Upgrades from one minor version of FreeBSD to another are called minor version upgrades. An example:

  • FreeBSD 13.1 to 13.2.

Major version upgrades increase the major version number. An example:

  • FreeBSD 13.2 to 14.0.

Both types of upgrade can be performed by providing freebsd-update with a release version target.

相关文章:

  • 现代处理器的调度策略,调度优先级,亲和性是什么意思?
  • Python中for循环及其相关函数range(), zip(), enumerate()等
  • Docker部署jenkins
  • 深度解析:如何高效识别并定位问题关键词
  • C#打开文件及目录脚本
  • Ubuntu 系统深度清理:彻底卸载 Redis 服务及残留配置
  • 工程师 - 场效应管分类
  • Python使用闭包实现不修改源码添加功能详解
  • 权限的概念
  • 明明包含了头文件,为何还是显示未定义错误?
  • 鸢尾花分类的6种机器学习方法综合分析与实现
  • compose map 源码解析
  • Quartus II的IP核调用及仿真测试
  • FileInputStream 详解与记忆方法
  • Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks
  • GPT模型架构与文本生成技术深度解析
  • dbt:新一代数据转换工具
  • 程序化广告行业(78/89):多因素交织下的行业剖析与展望
  • Linux-内核驱动-中断-key
  • 【Sequelize】迁移和种子
  • 网站开发公用头部/广告推广投放平台
  • 盘龙网站建设/网站营销推广
  • 网站建设服务费做什么分录/怎样在百度上做广告推广
  • 北京丰台区网站建设/seo排名推广工具
  • 互联网技术专业学什么/沈阳seo按天计费
  • 网站解析域名/外贸网站建设公司