Skip to content

Revert "Orchagent changes needed to support single ASIC VOQ Fixed-System"#4035

Merged
prsunny merged 1 commit intomasterfrom
revert-3847-single_voq_swss
Dec 5, 2025
Merged

Revert "Orchagent changes needed to support single ASIC VOQ Fixed-System"#4035
prsunny merged 1 commit intomasterfrom
revert-3847-single_voq_swss

Conversation

@yxieca
Copy link
Contributor

@yxieca yxieca commented Dec 5, 2025

Reverts #3847

Copilot AI review requested due to automatic review settings December 5, 2025 02:07
@yxieca yxieca requested a review from prsunny as a code owner December 5, 2025 02:07
@mssonicbld
Copy link
Collaborator

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR reverts PR #3847, which added support for single ASIC VOQ (Virtual Output Queue) Fixed-System. The revert removes the conditional logic that allowed VOQ switches to operate in a standalone mode without chassis database connectivity, reverting back to requiring CHASSIS_APP_DB connection for all VOQ switch types.

Key changes:

  • Removed gMultiAsicVoq global flag and isChassisDbInUse() helper function, reverting to direct gMySwitchType == "voq" checks
  • Eliminated test infrastructure for single ASIC VOQ fixed-system mode, including test configurations and command-line options
  • Removed conditional CHASSIS_APP_DB connection logic that enabled standalone VOQ operation

Reviewed changes

Copilot reviewed 11 out of 11 changed files in this pull request and generated no comments.

Show a summary per file
File Description
tests/virtual_chassis/database_config.json Deleted database configuration file used for testing virtual chassis setup with single ASIC VOQ
tests/single_asic_voq_fs/default_config.json Deleted default configuration for single ASIC VOQ fixed-system test mode
tests/conftest.py Removed --switch-mode parameter, SINGLE_ASIC_VOQ_FS constant, and related conditional logic for handling single ASIC VOQ test mode
tests/mock_tests/mock_orchagent_main.cpp Removed mock implementations of gMultiAsicVoq and isChassisDbInUse()
orchagent/p4orch/tests/test_main.cpp Removed mock implementations of gMultiAsicVoq and isChassisDbInUse()
orchagent/main.cpp Removed gMultiAsicVoq flag, isChassisDbInUse() function, and isChassisAppDbPresent() function; restored unconditional CHASSIS_APP_DB connection for VOQ switches
orchagent/portsorch.cpp Reverted VOQ detection from isChassisDbInUse() to gMySwitchType == "voq" for LAG operations and port status updates
orchagent/neighorch.cpp Reverted VOQ detection from isChassisDbInUse() to gMySwitchType == "voq" for neighbor synchronization
orchagent/intfsorch.cpp Reverted VOQ detection from isChassisDbInUse() to gMySwitchType == "voq" for interface operations
.azure-pipelines/test-docker-sonic-vs-template.yml Removed single ASIC VOQ test execution from CI pipeline
.azure-pipelines/docker-sonic-vs/start.sh Removed conditional VOQ configuration file handling during container startup

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@yijingyan2
Copy link
Contributor

sonic-net/sonic-buildimage@71f390d
by reverting this pr, the kvmtest passed for t2

@prsunny prsunny merged commit a7198d1 into master Dec 5, 2025
12 of 16 checks passed
@prsunny
Copy link
Collaborator

prsunny commented Dec 5, 2025

@tjchadaga , would you check on this? need the t2 kvm fix before we can re-merge this.

@saiarcot895
Copy link
Contributor

Orchagent crash backtrace seen on T2 KVM:

#0  0x00007f1570b65828 in std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::basic_string (this=0x7fff0ffdeb80, __str=<error reading variable: Cannot access memory at address 0x30>)
    at /build/reproducible-path/gcc-12-12.2.0/build/x86_64-linux-gnu/libstdc++-v3/include/bits/basic_string.h:544
#1  0x00005582ac5cefe2 in swss::TableBase::getTableNameSeparator[abi:cxx11]() const (this=<optimized out>) at /usr/include/swss/table.h:82
#2  NeighOrch::voqSyncAddNeigh (this=this@entry=0x7f156fc53400, alias="vlab-t2-1-1|asic0|Ethernet-IB0", ip_address=..., mac=..., neighbor_entry=...) at ./orchagent/neighorch.cpp:2296
#3  0x00005582ac5cf8a4 in NeighOrch::addInbandNeighbor (this=this@entry=0x7f156fc53400, alias="vlab-t2-1-1|asic0|Ethernet-IB0", ip_address=...) at ./orchagent/neighorch.cpp:2130
#4  0x00005582ac5ea714 in IntfsOrch::setIntf (this=this@entry=0x7f156e7fae00, alias="Ethernet-IB0", vrf_id=vrf_id@entry=844424930132007, ip_prefix=ip_prefix@entry=0x7fff0ffdfed0, adminUp=<optimized out>, mtu=<optimized out>, loopbackAction="")
    at ./orchagent/intfsorch.cpp:591
#5  0x00005582ac5ec07f in IntfsOrch::doTask (this=0x7f156e7fae00, consumer=...) at ./orchagent/intfsorch.cpp:965
#6  0x00005582ac5698f3 in Consumer::execute (this=0x7f156e78a600) at ./orchagent/orch.cpp:338
#7  0x00005582ac557bb0 in OrchDaemon::start (this=this@entry=0x7f156fc3e970, heartBeatInterval=heartBeatInterval@entry=10000) at ./orchagent/orchdaemon.cpp:980
#8  0x00005582ac49336a in main (argc=<optimized out>, argv=<optimized out>) at ./orchagent/main.cpp:965

Trigger of segfault:

(gdb) frame 2
#2  NeighOrch::voqSyncAddNeigh (this=this@entry=0x7f156fc53400, alias="vlab-t2-1-1|asic0|Ethernet-IB0", ip_address=..., mac=..., neighbor_entry=...) at ./orchagent/neighorch.cpp:2296
2296    in ./orchagent/neighorch.cpp
(gdb) print m_tableVoqSystemNeighTable
$5 = std::unique_ptr<swss::Table> = {get() = 0x0}

