LoginSignup
2
2

More than 5 years have passed since last update.

linux-boxをhub化する

Last updated at Posted at 2014-05-20

覚え書き

linux-boxをハブ化する

2つのNIC(eth0,eth1)をブリッジさせてHUBとして動作させます。OSはCentOS6.5です。

  • パッケージをインストールする
    # yum install bridge-utils

  • インターフェース設定ファイルを編集する

/etc/sysconfig/network-script/ifcfg-eth[0|1]の内容
DEVICE=eth0 (or eth1)
HWADDR=xx:xx:xx:xx:xx:xx (actual mac address)
ONBOOT=yes
TYPE=Ethernet
BRIDGE=vbr0

/etc/sysconfig/network-script/ifcfg-vbr0の内容
DEVICE=vbr0
BOOTPROTO=static
IPADDR=192.168.20.1
NETMASK=255.255.255.0
ONBOOT=yes
TYPE=Bridge
STP=off

  • ネットワーク再起動 # service network restart
2
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
2