CentOS 9 开局配置
CentOS 9 开局配置
CentOS 9 发布有几年了,一直没有尝试使用,CentOS 9 有一些变动。

查看系统基础信息
# 查看系统基础信息
[root@chenby ~]# neofetch
.. cby@chenby
.PLTJ. ----------
<><><><> OS: CentOS Stream 9 x86_64
KKSSV' 4KKK LJ KKKL.'VSSKK Host: VMware Virtual Platform None
KKV' 4KKKKK LJ KKKKAL 'VKK Kernel: 5.14.0-165.el9.x86_64
V' ' 'VKKKK LJ KKKKV' ' 'V Uptime: 1 min
.4MA.' 'VKK LJ KKV' '.4Mb. Packages: 651 (rpm)
. KKKKKA.' 'V LJ V' '.4KKKKK . Shell: bash 5.1.8
.4D KKKKKKKA.'' LJ ''.4KKKKKKK FA. Resolution: 800x600
<QDD ++++++++++++ ++++++++++++ GFD> Terminal: /dev/pts/0
'VD KKKKKKKK'.. LJ ..'KKKKKKKK FV CPU: AMD Ryzen 9 3950X (32) @ 3.500GHz
' VKKKKK'. .4 LJ K. .'KKKKKV ' GPU: 00:0f.0 VMware SVGA II Adapter
'VK'. .4KK LJ KKA. .'KV' Memory: 375MiB / 7909MiB
A. . .4KKKK LJ KKKKA. . .4
KKA. 'KKKKK LJ KKKKK' .4KK
KKSSA. VKKK LJ KKKV .4SSKK
<><><><>
'MKKM'
''
[root@chenby ~]#
使用国内镜像源
# 使用国内镜像源
cat > /etc/yum.repos.d/centos.repo << EOF
[AppStream]
name=CentOS-\$releasever - AppStream - mirrors.ustc.edu.cn
#failovermethod=priority
baseurl=https://mirrors.ustc.edu.cn/centos-stream/\$stream/AppStream/\$basearch/os/
gpgcheck=1
gpgkey=https://mirrors.ustc.edu.cn/centos-stream/RPM-GPG-KEY-CentOS-Official
[BaseOS]
name=CentOS-\$releasever - BaseOS - mirrors.ustc.edu.cn
#failovermethod=priority
baseurl=https://mirrors.ustc.edu.cn/centos-stream/\$stream/BaseOS/\$basearch/os/
gpgcheck=1
gpgkey=https://mirrors.ustc.edu.cn/centos-stream/RPM-GPG-KEY-CentOS-Official
[CRB]
name=CentOS-\$releasever - CRB - mirrors.ustc.edu.cn
#failovermethod=priority
baseurl=https://mirrors.ustc.edu.cn/centos-stream/\$stream/CRB/\$basearch/os/
gpgcheck=1
gpgkey=https://mirrors.ustc.edu.cn/centos-stream/RPM-GPG-KEY-CentOS-Official
[HighAvailability]
name=CentOS-\$releasever - HighAvailability - mirrors.ustc.edu.cn
#failovermethod=priority
baseurl=https://mirrors.ustc.edu.cn/centos-stream/\$stream/HighAvailability/\$basearch/os/
gpgcheck=1
gpgkey=https://mirrors.ustc.edu.cn/centos-stream/RPM-GPG-KEY-CentOS-Official
[NFV]
name=CentOS-\$releasever - NFV - mirrors.ustc.edu.cn
#failovermethod=priority
baseurl=https://mirrors.ustc.edu.cn/centos-stream/\$stream/NFV/\$basearch/os/
gpgcheck=1
gpgkey=https://mirrors.ustc.edu.cn/centos-stream/RPM-GPG-KEY-CentOS-Official
[RT]
name=CentOS-\$releasever - RT - mirrors.ustc.edu.cn
#failovermethod=priority
baseurl=https://mirrors.ustc.edu.cn/centos-stream/\$stream/RT/\$basearch/os/
gpgcheck=1
gpgkey=https://mirrors.ustc.edu.cn/centos-stream/RPM-GPG-KEY-CentOS-Official
[ResilientStorage]
name=CentOS-\$releasever - ResilientStorage - mirrors.ustc.edu.cn
#failovermethod=priority
baseurl=https://mirrors.ustc.edu.cn/centos-stream/\$stream/ResilientStorage/\$basearch/os/
gpgcheck=1
gpgkey=https://mirrors.ustc.edu.cn/centos-stream/RPM-GPG-KEY-CentOS-Official
EOF
安装epel扩展源
# 安装epel扩展源
sudo yum install -y epel-release
设置为国内源
# 设置为国内源
sudo sed -e 's|^metalink=|#metalink=|g' \
-e 's|^#baseurl=https\?://download.fedoraproject.org/pub/epel/|baseurl=https://mirrors.ustc.edu.cn/epel/|g' \
-e 's|^#baseurl=https\?://download.example/pub/epel/|baseurl=https://mirrors.ustc.edu.cn/epel/|g' \
-i.bak \
/etc/yum.repos.d/epel.repo
sudo sed -e 's|^metalink=|#metalink=|g' \
-e 's|^#baseurl=https\?://download.fedoraproject.org/pub/epel/|baseurl=https://mirrors.ustc.edu.cn/epel/|g' \
-e 's|^#baseurl=https\?://download.example/pub/epel/|baseurl=https://mirrors.ustc.edu.cn/epel/|g' \
-i.bak \
/etc/yum.repos.d/epel-next.repo
更新源信息
# 更新源信息
yum makecache && yum update
配置网卡IP
# 配置网卡IP
nmcli con mod ens160 ipv4.addresses 192.168.1.16/24; nmcli con mod ens160 ipv4.gateway 192.168.1.1; nmcli con mod ens160 ipv4.method manual; nmcli con mod ens160 ipv4.dns "8.8.8.8"; nmcli con up ens160
nmcli con mod ens160 ipv6.addresses 2409:8a10:9e1e:7c10::1233; nmcli con mod ens160 ipv6.gateway 2409:8a10:9e1e:7c10::; nmcli con mod ens160 ipv6.method manual; nmcli con mod ens160 ipv6.dns "2001:4860:4860::8888"; nmcli con up ens160
查看网卡配置
# 查看网卡配置
cat /etc/NetworkManager/system-connections/ens160.nmconnection
[connection]
id=ens160
uuid=23c2f83b-e567-3296-bb0a-433ea216449f
type=ethernet
autoconnect-priority=-999
interface-name=ens160
timestamp=1664101928
[ethernet]
[ipv4]
address1=192.168.1.16/24,192.168.1.1
dns=8.8.8.8;
method=manual
[ipv6]
addr-gen-mode=eui64
address1=2409:8a10:9e1e:7c10::1233/128,2409:8a10:9e1e:7c10::
dns=2001:4860:4860::8888;
method=manual
[proxy]
测试网络
# 测试网络
[root@chenby ~]# ping www.oiox.cn -4
PING (117.161.38.205) 56(84) bytes of data.
64 bytes from 117.161.38.205 (117.161.38.205): icmp_seq=1 ttl=55 time=6.84 ms
64 bytes from 117.161.38.205 (117.161.38.205): icmp_seq=2 ttl=55 time=6.44 ms
64 bytes from 117.161.38.205 (117.161.38.205): icmp_seq=3 ttl=55 time=7.12 ms
--- ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2003ms
rtt min/avg/max/mdev = 6.441/6.800/7.117/0.277 ms
[root@bogon ~]# ping www.oiox.cn -6
PING www.oiox.cn(js-ipv6 (2409:8c10:c00:1404:3b::)) 56 data bytes
64 bytes from js-ipv6 (2409:8c10:c00:1404:3b::): icmp_seq=1 ttl=56 time=5.94 ms
64 bytes from js-ipv6 (2409:8c10:c00:1404:3b::): icmp_seq=2 ttl=56 time=6.11 ms
64 bytes from js-ipv6 (2409:8c10:c00:1404:3b::): icmp_seq=3 ttl=56 time=6.01 ms
--- www.oiox.cn ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2002ms
rtt min/avg/max/mdev = 5.941/6.020/6.107/0.067 ms
[root@chenby ~]#
关于
https://www.oiox.cn/
https://www.oiox.cn/index.php/start-page.html
CSDN、GitHub、知乎、开源中国、思否、掘金、简书、华为云、阿里云、腾讯云、哔哩哔哩、今日头条、新浪微博、个人博客
全网可搜《小陈运维》
文章主要发布于微信公众号
CentOS 9 开局配置的更多相关文章
- CentOS下Apache配置多域名或者多端口映射
CentOS下Apache默认网站根目录为/var/www/html,假如我默认存了一个CI项目在html文件夹里,同时服务器的外网IP为ExampleIp,因为使用的是MVC框架,Apache需开启 ...
- CentOS 6.3配置PPTP VPN的方法
1.验证ppp 用cat命令检查是否开启ppp,一般服务器都是开启的,除了特殊的VPS主机之外. [root@localhost1 /]# cat /dev/ppp cat: /dev/ppp: No ...
- 基于VMware为CentOS 6.5配置两个网卡
为CentOS 6.5配置两块网卡,一块是eth0,一块是eth1,下面以master为例 1.选择“master”-->“编辑虚拟机设置”,如下所示 2.单击“添加”,如下 3.选择“网络适配 ...
- Centos下安装配置LAMP(Linux+Apache+MySQL+PHP)
Centos下安装配置LAMP(Linux+Apache+MySQL+PHP) 关于LAMP的各种知识,还请大家自行百度谷歌,在这里就不详细的介绍了,今天主要是介绍一下在Centos下安装,搭建一 ...
- CentOS 6.5配置nfs服务
CentOS 6.5配置nfs服务 网络文件系统(Network File System,NFS),一种使用于分散式文件系统的协议,由升阳公司开发,于1984年向外公布.功能是通过网络让不同的机器.不 ...
- CentOS安装与配置LNMP
本文PDF文档下载:http://www.coderblog.cn/doc/Install_and_config_LNMP_under_CentOS.pdf 本文EPUB文档下载:http://www ...
- [转]CENTOS 6.5 配置YUM安装NGINX+服务器负载均衡
原文连接: CENTOS 6.5 配置YUM安装NGINX http://blog.sina.com.cn/s/blog_69f467b70102uyux.html 参考博文: Centos下安装. ...
- Tigase XMPP Server在CentOS部署和配置
Tigase XMPP Server在CentOS部署与配置 作者:chszs,转载需注明.博客主页:http://blog.csdn.net/chszs 以下讲述Tigase XMPP Server ...
- CentOS 7安装配置Apache HTTP Server
原文 CentOS 7安装配置Apache HTTP Server RPM安装httpd # yum -yinstall httpd //安装httpd会自动安装一下依赖包: apr apr-ut ...
- Centos中如何配置Texlive2013中文字体的问题
Centos中如何配置Texlive2013中文字体的问题: 第一步是下载你需要的字体,我从windows/fonts中拷贝的比较多,你只要复制你需要的字体即可. 注意只要文件扩展名为ttf的文件,t ...
随机推荐
- gimp脚本.scm一些心得记录
gimp的脚本scm一些心得记录 GIMP 2.10 图像处理脚本推荐GIMP使用脚本使得图像处理的功能更加强大,对于一些常见操作可以通过脚本快速实现.GIMP也出来2.10版本了,比前面的2.8相比 ...
- Python+Django(2)——创建应用程序
新打开一个终端窗口,切换到manage.py所在的目录 激活虚拟环境:ll_env\Scripts\activate 命令startapp appname 让Django建立创建应用程序所需的基础设施 ...
- redis远程连接错误SocketTimeoutException: connect timed out
redis远程连接错误SocketTimeoutException: connect timed out 解决方案: 编辑redis.conf文件(建议将其 先备份 编辑备份文件 启动redis服务时 ...
- swoft-个基于 Swoole 原生协程的PHP 微服务框架
刚才百度了一下swoft框架,官网打不开了,仓库也暂停了.不由感慨.曾经和同事踩了许多坑使用此极其小众的框架完成微服务项目.使用它的唯一目的就是提高程序性能(底层使用了协程),为此大家都学习了很多新知 ...
- CI框架 between and sql语句
1.在文档里没有找到关于where() between and 相应的说明 每次组合查询 要么写原生 要么连续调用where方法. 可用以下方式组合 $condition = array(); $co ...
- percona mongo热备
https://www.percona.com/doc/percona-server-for-mongodb/LATEST/hot-backup.html#hot-backup Hot Backup ...
- 面向对象的练习总结(java)
三次作业总结博客 l 前言 第一次题目集是我刚刚接触java所做的第一套习题,本次题目难度不大,题量较多,涉及的知识点主要是基础的语法知识,出题人的意图是让我们尽快熟悉java的语法,由于事先有c语 ...
- Pintia 7-3 列车调度
7-3 列车调度 (25 分) 火车站的列车调度铁轨的结构如下图所示. 两端分别是一条入口(Entrance)轨道和一条出口(Exit)轨道,它们之间有N条平行的轨道.每趟列车从入口可以选择任意一条轨 ...
- 关于Centos7Th 初始化的一些概述
- 概述 Q:为什么要初始化,什么是初始化? A:一般初始化是根据的后期要部署的业务环境来定制的,新装的系统其自带的软件不够支撑各种开发环境或者运维工作:需要部署和设置对应的安全环境.开发/运维软件. ...
- C++ 几款IDE和编程平台的选择分析
最近闲来无事,就研究了一下几个编程平台和IDE.首先,我必须强调一下,这些方案研究并不一定适用于商业公司内部编程平台选择,而是给个人学习或者闲暇之余把玩用的.主要从以下几个指标考量:使用体验.跨平台. ...