Centos7报错:Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&infra=stock error was 14: curl#6 - "Could not resolve host: mirrorlist.centos.org; 未知的错误"
一、问题描述
Centos7使用yum命令失效,报错:Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&infra=stock error was 14: curl#6 - "Could not resolve host: mirrorlist.centos.org; 未知的错误"
二、解决方案
查询了好多种方法,有的说是DNS的问题,有的说是防火墙的问题 ...
CentOS 7 yum无法使用解决方法Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=
公众号本文地址,希望老铁浏览支持
https://mp.weixin.qq.com/s/29iT8kZQMjNoyhCywhqcvA
在centos7中使用yum命令时候报错:
Loading mirror speeds from cached hostfile
Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&infra=stock error was
14: curl#6 - "Could not res ...
CentOS-7离线安装policycoreutils-python
1、下载相关安装包
policycoreutils-2.5-34.el7.src.rpm 快速下载地址:https://vault.centos.org/7.9.2009/os/x86_64/Packages/policycoreutils-python-2.5-34.el7.x86_64.rpm
audit-libs-python >= 2.1.3-4 快速下载地址:https://vault.centos.org/7.9.2009/os/x86_64/Packages/audit-libs-python-2.8.5-4.el7.x86_6 ...
解决 CentOS 7 官方 yum 仓库无法使用的最佳实践
一、背景介绍
2024 年 7 月 1 日,在编译基于 CentOS 7.6.1810 镜像的 Dockerfile 过程中,执行 yum install 指令时,遇到了错误:Could not resolve host: mirrorlist.centos.org; Unknown error。
特别指出: 编译 Dockerfile 并执行其中的 yum install 指令时,所使用的是正在编译的镜像中的 yum 仓库,非编译机上的。
...
如何应对红帽不再维护 CentOS
CentOS(Community Enterprise Operating System,社区企业操作系统)是由 Lance Davis 发起,通过社区驱动,目标是创建一个免费、开源的企业级操作系统。它根据 Red Hat Enterprise Linux(RHEL)开放源码编译而成,由于代码相同,因此一些要求免费且高度稳定性的服务器使用 CentOS 作为 Red Hat Enterprise Linux 的替代 ...
CentOS 7.9 安装 Docker,并进行 Docker 加速,拉取镜像
一、Yum 安装 Docker,配置 Docker CE 镜像站:
参考:Docker CE 镜像源站 需要魔法:在 CentOS 上安装 Docker 引擎 |Docker 文档
1、PS: 如果有旧版本的 Docker 或 尝试安装新版本之前,请先卸载这些旧版本,以及关联的依赖项。dockerdocker-engine
sudo yum remove docker \
docker-client \
...
记录一次Centos升级glibc2.28遇到的坑
升级glibc
#查询glibc版本:
strings /lib64/libc.so.6 | grep -E "^GLIBC" | sort -V -r | uniq
升级glibc2.28
wget https://ftp.gnu.org/gnu/glibc/glibc-2.28.tar.gz
tar -xzvf glibc-2.28.tar.gz
cd glibc-2.28
创建临时文件
mkdir build && cd build
../configure --prefix=/usr --disable-profile --enable-add-ons - ...
CentOS上搭建SFTP
CentOS上搭建SFTP
在CentOS上安装SFTP服务通常是通过安装OpenSSH来实现的,因为OpenSSH默认提供了SFTP功能。以下是在CentOS上安装SFTP的步骤:
一、安装OpenSSH服务器:
sudo yum install openssh-server
启动SSH服务:
sudo systemctl start sshd
确保SSH服务随系统启动而启动:
sudo systemctl enable sshd ...
CentOS安装RustDesk自建服务器
一、安装node.js
1、下载并解压
[root@VM-8-2-centos src]# cd /usr/local
# 下载node文件
[root@VM-8-2-centos local]# wget https://registry.npmmirror.com/-/binary/node/v16.18.1/node-v16.18.1-linux-x64.tar.gz
# 解压文件
[root@VM-8-2-centos local]# sudo tar -zxvf node-v16.18.1-linux-x64.tar.gz -C ./node-v1 ...
CentOS 7.9 环境下搭建k8s集群(一主两从)
目录一、硬件准备(虚拟主机)二、环境准备1、所有机器关闭防火墙2、所有机器关闭selinux3、所有机器关闭swap4、所有机器上添加主机名与ip的对应关系5、在所有主机上将桥接的ipv4流量传递到iptables的链三、为所有节点安装docker四、集群部署1、为所有节点修改仓库,安装kubeadm、kubelet、kubectl2、修改docker的配置(所 ...
CentOS下安装redis 详细步骤
1、前言
Redis版本 6.2.5
服务器版本 Linux CentOS 7.6 64位
2、下载 Redis
下载网址:https://redis.io/download/
笔者使用wget在线下载
wget http://download.redis.io/releases/redis-6.2.5.tar.gz
3、解压、安装
3.1 使用 tar 解压压缩包
tar -xzvf redis-6.2.5.tar.gz
3.2 进入解压后的目录
cd redis-6.2.5
3.3 这 ...
CentOS 7 系统更新和内核升级
安装必要的功能:wget和vim后面会用到,以免出现问题
yum -y install wget vim
处理yum源:更换为阿里的yum源
备份原始文件:
cd /etc/yum.repos.d/
mkdir /etc/yum.repos.d/bak
mv /etc/yum.repos.d/*.repo /etc/yum.repos.d/bak
下载阿里的yum源仓库配置文件:
wget -O /etc/yum.repos.d/CentOS-Base.repo https://mirror ...
centos 离线安装tree命令
在线安装tree命令:
yum -y install tree
但是在线包总是下载失败:
Repository epel is listed more than once in the configuration
Repository epel-debuginfo is listed more than once in the configuration
Repository epel-source is listed more than once in the configuration
Loading mirror speeds ...
CentOS 7.9二进制部署K8S 1.28.3+集群实战
目录前置知识: 部署Kubernetes集群的方式一.K8S二进制部署准备环境1.集群角色划分2.所有节点安装常用的软件包3.k8s-master01节点免密钥登录集群并同步数据4.所有节点Linux基础环境优化5.所有节点升级Linux内核并更新系统6.所有节点安装ipvsadm以实现kube-proxy的负载均衡二.安装K8S相关的基础组件1.所有节点安装containerd1 ...
CentOS 宝塔 安装 onlyoffice
1.宝塔默认软件安装
1.1Nginx需要编译安装
默认版本没有http_secure_link_module 所以需要重新编译安装一遍
打开 /www/server/panel/install 下的nginx.sh,找到 ./configure ,在后面添加 --with-http_secure_link_module
执行 bash nginx.sh install 1.24
下面部分弃用cd /www/server/nginx/src
...
CentOS openssh 升级教程
openssh 下载地址
https://www.openssh.com/openbsd.html
OpenSSH 9.6: December 18, 2023
https://ftp.openbsd.org/pub/OpenBSD/OpenSSH/openssh-9.6.tar.gz
# cd /usr/src/usr.bin
# tar zxvf .../openssh-9.6.tar.gz
# cd ssh
# make obj
# make cleandir
# make depend
# make
# make install
# cp ssh_config ...
CentOS 7.9 安装net 8运行时环境[转]
1.从官网下载对应的运行时环境压缩包。
下载地址:https://dotnet.microsoft.com/zh-cn/download/dotnet/8.0
dotnet-sdk-8.0.100-linux-x64.tar.gz
2.上传至服务器,以我为例我是上传至/usr/local/software/dotnet8
3.运行命令解压环境压缩包
tar -zxvf /home/dotnet8/dotnet-sdk-8.0.100-linux-x64.tar.gz -C /usr/local/ ...
gitlab+sonarqube实现自动化代码漏洞扫描(centos内网环境安装配置及使用遇到的问题)
sonarqube可以与源码管理工具gitlab集成,实现提交代码后自动扫描检测代码的相关漏洞。该CI/CD过程大致为:
1、研发人员提交源码至gitlab服务器 —>
2、gitlab runner执行指定脚本(由项目的.gitlab-ci.yml配置文件指定具体内容,如编译项目、开启代码检测) —>
3、sonar-scanner对项目进行扫描,sonar-scanner将扫描 ...
CentOS开机提示Centos kernel panic-not syncing:VFS:Unable to mount root fs on unknown-block,vm exsi 修复centos虚拟机内核操作
故障:
CentOS开机提示Centos kernel panic-not syncing:VFS:Unable to mount root fs on unknown-block
故障背景:
在没有关闭应用和系统的前提下,直接点了虚拟机关闭电源选项,再开机就报如上错误
原因分析:
根据提示信息分析,可能因为意外关机导致系统内核信息混乱。
解决方法:
(1)如果开机有 ...
Centos系统安装MySQL详细教程
首先再虚拟机中安装一个Centos7(VM虚拟机安装Centos7)
CentOS是常见的Linux操作系统之一,它是一款开源的,稳定而且高效的操作系统。作为一名开发人员,我们经常需要在CentOS系统上安装MySQL数据库。本文将为您介绍如何在CentOS系统上成功安装MySQL数据库的详细步骤。
一、安装MySQL数据库前的准备工作
1、首先,我们需要先 ...