Commit c7316230 authored by Grzegorz Daniluk's avatar Grzegorz Daniluk

smartbits-tester: vlan configuration for performance tests

parent 2e5cae01
......@@ -5,7 +5,7 @@
int wrs_config(char *ip, int testno)
{
char cmd[100];
int list[7] = {211, 212, 221, 222, 225, 226, 227};
int list[16] = {211, 212, 221, 222, 225, 226, 227, 311, 312, 313, 314, 315, 321, 322, 331, 332};
sprintf(cmd, "ssh -p %d root@%s %s %d >/dev/null 2>&1", WRS_PORT, ip, WRS_CONF_SCRIPT, list[testno]);
return system(cmd);
......
#!/bin/sh
# remove all possible VLANs
/wr/bin/rtu_stat vlan 1 1 0x0 1
/wr/bin/rtu_stat vlan 2 2 0x0 1
/wr/bin/rtu_stat vlan 3 3 0x0 1
/wr/bin/rtu_stat vlan 4 4 0x0 1
/wr/bin/rtu_stat vlan 5 5 0x0 1
/wr/bin/rtu_stat vlan 6 6 0x0 1
/wr/bin/rtu_stat vlan 7 7 0x0 1
/wr/bin/rtu_stat vlan 8 8 0x0 1
/wr/bin/rtu_stat vlan 9 9 0x0 1
/wr/bin/rtu_gd -g $1
if [ "$1" == "211" ] || [ "$1" == "212" ]; then
if [ "$1" == "211" ] || [ "$1" == "212" ] || [ "$1" == "311" ] || [ "$1" == "312" ] || [ "$1" == "313" ] || [ "$1" == "331" ]; then
#remove VLAN 1
/wr/bin/rtu_stat vlan 1 1 0x0 1
fi
......@@ -16,7 +27,7 @@ if [ "$1" == "222" ]; then
/wr/bin/rtu_stat vlan 1 1 0x1
fi
if [ "$1" == "227" ]; then
if [ "$1" == "227" ] || [ "$1" == "321" ] || [ "$1" == "322" ]; then
/wr/bin/rtu_stat vlan 1 1 0x20001
/wr/bin/rtu_stat vlan 2 2 0x00006
/wr/bin/rtu_stat vlan 3 3 0x00018
......@@ -27,3 +38,9 @@ if [ "$1" == "227" ]; then
/wr/bin/rtu_stat vlan 8 8 0x06000
/wr/bin/rtu_stat vlan 9 9 0x18000
fi
if [ "$1" == "314" ] || [ "$1" == "315" ] || [ "$1" == "332" ]; then
/wr/bin/rtu_stat vlan 1 1 0x3
/wr/bin/rtu_stat vlan 2 2 0x30000
fi
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment