#####问题背景:windows上装多台虚拟机,来测试mycat,其中一台虚拟机装mysql的时候遇到如下问题,上传的centos7的镜像
#####具体错误日志:
"[root@localhost centosroot]# sudo yum -y localinstall mysql-community-client-5.7.30-1.el7.x86_64.rpm
已加载插件:fastestmirror
正在检查 mysql-community-client-5.7.30-1.el7.x86_64.rpm: mysql-community-client-5.7.30-1.el7.x86_64
mysql-community-client-5.7.30-1.el7.x86_64.rpm 将被安装
正在解决依赖关系
--> 正在检查事务
---> 软件包 mysql-community-client.x86_64.0.5.7.30-1.el7 将被 安装
--> 正在处理依赖关系 mysql-community-libs(x86-64) >= 5.7.9,它被软件包 mysql-community-client-5.7.30-1.el7.x86_64 需要
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 resolve host: mirrorlist.centos.org; 未知的错误"
One of the configured repositories failed (未知),
and yum doesn't have enough cached data to continue. At this point the only
safe thing yum can do is fail. There are a few ways to work "fix" this:
1. Contact the upstream for the repository and get them to fix the problem.
2. Reconfigure the baseurl/etc. for the repository, to point to a working
upstream. This is most often useful if you are using a newer
distribution release than is supported by the repository (and the
packages for the previous distribution release still work).
3. Run the command with the repository temporarily disabled
yum --disablerepo=<repoid> ...
4. Disable the repository permanently, so yum won't use it by default. Yum
will then just ignore the repository until you permanently enable it
again or use --enablerepo for temporary usage:
yum-config-manager --disable <repoid>
or
subscription-manager repos --disable=<repoid>
5. Configure the failing repository to be skipped, if it is unavailable.
Note that yum will try to contact the repo. when it runs most commands,
so will have to try and fail each time (and thus. yum will be be much
slower). If it is a very temporary problem though, this is often a nice
compromise:
yum-config-manager --save --setopt=<repoid>.skip_if_unavailable=true
Cannot find a valid baseurl for repo: base/7/x86_64"
虚拟机网络配置以及本机网络配置
本地的机子ip配置:
连接特定的 DNS 后缀 . . . . . . . :
IPv6 地址 . . . . . . . . . . . . : 240e:47d:32e8:909c:dc1b:f63e:b065:553c
临时 IPv6 地址. . . . . . . . . . : 240e:47d:32e8:909c:a5c3:a7ad:741:cea4
本地链接 IPv6 地址. . . . . . . . : fe80::dc1b:f63e:b065:553c%48
IPv4 地址 . . . . . . . . . . . . : 192.168.43.64
子网掩码 . . . . . . . . . . . . : 255.255.255.0
默认网关. . . . . . . . . . . . . : fe80::74df:40ff:fe34:7225%48
192.168.43.1
虚拟机网络配置:
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: ens33: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
link/ether 00:0c:29:8b:0c:61 brd ff:ff:ff:ff:ff:ff
inet 192.168.43.66/24 brd 192.168.43.255 scope global noprefixroute ens33
valid_lft forever preferred_lft forever
inet6 240e:47d:32e8:909c:20c:29ff:fe8b:c61/64 scope global mngtmpaddr dynamic
valid_lft 3541sec preferred_lft 3541sec
inet6 fe80::20c:29ff:fe8b:c61/64 scope link
valid_lft forever preferred_lft forever
虚拟机的resolv.conf文件配置:
nameserver 1.1.1.1
nameserver 1.0.0.1
虚拟机的ifcfg-ens33文件配置:
"E=ens33
BOOTPROTO=static
ONBOOT=yes
IPADDR=192.168.43.66
NETMASK=255.255.255.0
GATEWAY=192.168.43.1
DNS1=1.1.1.1
DNS2=1.0.0.1"
采用的桥接模式
我想要达到的结果
在这台虚拟机成功使用mysql以便测试mycat