如何安装openEuler系统?

RHEL-Like

1 基础知识

1.1 系统简介

– openEuler是一款开源操作系统,中文翻译为欧拉
– openEuler的当前内核源于Linux
– openEuler支持鲲鹏及其它多种处理器,能够充分释放计算芯片的潜能
– openEuler是由全球开源贡献者构建的高效、稳定、安全的开源操作系统
– openEuler适用于数据库、大数据、云计算、人工智能等应用场景
– openEuler是一个面向全球的操作系统开源社区
– openEuler通过社区合作,打造创新平台,构建支持多处理器架构、统一和开放的操作系统
– openEuler推动软硬件应用生态繁荣发展
注:笔者使用后评估openEuler可作为centOS的替代

1.2 发布版本

– 创新版,支持Linux爱好者创新(一般半年发布一次)例如,openEuler 20.09
– LTS版,属于稳定版本(一般两年发布一次),例如,openEuler LTS 20.03

1.3 安装硬件要求

部件名称 最小硬件要求 说明
架构
  • AArch64
  • x86_64
  • 支持Arm的64位架构。
  • 支持Intel的x86 64位架构。
内存
  • 华为鲲鹏920系列CPU
  • Intel® Xeon®处理器
CPU 不小于4GB(为了获得更好的应用体验,建议不小于8GB)
硬盘 为了获得更好的应用体验,建议不小于120GB 支持IDE、SATA、SAS等接口的硬盘。

2 最佳实践

2.1 从光盘引导

插入光盘并选择从光盘引导(由于不同的机器或虚拟机操作不同,这里不详述)

2.2 安装openEuler

2.2.1 选择安装向导


如上图所示:
选择【Install openEuler xxx】然后按下回车

2.2.2 选择语言


如上图所示:
选择你习惯的系统语言与(建议保留默认),单击【Continue】即可

2.2.3 安装的配置


如上图所示:
选择【Installtion Destination】,窗口显示如下,

如上图所示:
选择安装系统的目标磁盘(分区使用默认分区),单击【Done】返回之前的界面

如上图所示,
选择【Root Password】
窗口显示如下,

如上图所示,
输入两次Root密码,单击【Done】返回上一个界面

如上图所示,
选择【Time & Date】
窗口显示如下,

如上图所示:
选择你当地的时区,单击【Done】返回上一个界面
然后单击【Begin Installation】即开始安装

2.2.4 安装重启


如上图所示,
当安装完成时,单击【Reboot】即可完成安装并从操作系统引导

2.2.5 登录系统


如上图所示,
输入登录的用户名“root”
输入之前设置的登录密码(无回显)
按下【Enter】即可完成系统登录
另外,登录完成后,如需修改root密码请使用如下命令,

passwd

2.3 配置openEuler

2.3.1 配置静态IP

nmcli connection show
nmcli con delete ens33
nmcli device
nmcli con add ifname ens33 con-name ens33 type ethernet
nmcli con modify ens33 ipv4.addresses "10.168.0.70/24"
nmcli con modify ens33 ipv4.gateway 10.168.0.1
nmcli con modify ens33 ipv4.dns "202.96.128.86 202.96.128.166"
nmcli con modify ens33 ipv4.method manual
nmcli con modify ens33 ipv6.method ignore
nmcli con modify ens33 conconnect.autoconnect yes
nmcli con modify ens33 connect.autoconnect yes
nmcli con up ens33

2.3.2 配置服务器名称

hostnamectl set-hostname openeuler.cmdschool.org

2.3.3 自定义源服务器

mkdir /etc/yum.repos.d/backup
mv /etc/yum.repos.d/*.repo /etc/yum.repos.d/backup/
vi /etc/yum.repos.d/openEuler.repo

加入如下配置,

#generic-repos is licensed under the Mulan PSL v2.
#You can use this software according to the terms and conditions of the Mulan PSL v2.
#You may obtain a copy of Mulan PSL v2 at:
#    https://license.coscl.org.cn/MulanPSL2
#THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR
#IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR FIT FOR A PARTICULAR
#PURPOSE.
#See the Mulan PSL v2 for more details.

[OS]
name=OS
baseurl=https://mirrors.aliyun.com/openeuler/openEuler-21.03/OS/$basearch/
enabled=1
gpgcheck=1
gpgkey=https://mirrors.aliyun.com/openeuler/openEuler-21.03/OS/$basearch/RPM-GPG-KEY-openEuler

[everything]
name=everything
baseurl=https://mirrors.aliyun.com/openeuler/openEuler-21.03/everything/$basearch/
enabled=1
gpgcheck=1
gpgkey=https://mirrors.aliyun.com/openeuler/openEuler-21.03/everything/$basearch/RPM-GPG-KEY-openEuler

[EPOL]
name=EPOL
baseurl=https://mirrors.aliyun.com/openeuler/openEuler-21.03/EPOL/$basearch/
enabled=1
gpgcheck=1
gpgkey=https://mirrors.aliyun.com/openeuler/openEuler-21.03/OS/$basearch/RPM-GPG-KEY-openEuler

[debuginfo]
name=debuginfo
baseurl=https://mirrors.aliyun.com/openeuler/openEuler-21.03/debuginfo/$basearch/
enabled=1
gpgcheck=1
gpgkey=https://mirrors.aliyun.com/openeuler/openEuler-21.03/debuginfo/$basearch/RPM-GPG-KEY-openEuler

[source]
name=source
baseurl=https://mirrors.aliyun.com/openeuler/openEuler-21.03/source/
enabled=1
gpgcheck=1
gpgkey=https://mirrors.aliyun.com/openeuler/openEuler-21.03/source/RPM-GPG-KEY-openEuler

[update]
name=update
baseurl=https://mirrors.aliyun.com/openeuler/openEuler-21.03/update/$basearch/
enabled=1
gpgcheck=1
gpgkey=https://mirrors.aliyun.com/openeuler/openEuler-21.03/OS/$basearch/RPM-GPG-KEY-openEuler

2.3.4 更新系统版本(可选)

dnf update -y

2.3.5 安装常见的工具包

dnf install -y vim wget unzip

2.3.6 配置时间同步服务

dnf install -y chrony
systemctl start chronyd.service
systemctl enable chronyd.service

另外,如果是内网请使用如下命令检查参数是否符合内部所需的定义,

grep ^pool /etc/chrony.conf

默认参数如下,

pool pool.ntp.org iburst

以上修改为内部的时间源服务器即可,另外需要注意时区问题,可用如下命令修改,

timedatectl set-timezone Asia/Shanghai

2.3.7 关闭SELinux(可选)

sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config
setenforce 0

2.3.8 开放服务所需的端口(可选)

firewall-cmd --permanent --add-service http --add-service https
firewall-cmd --reload
firewall-cmd --list-all

注:具体开放哪些服务或端口需要根据不同的需求决定

参阅文档
==================================

系统官网
——————
https://www.openeuler.org/

官方教程
——————
https://docs.openeuler.org/

系统下载地址
——————
https://www.openeuler.org/zh/mirror/list/

没有评论

发表回复

RHEL-Like
如何配置rsyncd服务?

1 前言 一个问题,一篇文章,一出故事。 由于笔者想实现文件通过rsync自动传输,但是又不想使用o …

RHEL-Like
如何用pam_google_authenticator认证模块实现SSH 2FA?

1 前言 一个问题,一篇文章,一出故事。 笔者想开启2FA以便增强SSH服务的安全性,于是便整理此文 …

RHEL-Like
如何升级RHEL clamav杀毒?

1 前言 一个问题,一篇文章,一出故事。 笔者需要卸载旧的病毒软件,然后更新rpm包的病毒软件,于是 …