使用console线连接管理版
bcm show port 查看端口的基本状态,如后插板上1口和24口端口是否为UP状态
bcm show running-config 查看配置文件
bcm set vlan create 0 200 创建vlan200 0表示设备id
bcm set vlan tagport 0 200 1 为vlan200添加一个打标签的端口
bcm set vlan tagport 0 200 24
cat /etc/network.d/ifcfg-eth0 4.0口用作上连接口(外网口兼做网管接口)
eth0
Link encap:Ethernet HWaddr 00:15:7c:1B:90:78
inet addr:1.1.1.3 Bcast:1.1.1.7 Mask:255.255.255.248
inet6 addr: fe80::217:7bff:fe9b:e088/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:3185190 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:15
RX bytes:889093713 (847.9 MiB) TX bytes:0 (0.0 B)
Interrupt:25 Base address:0xc000
cat /etc/network.d/ifcfg-eth0:1 4.1口用作上连接口(vrrp协议,VIP)
eth0:1
Link encap:Ethernet HWaddr 00:15:7c:1B:90:77
inet addr:1.1.1.2 Bcast:1.1.1.7 Mask:255.255.255.248
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Interrupt:25 Base address:0xc000
cat /etc/network.d/ifcfg-eth0:2 4.2口用作下连接口(内网口兼做capwap接口)
eth0:2
Link encap:Ethernet HWaddr 00:15:7c:1B:90:79
inet addr:10.10.10.9 Bcast:10.10.10.15 Mask:255.255.255.248
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Interrupt:25 Base address:0xc000
cat /icac/conf/access.conf
修改access.conf文件
1 127.0.0.1 4603
cat /icac/conf/forward.conf 修改forward.conf文件
127.0.0.1 4603
cat /etc/network.d/static_route 添加静态路由
default gw 1.1.1.1
-net 10.1.0.0 netmask 255.255.0.0 gw 10.10.10.9
-net 10.2.0.0 netmask 255.255.0.0 gw 10.10.10.9
/etc/init.d/network restart 重启网卡,让其立刻生效
copy_run_to_startup 保存配置
hostname kuku
interface GigabitEthernet 1/4.0
vlan id 255
ip address 1.1.1.3 255.255.255.248
vrip 1.1.1.2 group 10
interface GigabitEthernet 1/4.1
vlan id 256
ip address 10.10.10.9 255.255.255.248
attend 10.10.10.8 group 10 vrip
interface GigabitEthernet 1/0.0
ip address 1.1.1.1 255.255.255.248
vrgroup 10
priority 100
track-rtm-port 1 1
preempt
peerip 1.1.1.2
ip route 0.0.0.0 0.0.0.0 1.1.1.1
ip route 10.1.0.0 255.255.0.0 10.10.10.9
ip route 10.2.0.0 255.255.0.0 10.10.10.9