Skip to content

Commit

Permalink
[multi-asic][vs]: Add context_config.json files for multi-asic vs (#7697
Browse files Browse the repository at this point in the history
)

hwskus.
Why I did it
For multi-asic platforms, orchagent process in swss docker is started by passing device_ids(or asic_ids).
Each swss docker starts orchagent with a different device_id. This device_id is passed as Hardware info to syncd. For syncd to start with the right hwinfo, context_config.json is passed as an argument. context_config.json file is looked up to get the hwinfo information.
sonic-sairedis PRs required for this diff to be used to bring up multi-asic VS:
sonic-net/sonic-sairedis#830
sonic-net/sonic-sairedis#832

How I did it
Add context_config.json for each asic in the same structure as provided here: https://github.com/Azure/sonic-sairedis/blob/master/lib/src/context_config.json
Each asic context_config.json will have different hwinfo string.
hwinfo string will be same as device id retrieved from asic.conf file.
Signed-off-by: Suvarna Meenakshi <[email protected]>
  • Loading branch information
SuvarnaMeenakshi authored Jun 1, 2021
1 parent 90a457a commit a557dbd
Show file tree
Hide file tree
Showing 10 changed files with 210 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"CONTEXTS": [
{
"guid" : 0,
"name" : "syncd0",
"dbAsic" : "ASIC_DB",
"dbCounters" : "COUNTERS_DB",
"dbFlex": "FLEX_COUNTER_DB",
"dbState" : "STATE_DB",
"zmq_enable": false,
"zmq_endpoint": "tcp://127.0.0.1:5555",
"zmq_ntf_endpoint": "tcp://127.0.0.1:5556",
"switches": [
{
"index" : 0,
"hwinfo" : "0"
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"CONTEXTS": [
{
"guid" : 0,
"name" : "syncd1",
"dbAsic" : "ASIC_DB",
"dbCounters" : "COUNTERS_DB",
"dbFlex": "FLEX_COUNTER_DB",
"dbState" : "STATE_DB",
"zmq_enable": false,
"zmq_endpoint": "tcp://127.0.0.1:5555",
"zmq_ntf_endpoint": "tcp://127.0.0.1:5556",
"switches": [
{
"index" : 0,
"hwinfo" : "1"
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"CONTEXTS": [
{
"guid" : 0,
"name" : "syncd2",
"dbAsic" : "ASIC_DB",
"dbCounters" : "COUNTERS_DB",
"dbFlex": "FLEX_COUNTER_DB",
"dbState" : "STATE_DB",
"zmq_enable": false,
"zmq_endpoint": "tcp://127.0.0.1:5555",
"zmq_ntf_endpoint": "tcp://127.0.0.1:5556",
"switches": [
{
"index" : 0,
"hwinfo" : "2"
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"CONTEXTS": [
{
"guid" : 0,
"name" : "syncd3",
"dbAsic" : "ASIC_DB",
"dbCounters" : "COUNTERS_DB",
"dbFlex": "FLEX_COUNTER_DB",
"dbState" : "STATE_DB",
"zmq_enable": false,
"zmq_endpoint": "tcp://127.0.0.1:5555",
"zmq_ntf_endpoint": "tcp://127.0.0.1:5556",
"switches": [
{
"index" : 0,
"hwinfo" : "3"
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"CONTEXTS": [
{
"guid" : 0,
"name" : "syncd0",
"dbAsic" : "ASIC_DB",
"dbCounters" : "COUNTERS_DB",
"dbFlex": "FLEX_COUNTER_DB",
"dbState" : "STATE_DB",
"zmq_enable": false,
"zmq_endpoint": "tcp://127.0.0.1:5555",
"zmq_ntf_endpoint": "tcp://127.0.0.1:5556",
"switches": [
{
"index" : 0,
"hwinfo" : "0"
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"CONTEXTS": [
{
"guid" : 0,
"name" : "syncd1",
"dbAsic" : "ASIC_DB",
"dbCounters" : "COUNTERS_DB",
"dbFlex": "FLEX_COUNTER_DB",
"dbState" : "STATE_DB",
"zmq_enable": false,
"zmq_endpoint": "tcp://127.0.0.1:5555",
"zmq_ntf_endpoint": "tcp://127.0.0.1:5556",
"switches": [
{
"index" : 0,
"hwinfo" : "1"
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"CONTEXTS": [
{
"guid" : 0,
"name" : "syncd2",
"dbAsic" : "ASIC_DB",
"dbCounters" : "COUNTERS_DB",
"dbFlex": "FLEX_COUNTER_DB",
"dbState" : "STATE_DB",
"zmq_enable": false,
"zmq_endpoint": "tcp://127.0.0.1:5555",
"zmq_ntf_endpoint": "tcp://127.0.0.1:5556",
"switches": [
{
"index" : 0,
"hwinfo" : "2"
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"CONTEXTS": [
{
"guid" : 0,
"name" : "syncd3",
"dbAsic" : "ASIC_DB",
"dbCounters" : "COUNTERS_DB",
"dbFlex": "FLEX_COUNTER_DB",
"dbState" : "STATE_DB",
"zmq_enable": false,
"zmq_endpoint": "tcp://127.0.0.1:5555",
"zmq_ntf_endpoint": "tcp://127.0.0.1:5556",
"switches": [
{
"index" : 0,
"hwinfo" : "3"
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"CONTEXTS": [
{
"guid" : 0,
"name" : "syncd4",
"dbAsic" : "ASIC_DB",
"dbCounters" : "COUNTERS_DB",
"dbFlex": "FLEX_COUNTER_DB",
"dbState" : "STATE_DB",
"zmq_enable": false,
"zmq_endpoint": "tcp://127.0.0.1:5555",
"zmq_ntf_endpoint": "tcp://127.0.0.1:5556",
"switches": [
{
"index" : 0,
"hwinfo" : "4"
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"CONTEXTS": [
{
"guid" : 0,
"name" : "syncd5",
"dbAsic" : "ASIC_DB",
"dbCounters" : "COUNTERS_DB",
"dbFlex": "FLEX_COUNTER_DB",
"dbState" : "STATE_DB",
"zmq_enable": false,
"zmq_endpoint": "tcp://127.0.0.1:5555",
"zmq_ntf_endpoint": "tcp://127.0.0.1:5556",
"switches": [
{
"index" : 0,
"hwinfo" : "5"
}
]
}
]
}

0 comments on commit a557dbd

Please sign in to comment.