DevTech101

DevTech101

How to create a vlan interface and start at boot time.

First check if the bounding module is loaded.

lsmod | grep 8021q

/etc/sysconfig/network-scripts/ifcfg-solr

DEVICE=solr
TYPE=Ethernet
BOOTPROTO=none
ONBOOT=yes

/etc/sysconfig/network-scripts/ifcfg-solr.2018

DEVICE=solr.2018
IPADDR=10.10.18.51
NETWORK=10.10.18.0
NETMASK=255.255.254.0
GATEWAY=10.10.18.1
ONBOOT=yes
BOOTPROTO=none
USERCTL=no
VLAN=yes

To test just issue

/etc/init.d/network restart
or
ifup [if_name]

To remove the new vlan

How to remove VLAN ID 2018?

Type the following commands
# ip link set dev solr.2018 down
# ip link delete solr.2018

<3>How to configure bonding
First make sure the bonding module is loaded, then create the configuration below
/etc/sysconfig/network-scripts/ifcfg-bond0

DEVICE=bond0
BONDING_MASTER=yes
ONBOOT=yes
MTU=9000
NETWORK=10.151.18.0
NETMASK=255.255.254.0
IPADDR=10.151.18.51
BONDING_OPTS="mode=1 miimon=100"

/etc/sysconfig/network-scripts/ifcfg-dmznet_pvi

TYPE=Ethernet
BOOTPROTO=none
DEVICE=dmznet_pvi
ONBOOT=yes
MASTER=bond0
SLAVE=yes

/etc/sysconfig/network-scripts/ifcfg-dmznet_pviB

TYPE=Ethernet
BOOTPROTO=none
DEVICE=dmznet_pviB
ONBOOT=yes
MASTER=bond0
SLAVE=yes
0 0 votes
Article Rating
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x
%d bloggers like this: