Rocky Linux
Rocky Linux 是由 CentOS 联合创始人 Gregory Kurtzer 在 CentOS 传统版终止后发起的 RHEL 兼容发行版。它以”社区驱动、由社区拥有”为核心理念,迅速成为最受欢迎的 CentOS 替代品之一。
Gregory Kurtzer 与 CentOS
Section titled “Gregory Kurtzer 与 CentOS”Gregory Kurtzer 是 CentOS 项目的联合创始人之一。2004 年,他参与创建了 CentOS,旨在为社区提供免费的 RHEL 兼容发行版。后来他离开了 CentOS 项目,专注于高性能计算领域。
Rocky Linux 的诞生
Section titled “Rocky Linux 的诞生”2020 年 12 月,Red Hat 宣布 CentOS Linux 8 提前 EOL 的消息发布后,Kurtzer 在同一天的 CentOS 邮件列表中宣布将创建一个新项目来延续 CentOS 的原始使命。
项目以已故的 CentOS 联合创始人 Rocky McGaugh 的名字命名为 Rocky Linux,以纪念他对社区的贡献。
| 时间 | 事件 |
|---|---|
| 2020-12 | 项目宣布 |
| 2021-04 | Rocky Linux 8.3 RC 发布 |
| 2021-06 | Rocky Linux 8.4 正式发布(GA) |
| 2022-07 | Rocky Linux 9.0 发布 |
| 2025 | Rocky Linux 10 发布 |
Rocky Enterprise Software Foundation (RESF)
Section titled “Rocky Enterprise Software Foundation (RESF)”Rocky Linux 由 Rocky Enterprise Software Foundation (RESF) 管理,这是一个以公益为目的的组织。
RESF 采用团队制的扁平化治理结构:
- Leadership Team:项目整体方向和决策
- Release Engineering:版本发布和构建系统
- Infrastructure:基础设施管理
- Design:品牌和视觉设计
- Documentation:文档维护
- Testing:质量保证和测试
- Security:安全响应
- 社区拥有,社区驱动
- 永不被单一公司控制
- 代码、构建系统、基础设施全部开源
- 透明的决策过程
RHEL 兼容策略
Section titled “RHEL 兼容策略”Rocky Linux 的兼容目标是 bug-for-bug compatible(Bug 级兼容)——即不仅功能一致,连已知的 Bug 行为也保持一致。
2023 年 Red Hat 限制 RHEL SRPM 直接访问后,Rocky Linux 通过以下方式获取源代码:
- CentOS Stream git 仓库
- UBI(Universal Base Image)容器
- 付费 RHEL 订阅获取的 SRPM(遵守 GPL 许可证)
- 公开可用的源代码
Rocky Linux 团队强调其做法完全符合开源许可证的规定。
Rocky Linux 维护了一套 RHEL 兼容性测试套件,确保:
- 所有 RHEL RPM 包均可在 Rocky Linux 上安装
- ABI/API 完全一致
- 系统行为与 RHEL 一致
Peridot 构建系统
Section titled “Peridot 构建系统”Peridot 是 Rocky Linux 自主开发的云原生构建系统,完全开源。
- 基于 Kubernetes 的分布式构建
- 支持多架构并行构建(x86_64、aarch64 等)
- 完整的构建溯源和透明性
- 任何人都可以部署和审计
为什么自建构建系统
Section titled “为什么自建构建系统”传统的 EL 重编译项目通常使用 Koji(Fedora/CentOS 的构建系统)。Rocky Linux 选择自建 Peridot 是为了:
- 实现完全的构建透明性
- 避免对单一上游工具的依赖
- 支持更灵活的构建管道
- 使社区成员能够独立验证构建结果
# Peridot 源码https://github.com/rocky-linux/peridotmigrate2rocky
Section titled “migrate2rocky”migrate2rocky 是将现有 EL 系统迁移到 Rocky Linux 的官方工具:
# 下载迁移脚本curl -O https://raw.githubusercontent.com/rocky-linux/rocky-tools/main/migrate2rocky/migrate2rocky.sh
# 执行迁移(从 CentOS Linux 8、AlmaLinux 8、Oracle Linux 8 等)sudo bash migrate2rocky.sh -r
# 迁移完成后重启sudo reboot支持的迁移源:
- CentOS Linux 8
- AlmaLinux 8/9
- Oracle Linux 8/9
- RHEL 8/9(需取消注册)
迁移注意事项
Section titled “迁移注意事项”- 迁移前务必备份重要数据
- 检查第三方仓库的兼容性
- 如果使用了 CentOS SIG 仓库,需确认 Rocky Linux 是否有对应仓库
- 迁移后运行
dnf distro-sync确保所有包同步
获取 Rocky Linux
Section titled “获取 Rocky Linux”提供的镜像类型:
- DVD:完整安装镜像
- Minimal:最小化安装
- Boot:网络安装引导
- Cloud Images:GenericCloud、EC2、Azure、GCP
- Container Images:Docker Hub、Quay.io
- Live Images:GNOME、KDE、XFCE 桌面
安装后基本配置
Section titled “安装后基本配置”# 查看系统版本cat /etc/rocky-release
# 更新系统sudo dnf update -y
# 启用 CRB 仓库sudo dnf config-manager --set-enabled crb
# 安装 EPELsudo dnf install -y epel-release
# 安装常用工具sudo dnf install -y vim wget curl tar bash-completion| 仓库 | 说明 | 默认启用 |
|---|---|---|
| baseos | 核心系统包 | 是 |
| appstream | 应用程序和运行时 | 是 |
| crb | 开发者工具和库 | 否 |
| extras | 额外工具 | 是 |
| highavailability | 高可用组件 | 否 |
| nfv | 网络功能虚拟化 | 否 |
| plus | Rocky 特有增强包 | 否 |
| rt | 实时内核 | 否 |
Rocky Linux 特有仓库
Section titled “Rocky Linux 特有仓库”plus 仓库包含一些 Rocky Linux 特有的增强包,例如:
# 启用 plus 仓库sudo dnf config-manager --set-enabled plus
# 查看 plus 仓库中的包sudo dnf repo-pkgs plus list商业支持:CIQ
Section titled “商业支持:CIQ”CIQ (Ctrl IQ) 是 Gregory Kurtzer 创办的公司,提供 Rocky Linux 的商业支持:
- 企业级技术支持
- 安全加固和合规
- 性能优化
- 迁移服务
- 培训和咨询
CIQ 还提供 Apptainer(前身 Singularity)等 HPC 领域的解决方案。
- 论坛:forums.rockylinux.org
- 聊天:Mattermost(chat.rockylinux.org)
- 代码:github.com/rocky-linux
- Wiki:wiki.rockylinux.org
- x86_64
- aarch64 (ARM64)
- ppc64le (IBM POWER)
- s390x (IBM Z)
SIG(Special Interest Groups)
Section titled “SIG(Special Interest Groups)”Rocky Linux 也有自己的 SIG 系统:
- Kernel SIG:内核定制和实时内核
- Cloud SIG:云镜像和集成
- Desktop SIG:桌面环境
- HPC SIG:高性能计算
- Security SIG:安全加固
Rocky Linux 特别适合以下场景:
- CentOS 迁移:从传统 CentOS Linux 平滑迁移
- 生产服务器:Web 服务、数据库、应用服务器
- 企业 IT:需要免费 RHEL 兼容系统的企业
- 科研和教育:学术机构的计算基础设施
- 容器宿主机:运行 Podman 或 Kubernetes 的主机系统
Rocky Linux 以延续传统 CentOS 精神为使命,通过开放的构建系统和独立的基金会治理,赢得了社区的广泛信任。其 Bug 级兼容的目标、完全开源的 Peridot 构建系统和活跃的社区,使其成为 RHEL 兼容发行版中的有力竞争者。
版本与支持周期
Section titled “版本与支持周期”| Rocky Linux 版本 | 基于 RHEL | 发布时间 | 维护支持截止 |
|---|---|---|---|
| Rocky Linux 8 | RHEL 8.x | 2021-06 | 2029-05 |
| Rocky Linux 9 | RHEL 9.x | 2022-07 | 2032-05 |
| Rocky Linux 10 | RHEL 10.x | 2025 | 2035 |
Rocky Linux 10 在 2025 年跟随 RHEL 10 正式发布,带来 Python 3.12 默认版本、Podman 5.x、模块化弃用等新特性(包管理器仍是 DNF 4.20)。
- EL 11 前瞻 — Rocky Linux 11 发布时间预测与 RHEL 11 规划动态