电玩城打鱼捕鱼-专业24小时上下分

CentOS和openSUSE单网卡双ip配置记录,安装与部署

七月 19th, 2019  |  电玩城捕鱼系统简介

CentOS和openSUSE单网卡双ip配置记录:

1.2.1 环境准备
环境由三台服务器组成,分别为目录节点,内容节点,服务器列表如下所示:

1、更改IP之后,执行service network restart时出现 shutting down
interface eth0:Device state :3(disconnected)的问题时,执行service
networkmanager stop (关闭networkmanager服务)、

CentOS单网卡双ip 
cp -p /etc/sysconfig/network-scripts/ifcfg-eth0
/etc/sysconfig/network-scripts/ifcfg-eth0:0 
内容如下。eth0的ip是192.168.16.150网关是192.168.16.1 
[root@localhost network-scripts]# cat ifcfg-eth0   
DEVICE=”eth0″
NM_CONTROLLED=”yes”
ONBOOT=”yes”
HWADDR=00:0C:29:73:7B:2A 
TYPE=Ethernet
BOOTPROTO=none
IPADDR=192.168.16.150   eth0的ip
PREFIX=24
GATEWAY=192.168.16.1    eth0的网关
DNS1=114.114.144.144 
DEFROUTE=yes
IPV4_FAILURE_FATAL=yes
IPV6INIT=no
NAME=”System eth0″
UUID=5fb06bd0-0bb0-7ffb-45f1-d6edd65f3e03 
[root@localhost network-scripts]# cat ifcfg-eth0:0 
DEVICE=”eth0:0″
NM_CONTROLLED=”yes”
ONBOOT=”yes”
HWADDR=00:0C:29:73:7B:2A 
TYPE=Ethernet
BOOTPROTO=none
IPADDR=192.168.1.150  eth0:0的ip
PREFIX=24
GATEWAY=192.168.1.1    eth0:0的网关
DNS1=114.114.144.144 
DEFROUTE=yes           
IPV4_FAILURE_FATAL=yes
IPV6INIT=no
NAME=”System eth0:0″
UUID=5fb06bd0-0bb0-7ffb-45f1-d6edd65f3e03

表1  主机环境准备

chkconfig networkmanager stop(下次不自己启动)

opensuse双卡配置

IP

机器名称

10.0.0.201

m1.Hadoop

10.0.0.209

s1.hadoop

10.0.0.211

s2.hadoop

图片 1

#cat /etc/sysconfig/network/ifcfg-eth0
BOOTPROTO=’static’
BROADCAST=”
ETHTOOL_OPTIONS=”
IPADDR=’192.168.2.254/27′   eth0的ip
MTU=”
NAME=’80003ES2LAN Gigabit Ethernet Controller (Copper)’
NETWORK=”
REMOTE_IPADDR=”
STARTMODE=’auto’
USERCONTROL=’no’
IPADDR_eth01=’10.10.10.254′   eth0:0的ip
NETMASK_eth01=’255.255.255.0′
LABEL_eth01=’0′

相关阅读:

2、 ip地址只能单方面本机到虚拟机的ping通,则关闭虚拟机的防火墙,如果双方都不能ping通,检查是否host-only模式 

配置文件改完,只需service network restart即可

单节点Hadoop安装过程
http://www.linuxidc.com/Linux/2013-03/80282.htm

3、执行service network restart
时最后一项出错,检查ifcfg-eth0中的MAC地址和virtual
box中显示的是否一致;看/etc/udev/rules.d/70-persistent-net.rules中
etho和eth1的问题

图片 2

下面列出各主机配置信息:

4、ifdown
eth0

主机:m1.hadoop

错误提示信息如下:

[hadoop@m1 .ssh]$ cat /etc/sysconfig/network-scripts/ifcfg-eth0

Shutting down interface eth0:  Error: Device ‘eth0’
(/org/freedesktop/NetworkManager/Devices/0) disconnecting failed: This
device is not active

DEVICE=”eth0″

需执行chkconfig NetworkManager off 关闭其服务

NM_CONTROLLED=”yes”

5、配置

ONBOOT=yes

[root@upright91 network-scripts]# more ifcfg-eth1 

TYPE=Ethernet

DEVICE=eth1

BOOTPROTO=none

TYPE=Ethernet

IPADDR=10.0.0.201

UUID=eaf98ad9-5f58-4cfd-bbc4-c212637815ee

PREFIX=24

ONBOOT=yes

GATEWAY=10.0.0.254

NM_CONTROLLED=yes

DEFROUTE=yes

BOOTPROTO=none

IPV4_FAILURE_FATAL=yes

IPADDR=192.168.0.91

IPV6INIT=no

NETMASK=255.255.255.0

NAME=”System eth0″

IPV6INIT=no

HWADDR=10:50:56:AF:00:CF

USERCTL=no

[hadoop@m1 .ssh]$ cat /etc/hosts

PREFIX=24

10.0.0.201  m1.hadoop

DEFROUTE=yes

10.0.0.209  s1.hadoop

IPV4_FAILURE_FATAL=yes

10.0.0.211  s2.hadoop

NAME=”System eth1″

127.0.0.1      localhost.localdomain  localhost

HWADDR=6C:92:BF:2B:6B:F3

标签:, ,

Your Comments

近期评论

    功能


    网站地图xml地图