Skip to content

Commit 19b592b

Browse files
[vstest]VS test for VOQ System ports (#5862)
Changes for supporting vstest for VOQ system ports. The changes include: (1)Use of chassis_db.json is avoided since the SYSTEM_PORT is made available in virtual chassis linecard's default_config.json which will be loaded during bootup (2)Core port index map file is introduced and is copied from virtual chassis directory to hwsku direcory by start.sh (3)vs sai profile is modified to include core port index map file name Signed-off-by: vedganes <[email protected]>
1 parent e4ee07b commit 19b592b

File tree

5 files changed

+7
-16
lines changed

5 files changed

+7
-16
lines changed

platform/vs/docker-sonic-vs/Dockerfile.j2

-1
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,6 @@ COPY ["port_breakout_config_db.json", "/etc/sonic/"]
157157
COPY ["database_config.json", "/etc/default/sonic-db/"]
158158
COPY ["hostname.j2", "/usr/share/sonic/templates/"]
159159
COPY ["default_chassis_cfg.json", "/etc/default/sonic-db/"]
160-
COPY ["chassis_db.py", "/usr/bin/"]
161160

162161
COPY ["platform.json", "/usr/share/sonic/device/x86_64-kvm_x86_64-r0/"]
163162
COPY ["hwsku.json", "/usr/share/sonic/device/x86_64-kvm_x86_64-r0/Force10-S6000/"]

platform/vs/docker-sonic-vs/chassis_db.py

-13
This file was deleted.

platform/vs/docker-sonic-vs/database_config.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474
"instance" : "redis"
7575
},
7676
"CHASSIS_APP_DB" : {
77-
"id" : 11,
77+
"id" : 12,
7878
"separator": "|",
7979
"instance" : "redis_chassis"
8080
}

platform/vs/docker-sonic-vs/start.sh

+5-1
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@ supervisorctl start redis-server
7676
start_chassis_db=`sonic-cfggen -v DEVICE_METADATA.localhost.start_chassis_db -y $chassisdb_cfg_file`
7777
if [[ "$HOSTNAME" == *"supervisor"* ]] || [ "$start_chassis_db" == "1" ]; then
7878
supervisorctl start redis-chassis
79-
python /usr/bin/chassis_db.py
8079
fi
8180

8281
conn_chassis_db=`sonic-cfggen -v DEVICE_METADATA.localhost.connect_to_chassis_db -y $chassisdb_cfg_file`
@@ -86,6 +85,11 @@ if [ "$start_chassis_db" != "1" ] && [ "$conn_chassis_db" != "1" ]; then
8685
cp $db_cfg_file_tmp $db_cfg_file
8786
fi
8887

88+
if [ "$conn_chassis_db" == "1" ]; then
89+
if [ -f /usr/share/sonic/virtual_chassis/coreportindexmap.ini ]; then
90+
cp /usr/share/sonic/virtual_chassis/coreportindexmap.ini /usr/share/sonic/hwsku/
91+
fi
92+
fi
8993

9094
/usr/bin/configdb-load.sh
9195

src/sonic-device-data/src/sai.vs_profile

+1
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@ SAI_WARM_BOOT_WRITE_FILE=/var/cache/sai_warmboot.bin
33
SAI_VS_SWITCH_TYPE=SAI_VS_SWITCH_TYPE_BCM56850
44
SAI_VS_HOSTIF_USE_TAP_DEVICE=true
55
SAI_VS_INTERFACE_LANE_MAP_FILE=/usr/share/sonic/hwsku/lanemap.ini
6+
SAI_VS_CORE_PORT_INDEX_MAP_FILE=/usr/share/sonic/hwsku/coreportindexmap.ini

0 commit comments

Comments
 (0)