kalash-nexthop pushed a commit to kalash-nexthop/sonic-swss that referenced this pull request Dec 16, 2025
…tem (sonic-net#3847)" (sonic-net#4035)

This reverts commit 5671e08.

Signed-off-by: Kalash Nainwal <kalash@nexthop.ai>
prsunny pushed a commit that referenced this pull request Jan 5, 2026
What I did
Orchagent changes needed to support single ASIC VOQ Fixed-System (#3847) was reverted via (#4035) because
vms-kvm-t2 tests were failing.
That was because the isChassisAppDbPresent() was using an incorrect path to database_config.json
This PR brings back the original #3847 and fixes the isChassisAppDbPresent() to use the correct path.

Why I did it
Single-asic VOQ systems do need #3847
mssonicbld added a commit to mssonicbld/sonic-swss that referenced this pull request Jan 5, 2026
<!--
Please make sure you have read and understood the contribution guildlines:
https://github.com/Azure/SONiC/blob/gh-pages/CONTRIBUTING.md

1. Make sure your commit includes a signature generted with `git commit -s`
2. Make sure your commit title follows the correct format: [component]: description
3. Make sure your commit message contains enough details about the change and related tests
4. Make sure your pull request adds related reviewers, asignees, labels

Please also provide the following information in this pull request:
-->

**What I did**
Orchagent changes needed to support single ASIC VOQ Fixed-System (sonic-net#3847) was reverted via (sonic-net#4035) because
vms-kvm-t2 tests were failing.
That was because the `isChassisAppDbPresent()` was using an incorrect path to `database_config.json`
This PR brings back the original sonic-net#3847 and fixes the `isChassisAppDbPresent()` to use the correct path.

**Why I did it**
Single-asic VOQ systems do need sonic-net#3847

**How I verified it**
Tests on vms-kvm-t2 and also single-asic voq systems
Verified on vms-kvm-t2 the test_bgp_fact is passing
```
bgp/test_bgp_fact.py::test_bgp_facts[vlab-t2-1-1-0] PASSED [ 25%]
bgp/test_bgp_fact.py::test_bgp_facts[vlab-t2-1-1-1] PASSED [ 50%]
bgp/test_bgp_fact.py::test_bgp_facts[lvlab-t2-1-2-0] PASSED [ 75%]
bgp/test_bgp_fact.py::test_bgp_facts[vlab-t2-1-2-1] PASSED [100%]
```

**Details if related**
mssonicbld added a commit that referenced this pull request Jan 5, 2026
<!--
Please make sure you have read and understood the contribution guildlines:
https://github.com/Azure/SONiC/blob/gh-pages/CONTRIBUTING.md

1. Make sure your commit includes a signature generted with `git commit -s`
2. Make sure your commit title follows the correct format: [component]: description
3. Make sure your commit message contains enough details about the change and related tests
4. Make sure your pull request adds related reviewers, asignees, labels

Please also provide the following information in this pull request:
-->

**What I did**
Orchagent changes needed to support single ASIC VOQ Fixed-System (#3847) was reverted via (#4035) because
vms-kvm-t2 tests were failing.
That was because the `isChassisAppDbPresent()` was using an incorrect path to `database_config.json`
This PR brings back the original #3847 and fixes the `isChassisAppDbPresent()` to use the correct path.

**Why I did it**
Single-asic VOQ systems do need #3847

**How I verified it**
Tests on vms-kvm-t2 and also single-asic voq systems
Verified on vms-kvm-t2 the test_bgp_fact is passing
```
bgp/test_bgp_fact.py::test_bgp_facts[vlab-t2-1-1-0] PASSED [ 25%]
bgp/test_bgp_fact.py::test_bgp_facts[vlab-t2-1-1-1] PASSED [ 50%]
bgp/test_bgp_fact.py::test_bgp_facts[lvlab-t2-1-2-0] PASSED [ 75%]
bgp/test_bgp_fact.py::test_bgp_facts[vlab-t2-1-2-1] PASSED [100%]
```

**Details if related**
Pterosaur pushed a commit to Janetxxx/sonic-swss that referenced this pull request Jan 6, 2026
Pterosaur pushed a commit to Janetxxx/sonic-swss that referenced this pull request Jan 6, 2026
arpit-nexthop pushed a commit to nexthop-ai/sonic-swss that referenced this pull request Jan 21, 2026
What I did
Orchagent changes needed to support single ASIC VOQ Fixed-System (sonic-net#3847) was reverted via (sonic-net#4035) because
vms-kvm-t2 tests were failing.
That was because the isChassisAppDbPresent() was using an incorrect path to database_config.json
This PR brings back the original sonic-net#3847 and fixes the isChassisAppDbPresent() to use the correct path.

Why I did it
Single-asic VOQ systems do need sonic-net#3847
ganglyu pushed a commit to ganglyu/sonic-swss that referenced this pull request Jan 26, 2026
What I did
Orchagent changes needed to support single ASIC VOQ Fixed-System (sonic-net#3847) was reverted via (sonic-net#4035) because
vms-kvm-t2 tests were failing.
That was because the isChassisAppDbPresent() was using an incorrect path to database_config.json
This PR brings back the original sonic-net#3847 and fixes the isChassisAppDbPresent() to use the correct path.

Why I did it
Single-asic VOQ systems do need sonic-net#3847

Signed-off-by: ganglyu <glv@nvidia.com>
baorliu pushed a commit to baorliu/sonic-swss that referenced this pull request Feb 23, 2026
…tem (sonic-net#3847)" (sonic-net#4035)

This reverts commit 5671e08.

Signed-off-by: Baorong Liu <96146196+baorliu@users.noreply.github.com>
baorliu pushed a commit to baorliu/sonic-swss that referenced this pull request Feb 23, 2026
What I did
Orchagent changes needed to support single ASIC VOQ Fixed-System (sonic-net#3847) was reverted via (sonic-net#4035) because
vms-kvm-t2 tests were failing.
That was because the isChassisAppDbPresent() was using an incorrect path to database_config.json
This PR brings back the original sonic-net#3847 and fixes the isChassisAppDbPresent() to use the correct path.

Why I did it
Single-asic VOQ systems do need sonic-net#3847

Signed-off-by: Baorong Liu <96146196+baorliu@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants