zoukankan      html  css  js  c++  java
  • 双网卡绑定一个IP--bond

    双网卡绑定一个IP

    步骤1:新建/etc/sysconfig/network-scripts/ifcfg-bond0文件

    DEVICE=bond0
    ONBOOT=yes
    BOOTPROTO=static
    IPADDR=xxx.xxx.xxx.xxx
    NETMASK=xxx.xxx.xxx.xxx
    GATEWAY=xxx.xxx.xxx.xxx
    USERCTL=no

    步骤2:更改/etc/sysconfig/network-scripts/ifcfg-eth0网卡

    DEVICE=eth0
    ONBOOT=yes
    BOOTPROTO=none
    MASTER=bond0
    USERCTL=no

    步骤3:更改/etc/sysconfig/network-scripts/ifcfg-eth1网卡

    DEVICE=eth1
    ONBOOT=yes
    BOOTPROTO=none
    MASTER=bond0
    USERCTL=no

    步骤4:编辑 /etc/modprobe.d/dist.conf最后一行添加)

    alias bond0 bonding
    options bond0 miimon=100 mode=0

    步骤5:加入/etc/rc.d/rc.local启动项

      ifenslave bond0 eth0 eth1   
    

    步骤6:重启下机器

            reboot

    步骤7:测试

           网线从eth0拔下插到eth1还能正常ping通测配置成功

    Keep empowering yourself successfully...
  • 相关阅读:
    git
    redis
    Hexo-butterfly-magicv3.0.1(持续更新中....)
    转发好文章1
    0x07 Nagios Notifications
    0x06 nagios监控状态
    0x05 Nagios Host Check
    0x03 Nagios Plugins介绍
    0x02 Nagios CGI的认证和授权
    0x01 Nagios配置文件
  • 原文地址:https://www.cnblogs.com/jack34/p/8244959.html
Copyright © 2011-2022 走看看