Commit Graph

2174 Commits

Author SHA1 Message Date
Nazarii Hnydyn
55e7a14f04
[submodule]: Advance sonic-utilities. (#10058)
```
Commits on Jan 31, 2022
[sonic-package-manager] implement blocking feature state change (#2035) 

Commits on Feb 12, 2022
[ci] pipeline fixes for VS test (#2059) 

Commits on Feb 14, 2022
[ci] allow download partially succeeded suilds for sonic-swss-pytests… 
[build] allowPartiallySucceededBuilds true in the step of download so… 

Commits on Feb 16, 2022
[config] Fix snmpagentaddress doesn't support the uppercase letters f… 

Commits on Feb 17, 2022
[ci] Fix pipeline on build_and_install_module (#2074) 
Enable diff coverage and set the threshold to 50% (#2061) 

Commits on Feb 18, 2022
check for adding default vlan attempt added (#2075) 
[GCU] Adding unit-test where path and ref paths are under the same YA… 
[GCU] Turning port admin down before some critical port changes (#1998) 

Commits on Feb 20, 2022
show_platfom_info not run for simx (#2042) 
[aclshow] fix aclshow when clear is called before counters are popula… 
```
2022-02-22 15:32:57 -08:00
Mohamed Ghoneim
f21a45b68a
[build] fix build exception and revert #9136 (#10037)
#### Why I did it

1. Fix Build exception [example](https://dev.azure.com/mssonic/build/_build/results?buildId=73911&view=logs&jobId=88ce9a53-729c-5fa9-7b6e-3d98f2488e3f&j=cef3d8a9-152e-5193-620b-567dc18af272&t=ac3bce9f-b126-5a26-3fee-28ce0ec1679d)

```
2022-02-19T01:54:23.4200556Z ImportError: cannot import name 'soft_unicode' from 'markupsafe' (/usr/local/lib/python3.8/dist-packages/markupsafe/__init__.py)
```

This is because Jinja2 uses MarkupSafe without specifying an upper limit to the version, MarkupSafe version that was released today removed 'soft_unicode'. So now Jinja2 is complaining.

Related issues:
https://github.com/pallets/jinja/issues/1591
https://github.com/aws/aws-sam-cli/issues/3661


2. Reverts #9136

Fixing build failures in SONiC utils [example](https://dev.azure.com/mssonic/build/_build/results?buildId=73784&view=logs&jobId=83516c17-6666-5250-abde-63983ce72a49&j=83516c17-6666-5250-abde-63983ce72a49&t=6177235f-d4f1-5f72-835a-90ebb93a1784)

One of the errors:
```
 TestPathAddressing.test_find_ref_paths__ref_is_the_whole_key__returns_ref_paths 

self = <tests.generic_config_updater.gu_common_test.TestPathAddressing testMethod=test_find_ref_paths__ref_is_the_whole_key__returns_ref_paths>

    def test_find_ref_paths__ref_is_the_whole_key__returns_ref_paths(self):
        # Arrange
        path = "/PORT/Ethernet0"
        expected = [
            "/ACL_TABLE/NO-NSW-PACL-V4/ports/0",
            "/VLAN_MEMBER/Vlan1000|Ethernet0",
        ]
    
        # Act
        actual = self.path_addressing.find_ref_paths(path, Files.CROPPED_CONFIG_DB_AS_JSON)
    
        # Assert
>       self.assertEqual(expected, actual)
E       AssertionError: Lists differ: ['/ACL_TABLE/NO-NSW-PACL-V4/ports/0', '/VLAN_MEMBER/Vlan1000|Ethernet0'] != ['/ACL_TABLE/NO-NSW-PACL-V4/ports/0']
E       
E       First list contains 1 additional elements.
E       First extra element 1:
E       '/VLAN_MEMBER/Vlan1000|Ethernet0'
E       
E       - ['/ACL_TABLE/NO-NSW-PACL-V4/ports/0', '/VLAN_MEMBER/Vlan1000|Ethernet0']
E       + ['/ACL_TABLE/NO-NSW-PACL-V4/ports/0']
```

The VLAN_MEMBER backlink (can be called referrer link or ref link) is not found.

Issue introduced by https://github.com/Azure/sonic-buildimage/pull/9136
I don't know how this PR passed the build system, it should have failed.

Known YANG issue https://github.com/Azure/sonic-buildimage/issues/9312

#### How I did it
The import to `sonic-vlan` is breaking the build
```
    import sonic-vlan {
        prefix vlan;
    }
```

I am not sure if that's the only issue, so I think reverting the whole PR should be the safer option.

#### How to verify it
Ran sonic-utils tests locally.
2022-02-21 11:07:29 -08:00
thomas.cappleman@metaswitch.com
a7f6130383
[submodule] swss-common and py-swssdk updates (#9777)
sonic-swss-common:
[ci] Set diff coverage threshold to 50% (#567)
Added NVGRE tunnel related tables (#549)
Add option to suppress logging (#566)
[TableBase] Make channel name from both table name and database ID (#568)
Revert "[TableBase] Make channel name from both table name and database ID (#568)" (#574)

sonic-py-swsssdk:
Add option to suppress warnings when querying Redis (#115)
2022-02-18 13:24:04 -08:00
Christian Svensson
d540492834
caclmgrd: remove permit source port 179 (#9827)
[Caclmgrd] Remove insecure opening of source port 179
Signed-off-by: Christian Svensson <blue@cmd.nu>
2022-02-17 15:04:59 -08:00
Vadym Hlushko
5ce75acfa5
[nvgre] Added YANG model and tests (#9136)
- Why I did it
NVGRE Tunnel feature extends the Config DB with new tables. These tables require a new YANG model.

- How I did it
Added a new YANG model sonic-nvgre-tunnel.yang

- How to verify it
Added YANG test cases.

Signed-off-by: Vadym Hlushko <vadymh@nvidia.com>
2022-02-17 12:06:01 +02:00
kellyyeh
f136c53d19
[radv] Support multiple ipv6 prefixes per vlan interface (#9934)
Why I did it
Radvd.conf.j2 template creates two copies of the vlan interface when there are more than one ipv6 address assigned to a single vlan interface. Changed the format to add prefixes under the same vlan interface block.

How I did it
Modifies radvd.conf.j2 and added unit tests

How to verify it
Configure multiple ipv6 address to the same vlan, start radvd
Unit test will check if radvd.conf with multiple ipv6 addresses is formed correctly
2022-02-16 14:17:26 -08:00
Aravind Mani
b7ae4f2e67
Dell S6100: Addition of 10G ports (#9988) 2022-02-16 00:09:05 -08:00
Myron Sosyak
125fe9907a
Bump Thrift version from 0.13.0 to 0.14.1 (#9881)
#### Why I did it
To bump the Thrift version to 0.14.1 
- To avoid [CVE-2020-13949](https://nvd.nist.gov/vuln/detail/CVE-2020-13949) 
- to fix some dependencies issues

#### How I did it
- rename `src/thrfit_0_13_0` to `src/thrift_2` to remove version number in the path. (`src/thrift` contains rules to build thrift 0.11.0  )
- Add thrift sources as submodule as there are no prepared debian packages for version >0.13.0 on [debian.org](https://packages.debian.org/search?searchon=sourcenames&keywords=thrift)
- Added patches with fixes for original thrift debian rules:(remove unneeded packages, fix multi job build)
#### How to verify it
```
BLDENV=buster make -f Makefile.work target/debs/buster/libthrift-dev_0.14.1_amd64.deb
```
2022-02-15 16:39:47 -08:00
Sudharsan Dhamal Gopalarathnam
0b59f0b641
[yang]YANG model for policer table (#9948)
#### Why I did it
Added yang model for policer table
Fixes https://github.com/Azure/sonic-buildimage/issues/9742 and https://github.com/Azure/sonic-buildimage/issues/9743
#### How I did it
Creating yang model for policer

#### How to verify it
Added UT to verify the yang model

The configuration schema for policer is added in the pull request https://github.com/Azure/sonic-swss/pull/2144
2022-02-14 13:00:58 -08:00
Alexander Allen
675bceba4d
[submodule] Update linux-kernel submodule pointer (#9937)
Updates include the following changes in order to support new Mellanox platforms and drivers (Azure/sonic-linux-kernel#259)

10ef390 Update kconfig to support / enable newly backported mellanox patches.
6a949e1 Add backported patches for Mellanox hw-mgmt V.7.0020.1300
e1913f7 Rename and reformat patch headers
2022-02-13 17:13:48 +02:00
Kebo Liu
7af5fcf80e
update sonic-snmpagent submodule (#9935)
Update the sonic-snmpagemt submodule to pick up new changes:
Fix RFC2737 with update xcvr vendor version key name Azure/sonic-snmpagent@4ee573c
Fix Queue stat unavailable error seen during SNMP service start Azure/sonic-snmpagent@3013597
Modify path of python wheels to be installed Azure/sonic-snmpagent@b8ea609
[Voq][Inband] Support the Ethernet-IB port Azure/sonic-snmpagent@df615c4

Signed-off-by: Kebo Liu <kebol@nvidia.com>
2022-02-13 15:01:40 +02:00
Sudharsan Dhamal Gopalarathnam
b621dafff7
[yang] Adding not-provisioned to type field in DEVICE_METADATA table (#9951)
#### Why I did it
Fixing the issue https://github.com/Azure/sonic-buildimage/issues/9915

#### How I did it
Added 'not-provisioned' as a supported value for type field in DEVICE_METADATA type. This value is set during initial ZTP bring up

#### How to verify it
Added UT to verify it.
2022-02-10 11:59:25 -08:00
Jing Kan
914a8a1756
[sonic-config-engine]: Update minigraph parser to support enable DHCP server for BmcMgmtToRRouter (#9938)
Signed-off-by: Jing Kan jika@microsoft.com
2022-02-10 13:30:54 +08:00
abdosi
e44a40cc3b
Updated Internal BGP Templates for chassis packet (#9674)
Fixes: https://github.com/Azure/sonic-buildimage/issues/9610
2022-02-08 09:36:32 -08:00
Dror Prital
cd77efa763
[submodule] Update sonic-utilities submodule (#9871)
Update submodule sonic-utilities that contains the following commits:

[build] allowPartiallySucceededBuilds: true (#2043)
[system-health] Remove booting stage in system health service (#2022)
[GCU] Mark children of bgp_neighbor as create-only (#2008)
[generic_config_updater] Minor update - No logical code change (#2028)
[generic-config-updater] Handle failed service restarts (#2020)
[debug dump] Missing Dict Key handled in the MatchOptimizer (#2014)
[Auto Techsupport] Added Event Driven TS to Command Reference (#1985)
2022-02-07 12:58:47 +02:00
Jing Zhang
7a4c58f118
[sonic-linkmgrd][master] submodule update (#9904)
[sonic-linkmgrd][master] submodule update

ef1f5eb Jing Zhang Feb 3 09:37:25 2022 [linkmgrd] linkmgrd subscribes MUX_CABLE_INFO table to handle peer OIR events (#17)
bcd74b4 Jing Zhang Feb 1 09:52:00 2022 Collect ICMP packet loss information (#14)

sign-off: Jing Zhang zhangjing@microsoft.com
2022-02-05 13:07:32 -08:00
Ashok Daparthi-Dell
0629e5b432
[yang] Fix for sonic-scheduler.yang name pattern (#9873)
#### Why I did it

PR9611 - sonic-scheduler.yang pattern issue

#### How I did it
Modified the scheduler name pattern string to accept any string 

#### How to verify it

Sonic yang tests
2022-02-04 16:47:56 -08:00
kellyyeh
bc88535b88
[dhcp6relay] Support relaying Relay-Forward message (#9887) 2022-02-01 11:36:48 -08:00
noaOrMlnx
adb87162c4
[submodule] Update sonic-swss submodule pointer (#9859)
53c630b [CoPP] Add always_enabled field to coppmgr logic ([minigraph]: Add PORTCHANNEL_MEMBER configurations #2034)
adcf69d [cbf] Fix cbf sync error ([aboot] add SWI_DEFAULT support in boot0 #2056)
69f9ee5 fix mclagsyncd out of order initialization ([submodules] update dbsyncd and snmpagent pointers for LLDP MIB support #2112)
2022-02-01 19:20:00 +02:00
Mohamed Ghoneim
f8fd2defb4
[yang] Fixing groupings when grouping is in the same module file (#9880)
#### Why I did it
If the grouping is in the same file in the module, fetching the grouping fails

#### How I did it
fixing the `uses_module_name` when the grouping is under the same file

#### How to verify it
Enabled a grouping under the same file which is `lldp`, there is a test in sonic-yang-mgmt that translates `sample-config-db` into yang format. This test passes with grouping in `lldp` used.

#### Which release branch to backport (provide reason below if selected)

<!--
- Note we only backport fixes to a release branch, *not* features!
- Please also provide a reason for the backporting below.
- e.g.
- [x] 202006
-->

- [ ] 201811
- [ ] 201911
- [ ] 202006
- [ ] 202012
- [ ] 202106

#### Description for the changelog
<!--
Write a short (one line) summary that describes the changes in this
pull request for inclusion in the changelog:
-->


#### A picture of a cute animal (not mandatory but encouraged)
2022-01-28 10:23:38 -08:00
Mohamed Ghoneim
6100a6c8f9
[yang] Adding sonic-bgp-monitor to setup.py (#9877)
#### Why I did it
Include sonic-bgp-monitor to setup.py so it gets included in /usr/local/yang-models when installing the package

#### How I did it

#### How to verify it
install the package

#### Which release branch to backport (provide reason below if selected)

<!--
- Note we only backport fixes to a release branch, *not* features!
- Please also provide a reason for the backporting below.
- e.g.
- [x] 202006
-->

- [ ] 201811
- [ ] 201911
- [ ] 202006
- [ ] 202012
- [ ] 202106

#### Description for the changelog
<!--
Write a short (one line) summary that describes the changes in this
pull request for inclusion in the changelog:
-->


#### A picture of a cute animal (not mandatory but encouraged)
2022-01-28 10:16:27 -08:00
kellyyeh
f998684e3e
[dhcp_relay] Check payload size to prevent buffer overflow in dhcpv6 option (#9740) 2022-01-27 23:19:15 -08:00
Saikrishna Arcot
bcf5388f25
Package debugging and hardening for dhcpmon and dhcp6relay (#9862)
Enable dbgsym package for dhcpmon.

Allow CFLAGS and LDFLAGS from environment variables to be used
in the dhcp6relay build. This makes sure that the -O2 flag from
dpkg-buildflags gets used.

Finally, enable all hardening flags in dpkg-buildflags for
dhcp6relay and dhcpmon. The change from the default set of flags is that
during linking, immediate binding of symbols is done instead of lazy
binding.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2022-01-27 17:48:58 -08:00
sabari@broadcom
018a6495da
[yang] added mclag sonic yang (#7622)
#### How I did it
Added mclag sonic yang file for the MCLAG enhancements  as per HLD: Azure/SONiC#596

#### How to verify it
try rest APIs

#### Description for the changelog
Added mclag sonic yang
2022-01-27 13:09:58 -08:00
novikauanton
2532d65660
[swss] Update submodeule to fix mclagsyncd (#9837)
commit history:
*6cb43ee2 Fix mclagsyncd out of order initialization (#2112)
2022-01-27 11:41:11 -08:00
Junchao-Mellanox
c06cb219e2
Make system health service start early (#9792)
- Why I did it
For SYSTEM READY feature. Currently, there is a booting stage in system health service to indicate that the system is loading SONiC component. This booting stage is no longer needed because SYSTEM READY feature will treat that stage as system "NOT READY".

- How I did it
1. Remove booting stage
2. Adjust unit test cases

- How to verify it
Manual test, Unit test, sonic-mgmt Regression
2022-01-27 13:46:52 +02:00
Ying Xie
1ac140a945
[dhcp6relay] a couple memory access protections (#9851)
Why I did it
the strcpy and buffer allocation is not safe, it corrupts 1 byte on the stack. Depending on the memory layout, it may or may not cause issue immediately.
message type is not validated before updating the counter. Which could cause segment fault.

How I did it
Remove the unsafe strcpy, use config->interface.c_str() instead.
Check message type before updating counters.

How to verify it
The issue (1) caused segment fault on a specific platform. The fix was validated there. Issue (2) was precautionary. Added log in case it triggers.
2022-01-26 09:58:52 -08:00
ganglv
a04da0456b
[yang]: Update yang models to support 'cluster' (#9806)
Why I did it
Minigraph parser added a new field 'cluster' to device_metadata, and then yang validation is blocked.

How I did it
Add 'cluster' to device_metadata yang models.

How to verify it
Run UT for sonc-yang-models.
Use minigraph parser to generate ConfigDB schema and run yang validation.

Signed-off-by: Gang Lv ganglv@microsoft.com
2022-01-26 13:02:47 +08:00
vdahiya12
61e9a7683c
[y_cable] Support for initialization of new daemon ycable to support ycables (#9125)
* [y_cable] Support for initialization of new Daemon ycable to support
ycables
This PR also adds the commit in sonic-platform-daemons

94fa239 [y_cable] refactor y_cable to a seperate logic and new daemon from xcvrd (#219)

Why I did it
This PR separates the logic of Y-Cable from xcvrd. Before this change we were utilizing xcvrd daemon to control all aspects of Y-Cable right from initialization to processing requests from other entities like orch,linkmgr.
Now we would have another daemon ycabled which will serve this purpose.
Logically everything still remains the same from the perspective of other daemons.
it also take care aspects like init/delete daemon from Y-Cable perspective.

How I did it
To serve the purpose we build a new wheel sonic_ycabled-1.0-py3-none-any.whl and install it inside pmon.
We also initalize the daemon ycabled which serves our purpose for refactor inside pmon

How to verify it
Ran the changes with an image for dualtor tests on a 7050cx3 platform

Signed-off-by: vaibhav-dahiya <vdahiya@microsoft.com>
2022-01-25 11:10:25 -08:00
Andriy Kokhan
e88d7b3b93
[swss] Update submodule (#9816)
Update the sonic-swss submodule. The following are new commits in the submodule:

6cb43ee [p4orch] Fix handlePortStatusChangeNotification status deserialize (#2111)
863f0f1 [azp]: Enable PR diff coverage (#2083)
bf4cd4a Fix the unsafe usage of strncpy in portsorch.cpp (#2110)
c1b4b40 support port isolation group in BFN platform (#1940)


Signed-off-by: Andriy Kokhan <andriyx.kokhan@intel.com>
2022-01-21 12:07:40 -08:00
liuh-80
e639dda71b
[TACACS] fix src\tacacs\bash_tacplus\debian\rules file mode to 755 because it will be change to 755 by debian build and cause dirty image version. (#9821)
#### Why I did it
    src\tacacs\bash_tacplus\debian\rules file mode is 644, and debian build will change it to 755, which will cause image version contains 'dirty'

#### How I did it
    Change src\tacacs\bash_tacplus\debian\rules file mode to 755

#### How to verify it
    Check the image version not contains dirty

#### Which release branch to backport (provide reason below if selected)

- [ ] 201811
- [ ] 201911
- [ ] 202006
- [ ] 202012
- [ ] 202106
- [*] 202111

#### Description for the changelog
    Change src\tacacs\bash_tacplus\debian\rules file mode to 755

#### A picture of a cute animal (not mandatory but encouraged)
2022-01-21 22:28:31 +08:00
jingwenxie
7e9a198843
[yang] support ACL ACCEPT action (#9784)
Why I did it
ACL have ACCEPT action indeed, but yang doesn't support it.

How I did it
Add 'ACCEPT' enum to sonic-types.yang.j2

How to verify it
Run the YANG model unit tests
2022-01-21 11:11:54 +08:00
Jing Zhang
22e4b9be5c
[sonic-linkmgrd][master] submodule update #9808
[sonic-linkmgrd][master] submodule update

Commits added:
0c23756 Jing Zhang      2022-01-19      Linkmgrd subscribing State DB route event  (#13)
12b9951 Longxiang Lyu   2021-12-13      Add TLV support to ICMP payload (#11)
3eedda3 Longxiang Lyu   2022-01-06      Add missing intermediate states (#16)
8da4982 Ying Xie        2022-01-04      [linkmgrd] update README, set coding style guidance (#15)
a897cf8 Longxiang Lyu   2021-12-13      Improve PR template (#16)
6fec701 Jing Zhang      2021-12-06      Add pull request template for linkmgrd repo (#9)


signed-off-by: Jing Zhang zhangjing@microsoft.com
2022-01-20 17:45:55 -08:00
ganglv
d3c39d5324
[sonic-cfggen]: Feature should use 'state' to replace 'status' (#9796)
Why I did it
ConfigDB schema generated by minigraph parser can't pass yang validation.

How I did it
Modify minigraph.py, and use 'state' to replace 'status'.

How to verify it
Run UT for sonic-config-engine.
Use minigraph parser to generate ConfigDB schema, and run yang validation.

Signed-off-by: Gang Lv ganglv@microsoft.com
2022-01-20 08:51:56 +08:00
ganglv
dde5f37496
[yang]: Add Yang models for BGP monitor (#9752)
Why I did it
end2end test is blocked by Yang model for BGP monitor.

How I did it
Create new yang files for BGP monitor, and add UT.

How to verify it
Follow the steps in #9711.
Run UT for sonic-yang-models.

Signed-off-by: Gang Lv ganglv@microsoft.com
2022-01-20 08:51:12 +08:00
Junchao-Mellanox
56b5d22092
[submodule] Update submodule for sonic-platform-daemons (#9780)
c4127c2 [psud] Fix PSU log issue (#235)
07542cb [pmon][xcvrd]xcvrd process show backtrace on the internal port. (#233)
3e432e7 [Y-Cable] Increased unit test coverage of y_cable_helper.py (#229)
7c363f5 [ledd] prevent led crash on recirc port event (#232)
e9ccd82 [sonic-platform-daemons] fix dependency issue on py2 wheels by correcting the path (#234)
2b0acfb [sfp-refactoring] xcvrd: add initial support for CMIS application initialization (#217)
2022-01-19 20:33:12 +02:00
Aravind Mani
d5b0261da3
[DPB] Fix verbose mode issue (#9772) 2022-01-19 11:29:11 +05:30
Vivek Reddy
249c27b5ac
[submodule] Update sonic-utilities submodule (#9687)
```
d9f3afe [fdbshow] Adding more options for fdbshow and show mac (#1982)
902e14f Revert "Revert "[Barefoot] Added CLI to list/set P4 profile (#1951)"" (#2019)
5cc9dd5 Revert "Revert "[sonic-package-manager] support sonic-cli-gen and packages with YANG model (#1650)" (#1972)" (#1994)
```
2022-01-18 20:22:44 -08:00
Saikrishna Arcot
bb3362760d
[docker-dhcprelay]: Update to Bullseye (#9736)
As part of this, update the isc-dhcp package to match the Bullseye
version (this fixes some compile errors related to BIND), clean up some
of the build dependencies and runtime dependencies for debian packaging,
and use the default Boost version to compile against instead of
explicitly saying using 1.74.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2022-01-18 15:11:36 -08:00
xumia
40761941d4
[submodule]: update sonic-mgmt-common (#9785)
[submodule]: update sonic-mgmt-common
2022-01-18 21:05:46 +08:00
nkelapur
9b937497ca
Fix IPv4 routes with IPv6 link local next hops installed in FPM (#8740)
* Description: Currently IPv4 routes with IPv6 link local next hops are
not properly installed in FPM.
Reason is the netlink decoding truncates the ipv6 LL address to 4 byte
ipv4 address.

Ex : fe80:: is directly converted to ipv4 and it results in 254.128.0.0
as next hop for below routes

show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP,
O - OSPF, I - IS-IS, B - BGP, E - EIGRP, N - NHRP,
T - Table, v - VNC, V - VNC-Direct, A - Babel, D - SHARP,
F - PBR, f - OpenFabric,
> - selected route, * - FIB route, q - queued, r - rejected, b - backup

B>* 2.1.0.0/16 [200/0] via fe80::268a:7ff:fed0:d40, Ethernet0, weight 1,
02:22:26
B>* 5.1.0.0/16 [200/0] via fe80::268a:7ff:fed0:d40, Ethernet0, weight 1,
02:22:26
B>* 10.1.0.2/32 [200/0] via fe80::268a:7ff:fed0:d40, Ethernet0, weight
1, 02:22:26

Hence this fix converts the ipv6-LL address to ipv4-LL (169.254.0.1)
address before sending it to FPM. This is inline with how these types of
routes are currently programmed into kernel.

Signed-off-by: Nikhil Kelapure <nikhil.kelapure@broadcom.com>
2022-01-17 19:40:50 -08:00
xumia
5fb21ce9fd
[submodule]: update sonic-utilities (#9773)
[submodule]: update sonic-utilities
2022-01-18 08:36:33 +08:00
Aravind Mani
d5d642f348
[Submodule] sonic-platform-common submodule update (#9753) 2022-01-15 10:43:25 +05:30
Anish Narsian
cd26122dd6
[Yang] Add resource_type and downstream_subrole to yang model (#9696)
#### Why I did it
As a fix for https://github.com/Azure/sonic-buildimage/issues/9574

#### How I did it
Enhance yang model for networking-metadata

#### How to verify it
Unit testing
2022-01-14 15:37:20 -08:00
abdosi
582a21d6c5
[submodule update] sonic-swss (#9751)
[Submodule update] sonic-swss

    c78aa1b81a3a9001669746067ebbe40b4485f71d (HEAD -> master, origin/master, origin/HEAD) OA changes to support Ordered ECMP and DVS test for same. (#2092)
    b4b00031378a6ce303b779159e718d6d20790c11 Handling Invalid CRM configuration gracefully (#2109)
    d240cb2d356ec17baa464455f37f88ac5dbc441a [Mellanox] '_8lane' not added to Mellanox 5xxx models with 800G (#2090)
    8fd6e488d2a3696b9cfe352a9119c86f0f33e6dc [pfcwd] Add vs test infrastructure (#2077)
    b96ee5438b8bf08980846ee84ff69e7ba267b0dc [vnetorch] Advertise vnet tunnel routes (#2058)
2022-01-13 10:53:27 -08:00
abdosi
6076cd1c9d
[submodule update] sonic-sairedis (#9750)
[submodule update] sonic-sairedis

    d5866a3dccfb3bc50853d740d54203b5cae61eed (HEAD -> master, origin/master, origin/HEAD) [vslib]: fix create MACsec SA error (#986)
    f36f7ce6236ae97526e15f00e7688ccced7c0454 Added Support for enum query capability of Nexthop Group Type. (#989)
    323b89b14995a84bd6539c8a1df00b77d251f99e Support for MACsec statistics (#892)
    26a8a1204e873109537c81462ad1457cf38c2f9e Prevent other notification event storms to keep enqueue unchecked and drained all memory that leads to crashing the switch router (#968)
    0cb253a42cd0a641b8e0a3c6a4a54e5397dd8c2d Fix object availability conversion (#974)
2022-01-13 08:17:39 -08:00
Ze Gan
5cdfffe2fc
[submodule]: update sonic-wpa-supplicant (#9388)
457e94d51 [macsec_linux]: Fixbug cannot dump the PN due to type error (#42)
f7c073323 Disable P2P module (#41)
7b3b777e2 [ci]: use native arm64 and armhf build pool (#40)
d4e91d66c [sonic_operator]: Increase wait timeout (#39)
43611ef88e [sonic_operators]: Add log in sonic operators (#43)

Signed-off-by: Ze Gan <ganze718@gmail.com>
2022-01-12 20:27:02 -08:00
abdosi
649e6c7307
[minigraph] Enhanced parser to parse interface name for static route nexthop (#9707)
What I did:-

Enhanced minigraph parser to parse interface name associated with static route nexthop

Why I did:-

One of the use case to support interface name is Chassis Packet. For Chassis Packet we have Static Routes configured to route traffic across line-card. If the FRR programs static route without the interface name then in case if the ip interface that is associated with the nexthop goes down FRR resolves static route nexthop over the default route as we have FRR config ip nht-resolve-via-default which causes undesired behavior. Having interface name with Static Route prevents recursive lookup on default route.

How I verify:

Updated unit-test cases
Manual verification
2022-01-12 18:48:23 -08:00
ganglv
c69d376071
[yang]: Update AAA yang models (#9724)
#### Why I did it
AAA yang model is not up to date.

#### How I did it
Add fallback and trace field, and replace boolean_type

#### How to verify it
Run UT for sonic_yang_models.
Follow the steps from #9710
2022-01-12 10:23:11 -08:00
ganglv
c11ab02ab1
[sonic-cfggen]: Add bgp asn for yang validation (#9640)
Why I did it
Config db schema generated by minigraph can’t pass yang validation, bgp_asn must not be None.

How I did it
Update sampe-voq-graph.xml to add bgp_asn.

How to verify it
Build sonic-config-engine.
Run command 'sonic-cfggen -m tests/sample-voq-graph.xml -p tests/voq-sample-port-config.ini --print-data', and check bgp_asn.

Signed-off-by: Gang Lv ganglv@microsoft.com
2022-01-12 15:25:38 +08:00
Shi Su
ac894b394f
[swss] Update submodule (#9723)
Why I did it
Update the sonic-swss submodule. The following are new commits in the submodule.

6dae6b8 Add initial value for weight in overlay nexthops (#2096)
d3cd402 [p4rt-tests] Bind response consumer to appl_state_db (#2105)
43e54e5 Fix armhf buildimage artifacts not found issue (#2107)

How I did it
Update the swss submodule pointer.
2022-01-11 09:42:09 -08:00
Saikrishna Arcot
fee2441717
Create docker-base-bullseye and docker-config-engine-bullseye (#9666)
* [slave-bullseye]: Remove Python 2

It shouldn't be needed anymore.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>

* [dockers]: Add docker-base-bullseye and docker-config-engine-bullseye

Also upgrade socat from 1.7.3.1 to 1.7.4.1

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2022-01-11 09:23:42 -08:00
Shilong Liu
94b778c39b
[build] docker-sonic-mgmt replace USER by whoami (#9702) 2022-01-11 16:48:04 +08:00
Kerry Meyer
9b795dbf09
Showtech sonic mgmt framework: Add Management Framework functionality for "show tech-support" (#7816)
Provide the changes required for supporting the "show-techsupport" command via the SONiC Management Framework front end mechanisms (CLI, REST, and gNOI). The Management Framework functionality implemented by this PR improves on the the capabilities currently provided by the SONiC Click CLI interface via the "show techsupport" command by providing the following additional features:

- User-friendly "help" information describing command syntax details for CLI invocation.
- Ability to invoke the command via REST and gNOI mechanisms.

Unit test results are attached to this PR.
2022-01-10 14:36:34 -08:00
Lawrence Lee
8e6b194b17
[YANG]: Add support for dual ToR attributes (#9698)
Fixes #9561
Fixes #9570 
Fixes #9563
Partial fix for #9556 

#### Why I did it
- Attributes for dual ToR configs lack YANG model support

#### How I did it
- Extend YANG tests to cover dual ToR use cases
- Extend YANG model to cover dual ToR use cases
- Reduce the default log level to warning so only test failures are printed

#### How to verify it
- Run the YANG model unit tests
2022-01-10 12:24:51 -08:00
Longxiang Lyu
58c5bb6513
[Yang] Add YANG model support for vlan sub interface (#9269)
Why I did it
Add YANG model file for table VLAN_SUB_INTERFACE

How I did it
Add YANG model file sonic-vlan-sub-interface.yang to describe data structure
modify existing unit-test to cover vlan sub interface

How to verify it
Build sonic-yang-models and sonic-yang-mgmt without errors
2022-01-10 10:49:10 +08:00
Qi Luo
d7ffcf1773
[minigraph] do not use NULL:NULL explicitly in json (#9703)
#### Why I did it
It should be handled by `ConfigDBConnector.typed_to_raw()`.

This is a bug for `sonic-cfggen -m --print-data` only
```
    "PORTCHANNEL_MEMBER": {
        "PortChannel0001|Ethernet112": {
            "NULL": "NULL"
        },
        "PortChannel0002|Ethernet116": {
            "NULL": "NULL"
        },
        "PortChannel0003|Ethernet120": {
            "NULL": "NULL"
        },
        "PortChannel0004|Ethernet124": {
            "NULL": "NULL"
        }
    },
```
But not appears in `sonic-cfgen -d --print-data`.
```
    "PORTCHANNEL_MEMBER": {
        "PortChannel0001|Ethernet112": {},
        "PortChannel0002|Ethernet116": {},
        "PortChannel0003|Ethernet120": {},
        "PortChannel0004|Ethernet124": {}
    },
```
Tested in a T0 KVM.
2022-01-07 22:20:31 -08:00
anamehra
e5d5f80d14
Cache connection handles to prevent duplicate (#9636)
On a multi-asic Supervisor card, running commands like
'show interface counter' opens a confid_db connection per
namespace per interface which results in many duplicate connections
exceeding the allowed open file handles. This causes the command to fail.

Caching the connections to prevent duplicate handles.
2022-01-07 12:58:01 -08:00
abdosi
6c507329b7
Enable/Disable Order ECMP feature. (#9651)
Updated Jinja2 Template in switch.json.j2 for enabling/disabling Order ECMP feature based on device role.
Changes as per design: Azure/SONiC#896
2022-01-06 16:40:50 -08:00
ganglv
abbd173845
[sonic-cfggen]: Remove wrong portchannel members (#9614)
Why I did it
Config db schema generated by minigraph can’t pass yang validation, portchannel_member has invalid port.

How I did it
Update test minigraph to remove invalid port channel.

How to verify it
Build sonic-config-engine.
Run command 'sonic-cfggen -m xxx.xml --print-data', and check port channel member.

Signed-off-by: Gang Lv ganglv@microsoft.com
2022-01-06 09:14:36 +08:00
ganglv
52fdb8e42e
[yang]: Support VLAN alias (#9615)
Why I did it
Config db schema generated by minigraph can’t pass yang validation, and there's no 'alias' field in yang model.
Minigraph parser supports 'alias' field for VLAN.

How I did it
Add 'alias' field to sonic-vlan.yang

How to verify it
Build sonic-yang-models.
Run command 'sonic-cfggen -m xxx.xml --print-data', and run yang validation.

Signed-off-by: Gang Lv ganglv@microsoft.com
2022-01-05 10:27:29 -08:00
ganglv
5efebad24e
[sonic-cfggen]: Fix missing vlan interface (#9639)
Why I did it
Config db schema generated by minigraph can’t pass yang validation, there's no Vlan31 in 'VLAN' table.

How I did it
Update test minigraph to add vlan interface.

How to verify it
Build sonic-yang-models.
Run command 'sonic-cfggen -m tests/fg-ecmp-sample-minigraph.xml -p tests/mellanox-sample-port-config.ini --print-data', and run yang validation.

Signed-off-by: Gang Lv ganglv@microsoft.com
2022-01-05 10:10:46 -08:00
Shilong Liu
3844ae8290
Fix docker-sonic-mgmt reproducible related issue. (#9647)
Reproducible build script breaks docker-sonic-mgmt build.
2022-01-05 11:54:19 +08:00
Mohamed Ghoneim
98da6ebaa7
[sonic-yang-mgmt] Adding flag to disable/enable log printing (#9659)
#### Why I did it
Fixes https://github.com/Azure/sonic-utilities/issues/1871

From [generic-config-updater](https://github.com/Azure/sonic-utilities/tree/master/generic_config_updater) we call `sonic-yang-mgmt` multiple times in order to check a certain change to ConfigDb is valid or not. It is expected for some changes to be invalid, so always printing errors from `sonic-yang-mgmt` makes the output hard to read.

In this PR, we are adding a way to control if logs should be printed or not.

#### How I did it
- Added `print_log_enabled` flag to sonic_yang ctor
- Converted all `print` statements to `sysLog(..., doPrint=True)`

#### How to verify it
unit-test passing means the change did not break logs.

#### Info about libyang logging
libyang provides an extensive logging logic which can support a lot of scenarios:
- ly_log_level: setting logging level
  - LY_LLERR
  - LY_LLWRN
  - ... 
- ly_set_log_clb: setting log callback to customize the default behavior which is printing the msgs
- ly_log_options: setting logging options 
  - LY_LOLOG: If callback is set use it, otherwise just print. If flag is not set, do nothing.
  - ...

For more info refer to:
- https://netopeer.liberouter.org/doc/libyang/devel/html/group__logopts.html#gaff80501597ed76344a679be2b90a1d0a
- https://netopeer.liberouter.org/doc/libyang/devel/html/group__log.html#gac88b78694dfe9efe0450a69603f7eceb


#### What's next?
Consume the new flag `print_log_enabled` in [generic-config-updater](https://github.com/Azure/sonic-utilities/tree/master/generic_config_updater) to reduce the logging clutter. 

#### Which release branch to backport (provide reason below if selected)

<!--
- Note we only backport fixes to a release branch, *not* features!
- Please also provide a reason for the backporting below.
- e.g.
- [x] 202006
-->

- [ ] 201811
- [ ] 201911
- [ ] 202006
- [ ] 202012
- [ ] 202106

#### Description for the changelog
<!--
Write a short (one line) summary that describes the changes in this
pull request for inclusion in the changelog:
-->


#### A picture of a cute animal (not mandatory but encouraged)
2022-01-04 19:42:10 -08:00
Sudharsan Dhamal Gopalarathnam
b96533342f
[sonic-ztp] Submodule update (#9589)
Updating ztp submodule to include the below commits
f7dd3c5 [sonic-ztp]Fixing build failure after bullseye integration (#30)
9218e16 Replace swsssdk.ConfigDBConnector and SonicV2Connector with swsscommon(#28)

Signed-off-by: Sudharsan Dhamal Gopalarathnam <sudharsand@nvidia.com>
2022-01-02 17:56:14 +02:00
Stephen Sun
b749c67ac5
[sonic-swss] Submodule update (#9397)
691c37b7 [Route bulk] Fix bugs in case a SET operation follows a DEL operation in the same bulk (Azure/sonic-swss#2086)
a4c80c3d patch for issue Azure/sonic-swss#1971 - enable Rx Drop handling for cisco-8000 (Azure/sonic-swss#2041)
71751d10 [macsec] Support setting IPG by gearbox_config.json (Azure/sonic-swss#2051)
5d5c1692 [bulk mode] Fix bulk conflict when in case there are both remove and set operations (Azure/sonic-swss#2071)
8bbdbd2b Fix SRV6 NHOP CRM object type (Azure/sonic-swss#2072)
ef5b35f3 [vstest] VS test failure fix after fabric port orch PR merge (Azure/sonic-swss#1811)
89ea5385 Supply the missing ingress/egress port profile list in document (Azure/sonic-swss#2064)
81234373 [pfc_detect] fix RedisReply errors (Azure/sonic-swss#2040)
b38f527a [swss][CRM][MPLS] MPLS CRM Nexthop - switch back to using SAI OBJECT rather than SWITCH OBJECT
ae061e55 create debug_shell_enable config to enable debug shell (Azure/sonic-swss#2060)
45e446d9 [cbf] Fix max FC value (Azure/sonic-swss#2049)
b1b5b297 Initial p4orch pytest code. (Azure/sonic-swss#2054)
d352d5a9 Update default route status to state DB (Azure/sonic-swss#2009)
24a64d65 Orchagent: Integrate P4Orch (Azure/sonic-swss#2029)
15a3b6ca Delete the IPv6 link-local Neighbor when ipv6 link-local mode is disabled (Azure/sonic-swss#1897)
ed783e1f [orchagent] Add trap flow counter support (Azure/sonic-swss#1951)
e9b05a31 [vnetorch] ECMP for vnet tunnel routes with endpoint health monitor (Azure/sonic-swss#1955)
bcb7d61a P4Orch: inital add of source (Azure/sonic-swss#1997)
f6f6f867 [mclaglink] fix acl out ports (Azure/sonic-swss#2026)
fd887bf8 [Reclaim buffer] Reclaim unused buffer for dynamic buffer model (Azure/sonic-swss#1910)
92589789 [orchagent, cfgmgr] Add response publisher and state recording (Azure/sonic-swss#1992)
3d862a72 Fixing subport vs test script for subport under VNET (Azure/sonic-swss#2048)
fb0a5fd8 Don't handle buffer pool watermark during warm reboot reconciling (Azure/sonic-swss#1987)
16d4bcdb Routed subinterface enhancements (Azure/sonic-swss#1907)
9639db78 [vstest/subintf] Add vs test to validate sub interface ingress to a vnet (Azure/sonic-swss#1642)

Signed-off-by: Stephen Sun stephens@nvidia.com
2021-12-28 14:53:16 +02:00
Stepan Blyshchak
13582aaa6d
[sonic-yang] fix the feature state type (#9587)
- Why I did it
The feature state can be a jinja template, like in this file - https://github.com/Azure/sonic-buildimage/blob/master/files/build_templates/init_cfg.json.j2#L39.
Without this change it is not possible to validate a configuration file.

- How I did it
Relaxes the constraint on feature state. Feature state leaf can be any string.

- How to verify it
Run UT.

Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
2021-12-28 09:42:05 +02:00
ganglv
48a648c943
[sonic-cfggen]: Fix syslog_server output (#9616)
Why I did it
'SYSLOG_SERVER': {'': {}, '10.0.10.5': {}, '10.0.10.6': {}},
Config db schema generated by minigraph can’t pass yang validation, server address can't be empty.

How I did it
Update test minigraph to remove wrong configuration.

How to verify it
Build sonic-config-engine.
Run command 'sonic-cfggen -m xxx.xml --print-data', and SYSLOG_SERVERS table.

Signed-off-by: Gang Lv ganglv@microsoft.com
2021-12-23 10:03:28 +08:00
ganglv
3aec72879d
[sonic-cfggen]: Update test minigraph to fix interface (#9601)
Why I did it
Config db schema generated from test minigraph can't pass yang validation.

How I did it
Update test minigraph to fix interface

How to verify it
Build sonic-config-engine.
Run command 'sonic-cfggen -m xxx.xml --print-data', and check interface table and port table.

Signed-off-by: Gang Lv ganglv@microsoft.com
2021-12-21 19:08:15 +08:00
ganglv
67e40b5531
[sonic-cfggen]: Update test minigraph to add deployment_id (#9593)
Why I did it
Config db schema generated from test minigraph can't pass yang validation.

How I did it
Update minigraph xml to add DeploymentId.

How to verify it
Build sonic-config-engine.
Run command 'sonic-cfggen -m xxx.xml --print-data', and check deployment_id field.

Signed-off-by: Gang Lv ganglv@microsoft.com
2021-12-21 09:14:44 +08:00
ganglv
dfddd55cbf
[yang]: Add constraint for pfcwd (#9513)
#### Why I did it
POLL_INTERVAL cannot be set if any of the detection/restoration times in this table is less than the POLL_INTERVAL.

#### How I did it
Add "must" constraint to make sure detection/restoration times are greater than POLL_INTERVAL.

#### How to verify it
Use apply-patch command to update POLL_INTERVAL.
Build sonic-yang-model.
2021-12-20 11:15:39 -08:00
Oleksandr Ivantsiv
3af4a9619e
[sonic-config-engine]: Improve comparison between default and supported breakout modes. (#9278)
Closes #7958 

#### Why I did it
The previous implementation of sonic-cfggen did a simple comparison between default breakout mode in
hwsku.json and supported modes in platform.json. To set a different default speed in hwsku.json
it was required to add one more entry to supported modes in platfrom.json file:

1x10G[100G,50G] vs 1x100G[50G,10G]

The new implementation does more intelligent parsing and analysis of supported and default modes. It
allows changing default speed without adding a new entry to platform.json.

#### How I did it
Add more intelligent parsing and analysis of supported and default modes.

#### How to verify it
Run sonic-config-engine unit tests from sonic-config-engine/tests directory
2021-12-20 08:56:08 -08:00
Qi Luo
0d327abe93
[sonic-utilities] submodule update (#9315)
#### Why I did it
Including below commits:
```
fe00bbf 2021-12-17 | Revert "[sonic-package-manager] support sonic-cli-gen and packages with YANG model (#1650)" (#1972) [Prince George]
5fe6d92 2021-12-16 | [warm/fast-reboot] Fix kexec portion to support platforms based on Device Tree (#1966) [dflynn-Nokia]
74d2a09 2021-12-17 | [portstat] check TX/RX utilization calculation correctness (#1840) [Andriy Yurkiv]
e44c3f6 2021-12-16 | [generic-config-updater] Improving CreateOnly validator and marking /LOOPBACK_INTERFACE/LOOPBACK#/vrf_name as create-only (#1969) [Mohamed Ghoneim]
0067cc4 2021-12-15 | [build] adapt for upstream target path change (#1971) [Qi Luo]
96143ee 2021-12-09 | preserve old order for config reload (#1964) [arlakshm]
f08c81d 2021-12-10 | [vxlan] remove unnecessary whitespace for show commands (#1792) [Gord Chen]
14889ce 2021-12-09 | [soft-reboot] Add support for platforms based on Device Tree (#1963) [dflynn-Nokia]
7ceccd7 2021-12-08 | [generic-config-updater] Adding non-strict mode (#1929) [Mohamed Ghoneim]
2e462ef 2021-12-07 | [sfputil] Firmware download/upgrade CLI support for QSFP-DD (#1947) [Prince George]
7c34b79 2021-12-07 | [config] Add portchannel support  for static route  (#1857) [Dmytro]
54cc370 2021-12-06 | [doc] Refine doc on show loopback/mgmt ports (#1958) [Qi Luo]
3714f63 2021-12-06 | [port2alias]: Fix to get right number of return values (#1906) [SuvarnaMeenakshi]
3fa0854 2021-12-06 | [CLI][show bgp] On chassis don't show internal BGP sessions by default (#1927) [Mahesh Maddikayala]
6de91af 2021-12-06 | [Auto-Techsupport] Issues related to Multiple Cores crashing handled (#1948) [Vivek Reddy]
656ade1 2021-12-06 | SFP-Refactor: Vendor revision is not displayed properly (#1950) [Aravind Mani]
67466cb 2021-12-05 | [port] Fix port speed set (#1952) [Mykola Gerasymenko]
5172972 2021-12-04 | Fix invalid output of syslog IPv6 servers (#1933) [jingwenxie]
290ff5f 2021-12-03 | Routed subinterface enhancements (#1821) [Preetham]
1ea88e2 2021-12-01 | Enhance sfputil for CMIS QSFP (#1949) [andywongarista]
4e132c1 2021-11-30 | [debug dump] Refactoring Modules and Unit Tests (#1943) [Vivek Reddy]
b550c44 2021-11-30 | Add command reference for trap flow counters (#1876) [Junchao-Mellanox]
67a267b 2021-11-30 | [Reclaim buffer] [Mellanox] Db migrator support reclaiming reserved buffer for unused ports (#1822) [Stephen Sun]
30e4654 2021-11-25 | Add show command for BFD sessions (#1942) [Shi Su]
e63f47e 2021-11-25 | [warm-reboot] Fix failures of warm reboot on disconnect of ssh session (#1529) [maksymbelei95]
c05845d 2021-11-25 | Add trap flow counter support (#1868) [Junchao-Mellanox]
ef82f00 2021-11-24 | [load_minigraph] Delay pfcwd start until the buffer templates are rendered (#1937) [Neetha John]
f5e5a56 2021-11-24 | [sonic-package-manager] support sonic-cli-gen and packages with YANG model (#1650) [Stepan Blyshchak]
64777a4 2021-11-23 | generic_config_updater: Filename changed & VLAN validator added (#1919) [Renuka Manavalan]
1f8f6ab 2021-11-23 | [config reload] Update command reference (#1941) [Sudharsan Dhamal Gopalarathnam]
```
2021-12-19 23:06:25 -08:00
Sumukha Tumkur Vani
17c2949d31
[RESTAPI] Update submodule (#9547) 2021-12-17 09:21:32 -08:00
mohan-selvaraj
36673c135c
[yang] sonic yang changes for BUM storm control (#7355)
#### Why I did it
Sonic yang model for BUM storm control

#### How I did it
Added yang model and the corresponding test cases. 

#### How to verify it
yang model test case for storm control
2021-12-16 10:14:47 -08:00
liuh-80
734b1bfee6
[TACACS] Fix auditd can't load tacplus plugin issue. (#9481)
<!--
     Please make sure you've read and understood our contributing guidelines:
     https://github.com/Azure/SONiC/blob/gh-pages/CONTRIBUTING.md

     ** Make sure all your commits include a signature generated with `git commit -s` **

     If this is a bug fix, make sure your description includes "fixes #xxxx", or
     "closes #xxxx" or "resolves #xxxx"

     Please provide the following information:
-->

#### Why I did it
1. Fix auditd log file path, because known issue: https://github.com/Azure/sonic-buildimage/issues/9548

2. When SONiC change to based on bullseye, auditd version upgrade from 2.8.4 to 3.0.2, and in auditd 3.0.2 the plugin file path changed to /etc/audit/plugins.d, however the upstream auditisp-tacplus project not follow-up this change, it still install plugin config file to /etc/audit/audisp.d. so the plugin can't be launch correctly, the code change in src/tacacs/audisp/patches/0001-Porting-to-sonic.patch fix this issue.
#### How I did it
        Fix tacacs plugin config file path.
        Create /var/log/audit folder for auditd.

#### How to verify it
        Pass all UT, also run per-command acccounting UT to validate plugin loaded.

#### Which release branch to backport (provide reason below if selected)

<!--
- Note we only backport fixes to a release branch, *not* features!
- Please also provide a reason for the backporting below.
- e.g.
- [x] 202006
-->

- [ ] 201811
- [ ] 201911
- [ ] 202006
- [ ] 202012
- [ ] 202106

#### Description for the changelog
<!--
Write a short (one line) summary that describes the changes in this
pull request for inclusion in the changelog:
-->
        Fix tacacs plugin config file path.
        Create /var/log/audit folder for auditd.

#### A picture of a cute animal (not mandatory but encouraged)
2021-12-16 11:02:58 +08:00
Mohamed Ghoneim
2c5794f62d
[yang-model] Using 'leafref' instead of 'must' for loopback (#9535)
#### Why I did it
Fix issue https://github.com/Azure/sonic-utilities/issues/1962

The problem is current implementation of [sonic-yang-mgmt::find_data_dependencies](f2774b635d/src/sonic-yang-mgmt/sonic_yang.py (L518)) does not get referrers if they are using `must` statement, it has to use `leafref`.

For now we can convert `must` to `leafref` if possible. In the future we will investigate get referrers by `must` statements as well https://github.com/Azure/sonic-buildimage/issues/9534

#### How I did it
Instead of `must` use `leafref`

#### How to verify it
unit-test

#### Which release branch to backport (provide reason below if selected)

- [ ] 201811
- [ ] 201911
- [ ] 202006
- [ ] 202012
- [ ] 202106
2021-12-15 17:19:57 -08:00
tomer-israel
6a0bb3a2af
[LLDPD] fix to port remove and immediately create problem (#9519)
[LLDPD] fix to port remove and immediately create a problem - on delete link events it will immediately execute delete without using aggregate events mechanism.

This patch was added to LLDPD on this PR:
lldpd/lldpd#492

Signed-off-by: tomeri <tomeri@nvidia.com>
2021-12-15 13:06:40 -08:00
dependabot[bot]
2a467f8eb4
Bump lxml from 4.6.3 to 4.6.5 in /src/sonic-config-engine (#9522)
Bumps [lxml](https://github.com/lxml/lxml) from 4.6.3 to 4.6.5.
- [Release notes](https://github.com/lxml/lxml/releases)
- [Changelog](https://github.com/lxml/lxml/blob/master/CHANGES.txt)
- [Commits](https://github.com/lxml/lxml/compare/lxml-4.6.3...lxml-4.6.5)

---
updated-dependencies:
- dependency-name: lxml
  dependency-type: direct:production
2021-12-13 20:20:48 -08:00
abdosi
6c0da4bcf0
[bgp] Enable BGP Graceful Restart based on device role (#9486)
What I did:
Updated Jinja Template to enable BGP Graceful Restart based on device role. By default it will be enable only if the device role type is TorRouter.

Why I did:-
By default FRR is configured in Graceful Helper mode. Graceful Restart is needed on T0/TorRouter only since the device can go for warm-reboot. For T1/LeafRouter it need to be in Helper mode only
2021-12-13 10:14:50 -08:00
Samuel Angebault
6cf06637f6
[sonic-py-common] Add recirc_prefix definition (#9471)
This interface type is used for recirculation on chassis.
The definition is required to prevent this interface from being
considered a physical interface in sonic-platform-common and
sonic-platform-daemon
2021-12-12 18:09:51 -08:00
Mykola Gerasymenko
afd40984fc
[DPB][YANG] Fix cases when boolean is used in different literal cases (#9418)
Fixes #9326

#### Why I did it
When we try execute DPB from CLI we have error:
`libyang[0]: Invalid value "False" in "has_global_scope" element. (path: /sonic-feature:sonic-feature/FEATURE/FEATURE_LIST[name='bgp']/has_global_scope)`
The reason for this issue is that has_global_scope and other have been stored in redis database with value False or True form capital letter:
```
   "FEATURE":{
      "bgp":{
         "auto_restart":"enabled",
         "has_global_scope":"False",
         "has_per_asic_scope":"True",
         "has_timer":"False",
         "high_mem_alert":"disabled",
         "state":"enabled"
      }
```
But yang model support boolean just in lowercase letters (https://datatracker.ietf.org/doc/html/rfc6020#section-9.5.1).
#### How I did it
Added boolean to sonic-types as typedef with different literal cases.

#### How to verify it
Run the command config interface breakout <breakout_mode>

**NOTE:**
To verify this fix, the following PRs that fix other problems in SONiC must be merged into master:
1) Azure/sonic-buildimage/pull/9075
2) Azure/sonic-buildimage/pull/9276
2021-12-10 10:34:02 -08:00
Neetha John
5384b30d3c
[yang] Add missing device types to the device_metadata yang (#9464)
Signed-off-by: Neetha John <nejo@microsoft.com>

Bring back the changes in #9226 that were reverted. Unable to do a revert-revert.

Why I did it
Few device types were missing in the DEVICE_METADATA type field

How I did it
Added missing device types to the device metadata yang
2021-12-10 09:26:08 -08:00
Mohamed Ghoneim
02d273274f
[yang-models] Validating 'services' exist if ACL type is 'CTRLPLANE' (#9295)
#### Why I did it
Fixing issue #9294

#### How I did it
Updating ACL yang model

#### How to verify it

Validating issue with `config patch-apply` is fixed.

- Start a KVM
- Add file `add-ctrl-plane-tbl.json-patch ` with content:
```json
[
    {
     "op": "add",
     "path": "/ACL_TABLE/ACTRLPLANETABLE",
     "value": {
      "policy_desc": "ACTRLPLANETABLE",
      "services": [
       "SSH"
      ],
      "stage": "ingress",
      "type": "CTRLPLANE"
     }
    }
]
```
- Run `sudo config apply-patch add-ctrl-plane-tbl.json-patch`


Before:
```
Patch Applier: The patch was sorted into 4 changes:
Patch Applier:   * [{"op": "add", "path": "/ACL_TABLE/ACTRLPLANETABLE", "value": {"type": "CTRLPLANE"}}]
Patch Applier:   * [{"op": "add", "path": "/ACL_TABLE/ACTRLPLANETABLE/policy_desc", "value": "ACTRLPLANETABLE"}]
Patch Applier:   * [{"op": "add", "path": "/ACL_TABLE/ACTRLPLANETABLE/services", "value": ["SSH"]}]
Patch Applier:   * [{"op": "add", "path": "/ACL_TABLE/ACTRLPLANETABLE/stage", "value": "ingress"}]
```

After:
```
Patch Applier: The patch was sorted into 1 change:
Patch Applier:   * [{"op": "add", "path": "/ACL_TABLE/ACTRLPLANETABLE", "value": {"policy_desc": "ACTRLPLANETABLE", "services": ["SSH"], "stage": "ingress", "type": "CTRLPLANE"}}]
```

#### Which release branch to backport (provide reason below if selected)

<!--
- Note we only backport fixes to a release branch, *not* features!
- Please also provide a reason for the backporting below.
- e.g.
- [x] 202006
-->

- [ ] 201811
- [ ] 201911
- [ ] 202006
- [ ] 202012
- [ ] 202106

#### Description for the changelog
<!--
Write a short (one line) summary that describes the changes in this
pull request for inclusion in the changelog:
-->


#### A picture of a cute animal (not mandatory but encouraged)
2021-12-10 08:04:41 -08:00
arlakshm
327ad41bee
[yang] add set_owner to feature yang (#9075)
#### Why I did it
Add the configuration for the set_owner in the `feature` yang model

#### How I did it
Add new leaf `set_pwner` to the `feature` yang model

#### How to verify it
compile `sonic_yang_mgmt-1.0-py3-none-any.whl`
2021-12-09 23:18:45 -08:00
Abhishek
adf52c2581
[yang] SONiC MAC ACL Yang model update to add support for Source MAC, Destination MAC, Ethertype pattern update, VLAN_ID, PCP, DEI fields (#7917)
#### Why I did it
Currently only IP ACL and related model is defined. Support for MAC ACL is missing. Added support for it.

#### How I did it
ACL_RULE table is added with new MAC ACL related fields namely Source MAC, Destination MAC, Ethertype (Pattern updated to match any valid Ethertypes), VLAN, PCP, DEI

#### How to verify it
Yang model tests are attached.
2021-12-09 11:19:16 -08:00
MaratGubaiev
4562b82bf2
[yang] sonic-bgp-cmn/admin_status fixed (#9429)
#### Why I did it
fixing https://github.com/Azure/sonic-buildimage/issues/9350 "[yang-models] BGP neighbor admin_status should be up/down"
2021-12-09 10:19:05 -08:00
Longxiang Lyu
b88f68b1d6
[YANG] add YANG model support for CABLE_LENGTH (#9273)
Why I did it
Add YANG model support for table CABLE_LENGTH

How I did it
Add the YANG model file
Add the test description file and config file
add list CABLE_LENGTH_LIST to the qos_maps_model list in sonic-yang-ext, as it has an inner list.

How to verify it
Build sonic-yang-model and sonic-yang-mgmt
2021-12-09 09:34:01 -08:00
Stephen Sun
5ac4d42c44
[Unit test] Fix sonic config engine unit test failure (#9454)
- Why I did it
Fix sonic-config-engine unit test failure

- How I did it
 * Do not use pytest fixture in the test since it is not compatible with unittest framework which is used by all of the rest test cases.
 * Supply 2 missing files

- How to verify it
Run unit test or compile the module (when the unit test will run automatically)

Signed-off-by: Stephen Sun <stephens@nvidia.com>
2021-12-09 17:39:28 +02:00
Aravind Mani
fc91dae023
submodule platform daemon update (#9461) 2021-12-09 12:41:17 +05:30
Aravind Mani
66d55757c0
[Submodule]Update sonic-platform-common submodule (#9466) 2021-12-09 12:38:21 +05:30
ganglyu
3c1770b7cb
[yang]: update Yang models for cloudtype and region (#9425)
Why I did it
#9122
DEVICE_METADATA does not have cloudtype and region.

How I did it
Add cloudtype and region to DEVICE_METADATA.

How to verify it
Follow the steps in #9122.
Build sonic-yang-model.

Signed-off-by: Gang Lv ganglv@microsoft.com
2021-12-09 09:04:52 +08:00
Jing Zhang
a263edbc98
[sonic-linkmgrd][master] submodule update (#9420)
#### What I did 

[sonic-linkmgrd][master] submodule update

6c6151b Fix unstable unit tests (state change handler wasn't invoked) (#8)
2f7dc0a support code diff coverage (#5)
83f0002 Force mux state switch to standby if triggered from Cli (#6)

signed-off-by: Jing Zhang zhangjing@microsoft.com
2021-12-08 08:54:00 -08:00
Mykola Gerasymenko
b0f06bab90
[DPB][YANG] Add POLL_INTERVAL in flex_counter yang model (#9276)
#### Why I did it
DPB falls due to missing POLL_INTERVAL in sonic-flex_counter yang model.

#### How I did it
Added POLL_INTERVAL leaf to ACL container in sonic-flex_counter yang model.

#### How to verify it
Run the command config interface breakout <interface> <breakout_mode>

**NOTE:**
To verify this fix, a PR ([add set_owner to feature yang](https://github.com/Azure/sonic-buildimage/pull/9075)) that fix another bug in SONiC should be merged to master.
2021-12-08 00:21:33 -08:00
arlakshm
1509f433fd
[yang] syslog yang model (#9265)
Why I did it
Add yang model for syslog server

How I did it
Add new file sonic-syslog.yang and new files for tests

How to verify it
Compile target/python-wheels/sonic_yang_mgmt-1.0-py3-none-any.whl

Signed-off-by: Arvindsrinivasan Lakshmi Narasimhan arlakshm@microsoft.com
2021-12-07 14:12:26 -08:00
thomas.cappleman@metaswitch.com
7ebe44a2a0
[chassis] Fix uninitialized variable in minigraph parsing (#8917)
Why I did it
Local variable may not be created in minigraph parsing, causing crash

How I did it
Moved variable creation earlier
2021-12-07 11:33:17 -08:00
Brian O'Connor
46bcda359c
[PINS] Build P4RT container for PINS (#9083)
- Add INCLUDE_PINS to config to enable/disable container
- Add Docker files and supporting resources
- Add sonic-pins submodule and associated make files

Submission containing materials of a third party:
    Copyright Google LLC; Licensed under Apache 2.0

#### Why I did it

Adds P4RT container to SONiC for PINS

The P4RT app is covered by this HLD:
https://github.com/pins/SONiC/blob/master/doc/pins/p4rt_app_hld.md

#### How I did it

Followed the pattern and templates used for other SONiC applications

#### How to verify it

Build SONiC with INCLUDE_P4RT set to "y".
Verify that the resulting build has a container called "p4rt" running.
You can verify that the service is up by running the following command on the SONiC switch:
```bash
sudo netstat -lpnt | grep p4rt
```
You should see the service listening on TCP port 9559.

#### Which release branch to backport (provide reason below if selected)

None

#### Description for the changelog

Build P4RT container for PINS
2021-12-07 11:11:25 -08:00
Cosmin-Jinga-MS
c5d0df1b51
[Yang] [CBF Maps] SONiC CBF MAPs Yang (#9116)
* SONiC CBF MAPs Yang

    Created SONiC Yang model for the following CBF MAPs:
    DSCP_TO_FC_MAP
    EXP_TO_FC
2021-12-06 11:41:39 -08:00
abdosi
f501311f11
Updated BGP Template for Chassis/Multi-asic (#9291)
Updated BGP Template for the case:
    
   1. For Packet Chassis do not advertise Loopback4096 address into BGP as there is Static Route for same. 
       Having this route in BGP causes two level of recursion in Zebra and cause assert in Zebra 
       when there are many nexthop involved
 
   2. Advertise only P2P Connected IP's into BGP (External Peers). For Packet chassis we have backend IP Interface subnet and if 
        they get advertised into BGP then it also causes recursion
2021-12-06 09:36:24 -08:00
xumia
471a31fce0
[Bug][Build]: fix the file not found issue caused by the relative pat… (#9443)
Fix the nodesource.list cannot read issue, it is cased by the full path not used.

```
2021-12-03T06:59:26.0019306Z Removing intermediate container 77cfe980cd36
2021-12-03T06:59:26.0020872Z  ---> 528fd40e60f6
2021-12-03T06:59:26.0021457Z Step 81/81 : RUN post_run_buildinfo
2021-12-03T06:59:26.0841136Z  ---> Running in d804bd7e1b06
2021-12-03T06:59:29.1626594Z DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support pip 21.0 will remove support for this functionality.
2021-12-03T06:59:34.2960105Z /usr/bin/sed: can't read nodesource.list: No such file or directory
2021-12-03T06:59:34.5094880Z The command '/bin/sh -c post_run_buildinfo' returned a non-zero code: 2
```

Co-authored-by: Ubuntu <xumia@xumia-vm1.jqzc3g5pdlluxln0vevsg3s20h.xx.internal.cloudapp.net>
2021-12-03 21:23:09 -08:00
Prince George
b051a9f56f
[submodule-update] Updating sonic-platform-common submodule (#9412)
c2aac75 [SFP-Refactor] Fix LP mode API issue (#247)
dba17c8 Firmware upgrade CLI support for QSFP-DD transceivers (#244)
cd69212 [SFP-Refactor] Implement CMIS Low Power mode (#237)
9cea07f Fix RegGroupField decode (#245)
6ae1909 Add CMIS QSFP support (#246)
c1f317d Gracefully handle CMIS APIs for passive modules (#238)
ec7335d fix for firmware functions  (#243)
cf2ebe9 Fix RegBitField decode/encode (#242)
ef4f2c6 Fix SFP_CABLE_TECH_FIELD (#240)
e118644 remove time counting message in functions because function running time could be difficult to predict in unit tests (#241)

Signed-off-by: Prince George <prgeor@microsoft.com>
2021-12-02 18:21:55 -08:00
rupesh-k
a3d76bd24e
SONiC Yang model support for Mirror (#7877)
#### Why I did it
Created SONiC Yang model for Mirror.
Tables: MIRROR_SESSION

#### How I did it

Defined Yang models for COPP based on Guideline doc:
https://github.com/Azure/SONiC/blob/master/doc/mgmt/SONiC_YANG_Model_Guidelines.md
and
https://github.com/Azure/sonic-utilities/blob/master/doc/Command-Reference.md

#### How to verify it
'''
============================= test session starts ==============================
platform linux -- Python 3.7.3, pytest-3.10.1, py-1.7.0, pluggy-0.8.0
rootdir: /sonic/src/sonic-yang-models, inifile:
plugins: cov-2.6.0
collected 3 items

tests/test_sonic_yang_models.py ..                                       [ 66%]
tests/yang_model_tests/test_yang_model.py .                              [100%]

=============================== warnings summary ===============================

module: sonic-mirror-session
  +--rw sonic-mirror-session
     +--rw MIRROR_SESSION
        +--rw MIRROR_SESSION_LIST* [name]
           +--rw name         string
           +--rw type?        string
           +--rw src_ip?      inet:ipv4-address
           +--rw dst_ip?      inet:ipv4-address
           +--rw gre_type?    string
           +--rw dscp?        uint8
           +--rw ttl?         uint8
           +--rw queue?       uint8
           +--rw dst_port?    -> /port:sonic-port/PORT/PORT_LIST/name
           +--rw src_port?    union
           +--rw direction?   string

'''
2021-12-02 10:52:01 -08:00
xumia
5947406a45
[Build]: Cleanup the reproducible mirrors when build complete (#9132)
Why I did it
The reproducible build mirrors are only used during the build, the mirrors can be removed after that.
2021-12-02 09:04:40 +08:00
Saikrishna Arcot
34328f9f56
[sonic-swss-common]: Submodule update (#9395)
Bring in the following commit:

405f1df Use build profiles instead of distro version for Python 2 binding build (#558)

This change requires a corresponding change in this repo to set a build
profile to not build the python 2 bindings on Bullseye.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-12-01 10:14:13 -08:00
kellyyeh
f2ee94d201
[dhcp_relay] Update DHCPv6 counter on relayed messages (#9283) 2021-11-30 20:15:30 -08:00
liuh-80
739c45645c
[TACACS+] Add audisp-tacplus for per-command accounting. (#8750)
This pull request integrate audisp-tacplus to SONiC for per-command accounting.

#### Why I did it
To support TACACS per-command accounting, we integrate audisp-tacplus project to sonic.

#### How I did it
1. Add auditd service to SONiC
2. Port and patch audisp-tacplus to SONiC

#### How to verify it
UT with CUnit to cover all new code in usersecret-filter.c
Also pass all current UT.

#### Which release branch to backport (provide reason below if selected)
N/A

#### Description for the changelog
Add audisp-tacplus for per-command accounting.

#### A picture of a cute animal (not mandatory but encouraged)
2021-12-01 11:50:09 +08:00
Junchao-Mellanox
06a61dede0
[YANG] Add trap flow counter to yang model (#9353)
*[YANG] Add trap flow counter to yang model
2021-11-30 17:52:34 -08:00
vganesan-nokia
78de10713c
[voq-chassis][bgpcfg] VOQ_BGP_CHASSIS_NEIGHBORS timers default (#8455)
The BGP_VOQ_CHASSIS_NEIGHBOR keepalive and holdtime timers are
configured similar to general neighbors. Changes are done to configure
BGP_VOQ_CHASSIS_NEIGHBOR timers similar to BGP_INTENAL_NEIGBOR since voq
chassis bgp neighbors are similar to bgp internal neighbors in
multi-asic. As it is done for bgp internal neighbors, the keepalive and
holdtime timers are set to 3 and 10 seconds respectively. Also similar
to bgp internal neighbors, connection retry timer is also configured for
voq chassis bgp neighbors.

Signed-off-by: vedganes <vedavinayagam.ganesan@nokia.com>
2021-11-30 12:10:27 -08:00
Mahesh Maddikayala
bfef686d64
[sonic-py-common][device info] Check for None before accessing the ASIC type (#9290) 2021-11-30 11:12:48 -08:00
noaOrMlnx
0908f9ec49
[CoPP] Add always_enabled field (#9302)
*Add the "always_enabled" field to copp_cfg.j2 file, in order to allow traps without an entry in features table, to be installed automatically.
2021-11-30 11:04:15 -08:00
Shi Su
4b357044b3
[bgpcfgd] Add bgpcfgd support to advertise routes (#9197)
Why I did it
Add bgpcfgd support to advertise routes.

How I did it
Make bgpcfgd subscribe to the ADVERTISE_NETWORK table in STATE_DB and configure route advertisement accordingly.

How to verify it
Added unit tests in bgpcfgd and verify on KVM about route advertisement.
2021-11-29 23:17:57 -08:00
Preetham
858f430f94
Routed subinterface enhancements (#8761)
* Routed subinterfae enhancements HLD #833
* Adding python API support to get routed subinterface long name to get correct parent interface for the routed subinterface.
2021-11-29 09:13:16 -08:00
Stephen Sun
ba853348d5
[Reclaim buffer] Reclaim unused buffers by applying zero buffer profiles (#8768)
Signed-off-by: Stephen Sun stephens@nvidia.com

Why I did it
Support zero buffer profiles

Add buffer profiles and pool definition for zero buffer profiles
Support applying zero profiles on INACTIVE PORTS
Enable dynamic buffer manager to load zero pools and profiles from a JSON file
Dependency: It depends on Azure/sonic-swss#1910 and submodule advancing PR once the former merged.

How I did it
Add buffer profiles and pool definition for zero buffer profiles

If the buffer model is static:
Apply normal buffer profiles to admin-up ports
Apply zero buffer profiles to admin-down ports
If the buffer model is dynamic:
Apply normal buffer profiles to all ports
buffer manager will take care when a port is shut down
Update buffers_config.j2 to support INACTIVE PORTS by extending the existing macros to generate the various buffer objects, including PGs, queues, ingress/egress profile lists

Originally, all the macros to generate the above buffer objects took active ports only as an argument
Now that buffer items need to be generated on inactive ports as well, an extra argument representing the inactive ports need to be added
To be backward compatible, a new series of macros are introduced to take both active and inactive ports as arguments
The original version (with active ports only) will be checked first. If it is not defined, then the extended version will be called
Only vendors who support zero profiles need to change their buffer templates
Enable buffer manager to load zero pools and profiles from a JSON file:

The JSON file is provided on a per-platform basis
It is copied from platform/<vendor> folder to /usr/share/sonic/temlates folder in compiling time and rendered when the swss container is being created.
To make code clean and reduce redundant code, extract common macros from buffer_defaults_t{0,1}.j2 of all SKUs to two common files:

One in Mellanox-SN2700-D48C8 for single ingress pool mode
The other in ACS-MSN2700 for double ingress pool mode
Those files of all other SKUs will be symbol link to the above files

Update sonic-cfggen test accordingly:

Adjust example output file of JSON template for unit test
Add unit test in for Mellanox's new buffer templates.

How to verify it
Regression test.
Unit test in sonic-cfggen
Run regression test and manually test.
2021-11-29 08:04:01 -08:00
vdahiya12
7077474b54
[sonic-platform-daemons] submodule update (#9361)
[xcvrd] Fix Typo for initialization of post_sfp and deinit for xcvrd (#224)

Signed-off-by: vaibhav-dahiya <vdahiya@microsoft.com>
2021-11-26 06:33:18 +05:30
Ze Gan
ada0e50218
[iproute2]: Add macsec-xpn-support iproute2 in syncd (#8702)
* Add macsec-xpn-support iproute2 in syncd

Signed-off-by: Ze Gan <ganze718@gmail.com>

* Polish code

Signed-off-by: Ze Gan <ganze718@gmail.com>

* Remove useless files

Signed-off-by: Ze Gan <ganze718@gmail.com>

* Add self-compiled iproute2 to docker sonic vs

Signed-off-by: Ze Gan <ganze718@gmail.com>

* Enhance apt install for iproute2 dependencies

Signed-off-by: Ze Gan <ganze718@gmail.com>
2021-11-25 21:38:17 +08:00
Jing Zhang
879c18417a
[sonic-linkmgrd] submodule update (#9338)
Submodule update for sonic-linkmgrd
Incorporates:

c11a576 (2021-11-22 09:38:46) [ci]: show code coverage in azure pipeline (#4)
4ceb01d (2021-11-18 20:24:20) Fix MUX toggling issue (#1)
d640527 (2021-11-12 22:31:44) [ci]: fix artifact download
b9f247d (2021-11-12 22:31:44) [ci]: use native arm64/armhf build
3059122 (2021-09-27 11:32:23) [linkgrd] Add Missing Apache License Header
2021-11-24 23:55:17 -08:00
ganglyu
adf1990dd2
[yang]: Add admin_status to BGP_NEIGHBOR_TEMPLATE_LIST. (#9341)
Add admin_status to BGP_NEIGHBOR_TEMPLATE_LIST.

Signed-off-by: Gang Lv ganglv@microsoft.com
2021-11-24 23:54:19 -08:00
arlakshm
5830852832
remove staticd.conf.j2 (#9182)
Why I did it
resolves #8979 and #9055

How I did it
Remove the file static.conf.j2,which adds the default route on eth0 from bgp docker

Signed-off-by: Arvindsrinivasan Lakshmi Narasimhan <arlakshm@microsoft.com>
2021-11-24 15:32:16 -08:00
Junchao-Mellanox
a5336e123a
[submodule] Update submodule for sonic-sairedis (#9354)
sai-redis submodule update:

69517ba [lgtm] Add gmock libs to lgtm (#973)
a7c8cfa [FlexCounter] Add trap flow counter support (#954)
3304daa [vslib]: Add MACsec xpn support (#924)
a3143da Add ACL_TABLE object to break-before-make list (#970)
05a06a4 Update SAI with saiserver fix (#966)
e4180e0 [VS test] Increase test timeout (#967)
70e6491 Fix hung issue when installing linux kernel modules (#969)
2021-11-24 15:17:47 -08:00
Vivek Reddy
80dfbc85c8
update sonic-utilities submodule (#9360)
a0bff26a [acl-loader] modify acl-loader with change in STATE DB ACL capability table (#1896)
a395e284 [debug dump util] Changes for EVPN and VxLAN dump module (#1892)
02a98ef1 [debug dump util] Route Module added (#1913)
ac8382fd [generic-config-updater] Logging change just before applying it (#1934)
9ab6c515 [flex counter] Flex counter threads consume too much CPU resources. #9202 (#1925)
2ec47a59 [generic-config-updater] Handling empty tables while sorting a patch (#1923)
fdedcbf6 [fdbshow]: Handle FDB cleanup gracefully. (#1926)
e7535ae3 [sonic-cli-gen] first phase implementation of the SONiC CLI Auto-generation tool (#1644)

Signed-off-by: Vivek Reddy Karri <vkarri@nvidia.com>
2021-11-24 11:11:31 -08:00
abdosi
950ec3e68b
Added option to enable/disable Static Route Advertisement (#9298)
What I did:

Added option 'advertise':'true'/'false' to STATIC_TALE to control whether given route need to be advertise into BGP.

How I did:

Add a route in FRR with tag (1 for advertise and 2 for not advertise)
Create Route Map to match on tag as 1 and permit
Attach route-map to redistribute static.
Minigraph option to parse advertise option of Static Route.
2021-11-24 09:43:37 -08:00
Stephen Sun
9c4b787d91
[sonic-swss] Advance submodule (#9288)
bb0733aa [aclorch] Add ACL_TABLE_TYPE configuration  (#1982)
59cab5d9 Support for setting switch level DSCP to TC QoS map (#2023)
da21172e [aclorch] add generic AclOrch::updateAclRule() method (#1993)
4f6cb055 [Reclaiming buffer] Support reclaiming buffer in traditional model (#2011)
32d7a69e [Reclaiming buffer] Common code update (#1996)
b91d8ba7 [swss] L2 Forwarding Enhancements (#1716)
797dab41 [muxorch] Bind all ports to drop ACL table (#2027)
99929cd7 [lgtm.yml] add libgmock-dev (#2035)
8727ae5c [flex counter] Flex counter threads consume too much CPU resources #9202 (#2031)
103fdf05 Remove redundant calls to get child scheduler group during initialization (#1965)
18ea8404 [macsec]: MACsec statistics support (#1867)
0c462420 [orchagent] Flush pipeline every 1 second, not only when select will timeout (#2003)
339101cf [cbf] Add class-based forwarding support (#1963)
24a615bd Fix issue: accumulative headroom can exceed limit in rare scenario (#2020)
708e232a Test divide by zero processing path (#2028)
8f1d035c [macsecmgr]: Wait for port up before enabling macsec (#2032)
4912a770 Remove buffer drop counter when port is removed (#1860)
f9462c49 [Dynamic buffer] [Mellanox] Calculate the peer response time according to the speed (#1930)
8b5a401e Routed subinterface enhancements (#2017)
cdea5e9b Fix next hop compilation (#2025)
37c197d0 [SRV6] Sonic-swss changes for SRV6 (#1964)
f502c320 [vnetorch] Add ECMP support for vnet tunnel routes (#1960)

Signed-off-by: Stephen Sun <stephens@nvidia.com>
2021-11-24 11:00:42 +02:00
Junchao-Mellanox
11a93d2f92
[system-health] No longer check critical process/service status via monit (#9068)
HLD updated here: https://github.com/Azure/SONiC/pull/887

#### Why I did it

Command `monit summary -B` can no longer display the status for each critical process, system-health should not depend on it and need find a way to monitor the status of critical processes. The PR is to address that. monit is still used by system-health to do file system check as well as customize check.

#### How I did it

1.	Get container names from FEATURE table
2.	For each container, collect critical process names from file critical_processes
3.	Use “docker exec -it <container_name> bash -c ‘supervisorctl status’” to get processes status inside container, parse the output and check if any critical processes exit

#### How to verify it

1. Add unit test case to cover it
2. Adjust sonic-mgmt cases to cover it
3. Manual test
2021-11-23 15:47:48 -08:00
Prince George
2bf2e870fd
[submodule-update]: Update sonic-platform-common (#9352)
Signed-off-by: Prince George <prgeor@microsoft.com>
2021-11-23 20:46:02 +05:30
donNewtonAlpha
d063c7dec9
[sonic-swss-common] submodule update (#9322)
[sonic-swss-common] submodule update:
95aec72 2021-11-19 [PINS] Add Bazel support for external projects (#557)
1dfe06f 2021-11-18 P4Runtime : Status Code additions (#545)
8c93532 2021-11-18 Ported Marvell armhf build on amd64 host for debian buster to use cross-comp… (#501)
74264d9 2021-11-17 [PINS] Add AppDB ACL schema values shared between the P4RT app and P4Orch (#556)
a18618f 2021-11-15 [schema] Add vnet route tunnel and advertise network tables for state db (#560)
155770e 2021-11-12 [VS test] Increase test timeout (#559)
2b11dea 2021-11-08 [PINS] Update Redis schema to match P4Orch (#548)
be7d483 2021-11-08 [schema] add ACL_TABLE_TYPE table (#546)

Signed-off-by: Don Newton <don@opennetworking.org>
2021-11-23 07:11:49 -08:00
Mayank Maheshwari
5f235a9638
[yang_models]: Update extension yang and types yang with new yang ext… (#6861)
* [yang_models]: Update extension yang and types yang with new yang extensions and types respectively.
* [YANG] Added CVL specific type and moved sonic-types to j2 template.
2021-11-22 19:45:13 -08:00
Stepan Blyshchak
368b038b75
[sonic-acl] add ACL_TABLE_TYPE table (#9052)
* [sonic-acl] add ACL_TABLE_TYPE table

I implemented ACL table type concept. Till this change, there are predefined ACL table types orchagent knows about (L3, L3V6, etc.) and if other orch requires a custom table a new table type needs to be defined in aclorch.
This PR addresses this limitation by introducing AclTableType which can be constructed from a set of matches, actions and bpoint types user needs. There is also a new handler for ACL_TABLE_TYPE table which is used for user to define table types.
Currently, some of built-in ACL table types that requires special handling are distinguished from others by their names (TABLE_TYPE_MIRROR, TABLE_TYPE_MIRRORV6) and a special handling is performed by an AclOrch.
Signed-off-by: Stepan Blyshchak <stepanb@nvidia.com>
2021-11-23 10:33:42 +08:00
xumia
848a1710b0
[Build]: Fix the version not found issue (#9331)
When we update the a sai package downing from a remote server, we need to update the version file as well currently, but the reproducible build feature is not enabled in master, it can only be detected when merging the code into the release branches, such as 202106, 202012, etc.
The reproducible feature is to reduce the build failure, not need to break the build when the version not specified. If version not specified, the best choice is to accept the version from remote server.

Co-authored-by: Ubuntu <xumia@xumia-vm1.jqzc3g5pdlluxln0vevsg3s20h.xx.internal.cloudapp.net>
2021-11-22 12:18:32 -08:00
Vivek Reddy
01b239a761
[sonic-utilities] update sonic-utilities submodule (#9268)
a3e34e30 [Auto Techsupport] Event driven Techsupport Changes (#1796)
efa2ff62 [show][platform summary] Add chassis type in the platform summary output(#1922)
a39350c6 [aclshow] enhance ACL counters to work with FC infrastructure (#1858)
ed880131 [sonic-package-manager] fix registry requests failing when no service field in Bearer fields (#1921)
00b60455 [VS test] Increase test timeout (#1924)
2021-11-22 10:40:54 -08:00
Alexander Allen
d39d1a31ba
[yang] fix yang model tests to run on installed models (#9316)
Previously the Yang model unit tests pulled directly from the Yang model source code for their models. This worked up to a point where we had jinja templates which needed to be rendered before they could be tested on. Now we need to reference the install location of the rendered templates for the unit tests.

Additionally, PBH yang was never added to the list of models to install onto a switch so I have resolved that (another example why pulling directly from the source was not correct)

My best explanation for why we only saw this failing on mellanox was that these tests could not have possibly been running on the broadcom build (I have not investigated this specifically). There was no way for these tests to pass recently given they were referencing Yang models which did not exist in the source (ACL).
2021-11-19 21:16:14 -08:00
Qi Luo
06bf76b5bc
[minigraph] No longer generate the “members” field on the VLAN table in ConfigDB (#9237)
#### Why I did it
This field is deprecated.
Fixes https://github.com/Azure/sonic-buildimage/issues/8306
Fixes https://github.com/Azure/sonic-buildimage/issues/9121
2021-11-18 18:03:11 -08:00
Guohan Lu
c2595189e4
[config-engine]: add option to print verbose debug info in unit tests (#9303)
add option to print verbose debug info in unit tests

Signed-off-by: Guohan Lu <lguohan@gmail.com>
2021-11-18 09:34:28 -08:00
pettershao-ragilenetworks
0e0772596e
[ragile] support 32c and 4s platform (#8824)
Signed-off-by: pettershao-ragilenetworks pettershao@ragilenetworks.com

What I did it

Add new platform x86_64-ragile_ra-b6510-32c-r0 (Trident 3)
ASIC Vendor: Broadcom
Switch ASIC: Trident 3
Port Config: 32x100G

Add new platform x86_64-ragile_ra-b6920-4s-r0 (Tomahawk 3)
ASIC Vendor: Broadcom
Switch ASIC: Tomahawk 3
Port Config: 128x100G

-How I did it
Provide device and platform related files.

-How to verify it
show platform fan
show platform ssdhealth
show platform psustatus
show platform summary
show platform syseeprom
show platform temperature
show interface status
2021-11-17 23:49:06 -08:00
Mahesh Maddikayala
3025a1f8cb
[sonic-py-common][chassis] Include chassis platform when checking for internal connections (#9264) 2021-11-16 14:13:19 -08:00
Prince George
c302f490ff
[submodule]:Update sonic-platform-common submodule (#9256)
c8eceec 400zr initial support (#228)
ef55364 SSD Health: Retrieve SSD health and temperature values from generic SSD info (#229)
26c8346 Fix cmis cable length issue (#225)
671927d Fix typo in the simulated y_cable driver (#226)
51a9aca [sfp-refactor] Add initial support for CMIS in sonic_xcvr (#220)

Signed-off-by: Prince George <prgeor@microsoft.com>
2021-11-16 09:15:05 -08:00
Shi Su
7f45af9710
[YANG] Add YANG model for synchronous mode (#9194)
Add YANG model leaf for synchronous mode and default value
2021-11-15 21:57:12 -08:00
Vivek Reddy
ff32ac3ed4
[Auto Techsupport] Event driven Techsupport Changes (#8670)
#### Why I did it

Changes required for feature "Event Driven TechSupport Invocation & CoreDump Mgmt". [HLD](https://github.com/Azure/SONiC/pull/818 )

Requires: https://github.com/Azure/sonic-utilities/pull/1796.
Merging in any order would be fine.

Summary of the changes:

- Added the YANG Models for the new tables introduces as a part of this feature.
- Enhanced init_cfg.json with the default config required
- Added a compile Time flag which enables/disables the config required for this feature inside the init_cfg.json
- Enhanced the supervisor-proc-exit-listener script to populate `<feature>:<critical_proc> = <comm>:<pid>` info in the STATE_DB when it observes an proc exit notification for the critical processes running inside the docker.
2021-11-15 21:56:37 -08:00
Mahesh Maddikayala
2680491c03
[sonic_py_common][device info] APIs to return chassis type (voq or packet) (#9227) 2021-11-15 09:19:44 -08:00
Stepan Blyshchak
ca3a034e6f
[sonic-sairedis] update submodule (#9233)
6f1a0ea (HEAD, origin/master, origin/HEAD, master) [FlexCounter] Add support for ACL counters (#953)
67b3136 [vslib] fill aclcapability.is_action_list_mandatory field (#957)
eba6a1b [ci]: use native armhf and arm64 pool (#965)
04793b1 [az] Set diff coverage threshold to 50% (#963)
6092d50 [syncd] Add workaround for warm boot new objects (#960)
88b62ce Added Flex Counters support for tunnel counters (#886)
a718226 [Counters] Query Counters Stats Capabilities (#952)
2021-11-15 08:30:29 -08:00
Stepan Blyshchak
0e057a4bb1
[sonic-swss] update submodule (#9232)
```
5f8ebfa (HEAD, origin/master, origin/HEAD, master) [AclOrch] move ACL counters to flex counter infrastructure (#1943)
8119ec0 [bfdorch] Orchagent support hardware BFD (#1883)
15074ac [sonic-swss]:enable unconfiguring PFC on last TC on a port (#1962)
05c7c05 [Mux orch] set default as standby, change mux orch priority (#2010)
fe5b2a9 [pytest]: Ignore errors deleting host ifs (#2005)
70da9af [ci]: use native arm64 and armhf pool (#2013)
e14a071 [qos] Add EXP to TC map support (#1954)
c91a7f2 [switchorch] Implement VXLAN src port range feature  (#1959)
b20f0f4 Gcov for swss daemon (#1737)
01c243a [CRM][MPLS] Fix the mpls nexthop CRM attribute (#2008)
```

Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
2021-11-15 07:56:35 -08:00
Guohan Lu
db0b789b73
[submodule]: update sonic-linux-kernel (#9254)
* 6aa8d00 2021-11-12 | marvell-armhf]: add kconfig force inclusion for CONFIG_ARCH_NR_GPIO (#245) (HEAD, origin/master, origin/HEAD) [dflynn-Nokia]
* 39c7d18 2021-11-06 | [arm64]: add kconfig force inclusion for COMPAT_VSDO [Guohan Lu]
* fafaaea 2021-11-06 | [backport] kernel-compat-always-include-linux-compat.h-from-net-compat.patch [Guohan Lu]
* 6ac9b48 2021-10-19 | [ci]: use native arm64/armhf pool to build kernel [Guohan Lu]

Signed-off-by: Guohan Lu <lguohan@gmail.com>
2021-11-14 12:01:39 -08:00
dflynn-Nokia
df12ac5abd
[build]: marvell-armhf bullseye fixes (#9243)
This commit fixes/avoids the following errors encountered during the
marvell-armhf build for bullseye

- Fix Marvell prestera DMA driver build failure due to kallsyms_lookup_name()
  no longer being exported by the updated bullseye kernel. This is a temporary
  fix that will be replaced by a future version of the DMA driver.

- Update qemu-user-static version to align with the new glibc version included
  in bullseye

- Skip systemd-sonic-generator unit tests to avoid test failures. Root cause is
  still TBD

#### Why I did it
Fix the following build errors observed when building marvell-armhf for bullseye
1. Marvell Prestera DMA driver uses kernel API no longer exported
ERROR: modpost: "kallsyms_lookup_name" [/sonic/platform/marvell-armhf/prestera/mrvl-prestera/cpssEnabler/linuxNoKernelModule/drivers//mvDmaDrv.ko] undefined!

2. Old qemu-user-static version does not support semop() leading to following build failure
semop(1): encountered an error: Function not implemented

3. systemd-sonic-generator unit test failure
ssg-test.cc:217: Failure
Expected equality of these values:
  find_string_in_file(str_t, target, num_asics)
    Which is: false
  expected_result
    Which is: true
Error validating Before=single_inst.service in test.service
[  FAILED  ] SsgMainTest.ssg_main_40_npu (20 ms)
[----------] 4 tests from SsgMainTest (36 ms total)

[----------] Global test environment tear-down
[==========] 10 tests from 3 test suites ran. (54 ms total)
[  PASSED  ] 7 tests.
[  FAILED  ] 3 tests, listed below:
[  FAILED  ] SsgMainTest.ssg_main_single_npu
[  FAILED  ] SsgMainTest.ssg_main_10_npu
[  FAILED  ] SsgMainTest.ssg_main_40_npu

 3 FAILED TESTS
2021-11-13 10:48:58 -08:00
Guohan Lu
19f878f591
Revert "[yang] Add missing device types to the device_metadata yang (#9226)" (#9251)
This reverts commit 2dc94b30bb.
2021-11-12 22:08:58 -08:00
liuh-80
ff09b8b8ed
[TACACS+] Add Bash TACACS+ plugin for per-command authorization. (#8715)
This pull request add a bash plugin for TACACS+ per-command authorization

#### Why I did it
1. To support TACACS per command authorization, we check user command before execute it.
2. Fix libtacsupport.so can't parse tacplus_nss.conf correctly issue:
            Support debug=on setting.
            Support put server address and secret in same row.
3. Fix the parse_config_file method not reset server list before parse config file issue.

#### How I did it
The bash plugin will be called before every user command, and check user command with remote TACACS+ server for per-command authorization.

#### How to verify it
UT with CUnit cover all code in this plugin.
Also pass all current UT.

#### Which release branch to backport (provide reason below if selected)
N/A

#### Description for the changelog
Add Bash TACACS+ plugin.


#### A picture of a cute animal (not mandatory but encouraged)
2021-11-13 09:57:30 +08:00
tjchadaga
645173307a
sonic-platform-daemons submodule update (#9223) 2021-11-12 13:23:12 -08:00
Neetha John
2dc94b30bb
[yang] Add missing device types to the device_metadata yang (#9226)
* Add missing device types to the DEVICE_METADATA type field

Signed-off-by: Neetha John <nejo@microsoft.com>
2021-11-11 19:41:24 -08:00
kellyyeh
a86320a773
DHCPv6 Relay multivlan functionality support (#9178)
Fix support for DHCPV6 Relay multi vlan functionality. Make sure the relayed packet is received at correct interface.

How I did it
Bind a socket to each vlan interface's global and link-local address.
Socket binded to global address is used for relaying data from client to server and receiving data from servers.
Socket binded to link-local address is used for relaying data received from server back to the client.
2021-11-11 17:49:04 -08:00
Vivek Reddy
5826a5c4e7
[submodule] Update sonic-utilities submodule (#9229)
4bcaa602 [generic-config-updater] Adding logging to config-{replace, rollback, checkpoint, list-checkpoints} (#1885)
5e95fc34 [debug dump util] Vlan Module Added (#1877)
7f0bbd99 [debug dump util] Portchannel module added (#1853)
50bbfa0f Removed -t option and other missing fixes (#1884)

update sonic-utilties submodule

Signed-off-by: Vivek Reddy Karri <vkarri@nvidia.com>
2021-11-11 09:22:33 -08:00
Renuka Manavalan
bb92e98bb8
TACACS: Don't send sshd's bad password to AAA (#9123)
When sshd realizes that this login can't succeed due to internal device state
or configuration, instead of failing right there, it proceeds to prompt for
password, so as the user does not get any clue on where is the failure point.

Yet to ensure that this login does not proceed, sshd replaces user provided password
with a specific pattern of characters matching length of user provided password.
This pattern is "INCORRECT", which is bound to fail.

If user provided length is smaller/equal, the substring of pattern is overwritten.
If user provided length is greater, the pattern is repeated until length is exhausted.

But if the PAM-tacacs plugin would send this password to AAA, the user could get
locked out by AAA, for providing incorrect value.

How I did it
Hence this fix, matches obtained password against the pattern. If match, fail just before
reaching AAA server.
2021-11-11 07:46:52 -08:00
Stepan Blyshchak
b8eb9f2769
[sonic-yang-models] add ACL flex counter group (#8909)
Why I did it
To add ACL FC to the YANG model.

How I did it
Added to the YANG model and added a UT.

How to verify it
Together with depends PRs. Run ACL/Everflow test suite.

Signed-off-by: Stepan Blyshchak <stepanb@nvidia.com>
2021-11-11 09:09:36 +08:00
Stepan Blyshchak
a2c2d67098
[ACL] enable ACL FC when genereting config from minigraph but disable by default (#8908)
* [ACL] enable ACL FC when genereting config from minigraph but disable by default
Why I did it
To support ACL counters on Flex Counter Infrastructure.

How I did it
Enable ACL FC in init_cfg and minigraph. Disable when genereting configuration from preset.

How to verify it
Together with depends PRs. Run ACL/Everflow test suite.

Signed-off-by: Stepan Blyshchak <stepanb@nvidia.com>
2021-11-11 09:07:54 +08:00
Guohan Lu
5f11eb320e Revert "sysready (#8889)"
This reverts commit d7e5372e54.
2021-11-10 15:36:20 -08:00
Kiran Kumar Kella
b4dda1c18d Ported iptables patch to 5.10 kernel (#4)
Ported Iptables patch for supporting fullcone NAT option to 5.10 kernel.

Signed-off-by: Kiran Kella <kiran.kella@broadcom.com>
2021-11-10 15:27:22 -08:00
Saikrishna Arcot
91f6800500 Upgrade to ntp 4.2.8p15 for Bullseye
Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-11-10 15:27:22 -08:00
Saikrishna Arcot
2b0ad74db6 Update kdump-tools for bullseye
Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-11-10 15:27:22 -08:00
Saikrishna Arcot
06d793e985 sonic-frr: Add patch to skip installing png files
In the build in Bullseye, there are no png files available in the
specified installation source directory. For now, don't bother
installing those files.

This may end up being reverted later if there are indeed png files that
need to be installed for documentation.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-11-10 15:27:22 -08:00
Saikrishna Arcot
c923310b8c Update snmpd to 5.9, as part of the Bullseye upgrade
Debian actually did a binNMU for snmpd, so to match the package version
we're building with the version in the offiical repos, that version
needs to be manually specified in the changelog.

Buster still needs 5.7.3, because there's a ABI change between 5.7.3 and
5.9 for libsnmp, so for Buster, make sure that 5.7.3 is built, and for
Bullseye, make sure that 5.9 is built.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-11-10 15:27:22 -08:00
Saikrishna Arcot
da9f72910a Update monit build for Bullseye
Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-11-10 15:27:22 -08:00
Saikrishna Arcot
a1d30e3aa0 Python 2 removal/cleanup
Remove Python 2 package installation from the base image. For container
builds, reference Python 2 packages only if we're not building for
Bullseye.

For libyang, don't build Python 2 bindings at all, since they don't seem
to be used.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-11-10 15:27:22 -08:00
Saikrishna Arcot
b0b9bb0d68 openssh: Upgrade from 7.9 to 8.4, to match version in Bullseye
Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-11-10 15:27:22 -08:00
Saikrishna Arcot
371f496340 Update initramfs-tools from 0.133 to 0.140
Also update the patch to add support for booting from squashfs to fix a
shellcheck warning.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-11-10 15:27:22 -08:00
Saikrishna Arcot
20598f3019 Update src/sonic-linux-kernel to point to the 5.10 kernel
Some patches have been enabled at this point, others need more rework.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-11-10 15:27:22 -08:00
Senthil Kumar Guruswamy
d7e5372e54
sysready (#8889) 2021-11-10 14:52:52 -08:00
Arun Saravanan Balachandran
8219975d6f
[test] Include chassis fields validation in platform.json unit test (#8820)
Why I did it
Include validation of chassis dict in platform.json unit test
Based on: Azure/SONiC#768

How I did it
Update platform_json_checker to validate fields in chassis dict.

How to verify it
Verified that the unit test reports success for correct values of existing and capabilities fields in platform.json
2021-11-10 12:08:20 -08:00
AmitKaushik7
13bb747398
Adding mmu buffer yang files (#7838)
Why I did it
Added Buffer yang files derived from sonic/mgmt-cvl/testdata/schema from sonic-mgmt-common,  used by mgmt-framework.

Updated BUFFER_PG|({ifname},)*|{pg_num} to BUFFER_PG|{ifname}|{pg_num} in sonic-buffer-pg.yang.
This change is required for configuration migration for dynamic port breakout operation.

Added sonic-buffer-queue.yang for BUFFER_QUEUE

Tables: BUFFER_POOL, BUFFER_PROFILE, BUFFER_PG, BUFFER_QUEUE.

How I did it
Defined Yang models for BUFFER tables based on Guideline doc:
https://github.com/Azure/SONiC/blob/master/doc/mgmt/SONiC_YANG_Model_Guidelines.md
and
https://github.com/Azure/sonic-utilities/blob/master/doc/Command-Reference.md

How to verify it
sonic_yang_models package build.

Description for the changelog
MMU Buffer yang files (BUFFER_POOL/BUFFER_PROFILE/BUFFER_PG/BUFFER_QUEUE)
2021-11-10 10:23:18 -08:00
liuh-80
e2bffdf9e7
[sonic-utilities] submodule update (#9203)
Updating sonic-utilities sub module with the following commits

63a5257 [TACACS+] Add config command for AAA authorization and accounting. (#1889)
8a8577b [dump] [copp] Fixed the NameError Exception for copp dump module (#1911)
84be8b4 Dump media_settings from appDB during fast-reboot (#1910)
563c416 Allow interface type value none (#1902)
095bf54 generic_updater: Fix service validator related issues (#1901)
efbe1f4 [chassis][supervisor][show][interfaces]show interfaces command warning on Supervisor card (#1771)
487b3b7 Add CRM CLIs for SRV6 nexthop and my_sid_entry (#1883)
2021-11-09 12:19:35 -08:00
gechiang
ef457ab13f
Disable ALPM distributed hitbit thread that is used for debug purpose only but interfered with Other functional operations (#9199) 2021-11-09 07:21:57 -08:00
Ze Gan
07038a0223
[submodule]: update for swss-common (#9192)
52b7a47 (HEAD, origin/master, origin/HEAD) [schema]: MACsec statistics support (#520)
48d7d8a [ci]: use native arm64 and armhf pool to build (#552)

Signed-off-by: Ze Gan <ganze718@gmail.com>
2021-11-09 09:49:38 +08:00
trzhang-msft
de3a928c7c
caclmgrd: support packet mark in DHCP chain (#9131)
* caclmgrd: support packet mark in DHCP chain
2021-11-08 14:54:16 -08:00
Raphael Tryster
e8d316de61
[submodule] Update snmpagent (#9102)
Why I did it
Update pointer to this commit in sonic-snmpagent:

a07da53 2021-10-26 Removed unused variables in rfc2863.py (#237)
2021-11-08 09:55:24 -08:00
Guohan Lu
a2d0dbe604
[sonic-yang]: introduce yang template for cvl yang (#8880)
Signed-off-by: Guohan Lu <lguohan@gmail.com>
2021-11-06 11:35:55 -07:00
Junchao-Mellanox
68dfbfaf2a
Allow interface type value none (#9098)
This PR allow user to set none value to interface type. So there is a way to achieve the goal via CLI:

config interface type XXX none
config interface speed XXX 10000
config interface type XXX CR
2021-11-05 19:09:14 -07:00
Sudharsan Dhamal Gopalarathnam
4f00b86502
[swss] Update Submodule (#9174)
Including the below commits to update swss submodule
8448a60 [vs tests]Migrating sonic-swss tests to use hwsku instead of fakeplatform (#1978)
faa26db Fix random failure in PR/CI build. (#2006)
e03edb6 Allow interface type value none (#1991)
71b9650 [orchagent] Fix group name of port-buffer-drop in flexcounterorch.cpp (#1967)
facdef5 [VS test] Skip flaky virtual chassis test (#2004)
8261c1f [pytest]: Increase timeout when checking services (#2000)
67278be [teammgrd]: Handle LAGs cleanup gracefully on Warm/Fast reboot. (#1934)
e92c1df Enable FEC statistics collection for Ethernet ports (#1994)
9f30ca1 VxLAN Tunnel Counters and Rates implementation (#1859)

Signed-off-by: Sudharsan Dhamal Gopalarathnam <sudharsand@nvidia.com>
2021-11-05 11:39:45 -07:00
Prince Sunny
02902078ee
[Submodule] update for swss-common (#9180)
d23cf88 - 2021-10-28 : [schema] Add ACL_COUNTER_ATTR_ID_LIST (#533) [Stepan Blyshchak]
53b84c7 - 2021-10-26 : Add default route table name to State DB (#543) [Prince Sunny]
2021-11-05 08:24:35 -07:00
liuh-80
a61ffcd92c
[TACACS+] Add Config DB schema and HostCfg Enforcer plugin to support TACACS+ per-command authorization&accounting. (#9029)
[TACACS+] Add Config DB schema and HostCfg Enforcer plugin to support TACACS+ per-command authorization&accounting. (#9029)

#### Why I did it
    Support TACACS per-command authorization&accounting.

#### How I did it
    Change ConfigDB schema and HostCfg enforcer.
    Add UT to cover changed code.

#### How to verify it
    Build following project and pass all UTs:
    make target/python-wheels/sonic_host_services-1.0-py3-none-any.whl

#### Which release branch to backport (provide reason below if selected)
    N/A

#### Description for the changelog
    Add Config DB schema and HostCfg Enforcer plugin to support TACACS+ per-command authorization&accounting.

#### A picture of a cute animal (not mandatory but encouraged)
2021-11-05 12:39:48 +08:00
Akhilesh Samineni
2c801ef442
[yang]: SONiC Yang model for DHCP-Relay parameters (#8946)
SONiC Yang model for DHCP-Relay parameters

What I did
Added DHCPv6 Servers.
Tables: VLAN, DHCP_RELAY.

How I did it
Defined Yang model for Relay based on Guideline doc:
https://github.com/Azure/SONiC/blob/master/doc/mgmt/SONiC_YANG_Model_Guidelines.md

How to verify it
Added test cases to verify it.

Signed-off-by: Akhilesh Samineni akhilesh.samineni@broadcom.com
2021-11-04 10:44:04 -07:00
anamehra
fed19e3fb5
Added get_system_mac support for cisco-8000 device (#9104)
Added get_system_mac support for cisco-8000 device

Why I did it
This is required to assign unique MACs to namespaces on Backend and Frontend asics
for cisco-8000 platforms

How I did it
Add vendor specific hook in get_system_mac. The MAC address are read from /profile.ini
file

How to verify it
config load_minigraph on a multi-asic system
config save
check mac addresses in DEVICE_METADATA section in each config_db json file
2021-11-04 08:27:55 -07:00
kellyyeh
1067bc8fd3
Fix invalid destination address error (#9143) 2021-11-02 12:36:32 -07:00
Vivek Reddy
05b6207849
[hostcfgd] Missing comment added (#9113)
Missing comment change which is supposed to arrive with #8861 is added here

Signed-off-by: Vivek Reddy Karri <vkarri@nvidia.com>
2021-11-02 07:39:05 -07:00
Stepan Blyshchak
9a143aeb4b
[sonic-utilities] update submodule (#9137)
```
ca728b8 [config] fix interface IPv6 address removal. (#1819)
0665d6f VxLAN Tunnel Counters and Rates implementation (#1748)
80a10dc Fix log_ssd_health hang issue (#1904)
ea4a730 [config][cbf] Added config commands for CBF (#1799)
02ce8d6 [sonic-package-manager] update FEATURE entries on upgrade (#1803)
9f123c0 [generate_dump] remove secrets from dump files (#1886)
3a8ab73 [fwutil] Add `fwutil update all` to support the automatic platform component fw updates (#1242)
776fddf [sonic-package-manager] code style fixes and enhancements (#1802)
f53baac [watermarkstat] Fix for error in processing empty array from couters db (#1810)
0b2536b Generic_upater: Apply JSON change (#1856)
```

Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
2021-11-02 08:56:08 +02:00
Praveen Chaudhary
021b7dcb04
[sonic-breakout_cfg.yang]: Remove pattern from sonic-breakout_cfg.yang. (#6801)
Changes:
-- Remove pattern from sonic-breakout_cfg.yang, it is redundant.
-- test changes.

Signed-off-by: Praveen Chaudhary <pchaudhary@linkedin.com>
2021-11-01 08:26:27 -07:00
Sudharsan Dhamal Gopalarathnam
9661f10d0c
[swss] Update sub module (#9124)
The submodule update includes the following commits
ac3103a Add missing neighbor resolution for MPLS route programming (#1968)
bfba0ad [vlanmgr]Fix for STATE_DB port check logic (#1980)
9ef2ba4 Update VLAN removal code to work with 5.10 kernel and new
41fb26c Handle setting unknown mux state (#1984)
ac09bde Increase timeout for VS tests (#1988)
da8a43e Check if appl DB exists before deleting (#1983)
553d75a Change tunnel orch order (#1977)
7444e96 Add rekey period in macsec mgr (#1958)
d95823d [Buffermgr]Graceful handling of buffer model change (#1956)
b0aa6a0 EVPN VxLAN enhancement to support P2MP tunnel based programming for L
85bdf54 Fix the option missing in kernel config issue (#1973)
6b15584 Orchagent validates mirror session queue parameter against maximum va
fc9ffb9 [copp] Add ISIS, LDP and micro-BFD trap types to CoPP manager (#1890)
452cbc1 [macsecorch]: Add IPG adjusting for MACsec gearbox model (#1925)

Signed-off-by: Sudharsan Dhamal Gopalarathnam <sudharsand@nvidia.com>
2021-11-01 08:23:11 -07:00
abdosi
919b3e5cdf
[chassis-packet] Fixed BGP Internal Peer template (#9106)
What I did:

Fix the typo in Internal Peer Group template for Packet-based Chassis.
Address Review comments of PR: [chassis-packet] minigraph parsing and BGP template changes #8966
- Static Route Parsing for Host
- Formatting of chassis port_config.ini
2021-10-29 11:02:38 -07:00
Qi Luo
1c07d39cda
[sonic-snmpagent] Update submodule (#9076)
#### Why I did it
Includes below commits
```
c2d4945 2021-09-17 | [snmp] Allow system with no ports in config db run without errors (#221) [Lior Avramov]
fccb21b 2021-08-30 | [RFC1213]: Initialize lag oid map in reinit_data instead of (#232) [SuvarnaMeenakshi]
```
2021-10-29 07:15:00 -07:00
thomas.cappleman@metaswitch.com
aab689e961
[swss-common] Update swss-common submodule (#9073)
[schema] Add EXP to TC map config table (#537)
[CI]: Swap the python code coverage report with the cpp report (#544)
Remove SWIG generated files from coverage report (#542)
Update database defintions for PINs / P4Runtime (#536)
[ci]: Support code coverage (#539)
Fix the option missing in kernel config issue (#541)
Add SRV6 APP tables (#538)
[schema] Rename CBF config tables (#535)
2021-10-28 09:39:34 -07:00
Vivek Reddy
37882942c9
[hostcfgd] Fixed the brief blackout in hostcfgd using SubscriberStateTable (#8861)
#### Why I did it

Fixes https://github.com/Azure/sonic-buildimage/issues/8619

#### How I did it

1) Listening to CFG_DB notifications was migrated from ConfigDBConnector to SubscriberStateTable & Select
2) This change in design helped me to remove `update_all_features_config` which was roughly taking a 5-10 sec time to execute and thus the reason for blackout
3) Edited FeatureHandler, Feature & NtpCfgd classes to suit this design  
4) Added corresponding mocks and UT's

**Changes made to classes other than HostConfigDaemon:**
With the previous design, the initially read data from the config db was applied by using hardcoded methods even before the config_db.listen() was called. For Eg: `update_all_features_config` for FeatureHandler and load() named methods for NtpCfgd etc

But with this design, since the existing data is read and given out as a notification by SubscriberStateTable, i've pretty much removed these hardcoded methods. Thus changes made to these class will be around adapting them to the new design and no change in the actual functionality .


#### How to verify it

UT's:
```
tests/determine-reboot-cause_test.py .........                                                                                                                                                                                        [ 29%]
tests/procdockerstatsd_test.py .                                                                                                                                                                                                      [ 32%]
tests/caclmgrd/caclmgrd_dhcp_test.py ......                                                                                                                                                                                           [ 51%]
tests/hostcfgd/hostcfgd_radius_test.py ..                                                                                                                                                                                             [ 58%]
tests/hostcfgd/hostcfgd_test.py .............                                                                                                                                                                                         [100%]
```
Verified manually, 

```
Sep 10 22:53:25.662621 sonic INFO systemd[1]: hostcfgd.service: Succeeded.
Sep 10 22:55:04.127719 sonic INFO /hostcfgd: ConfigDB connect success
Sep 10 22:55:04.128108 sonic INFO /hostcfgd: KdumpCfg init ...
Sep 10 22:55:04.148819 sonic INFO /hostcfgd: Waiting for systemctl to finish initialization
Sep 10 22:55:04.163452 sonic INFO /hostcfgd: systemctl has finished initialization -- proceeding ...
Sep 10 22:55:04.163834 sonic INFO /hostcfgd: Kdump handler...
Sep 10 22:55:04.164019 sonic INFO /hostcfgd: Kdump global configuration update
Sep 10 22:55:04.758784 sonic INFO hostcfgd[184471]: kdump is already disabled
Sep 10 22:55:04.758876 sonic INFO hostcfgd[184471]: Kdump is already disabled
Sep 10 22:55:05.182021 sonic INFO hostcfgd[184511]: Kdump configuration has been updated in the startup configuration
Sep 10 22:55:05.596919 sonic INFO hostcfgd[184528]: Kdump configuration has been updated in the startup configuration
Sep 10 22:55:06.140627 sonic INFO /hostcfgd: Feature nat is stopped and disabled
Sep 10 22:55:06.642629 sonic INFO /hostcfgd: Feature telemetry is enabled and started
Sep 10 22:55:07.101297 sonic INFO /hostcfgd: Feature pmon is enabled and started
Sep 10 22:55:07.554366 sonic INFO /hostcfgd: Feature database is enabled and started
Sep 10 22:55:08.009329 sonic INFO /hostcfgd: Feature mgmt-framework is enabled and started
Sep 10 22:55:08.394952 sonic INFO /hostcfgd: Feature macsec is stopped and disabled
Sep 10 22:55:08.782853 sonic INFO /hostcfgd: Feature snmp is enabled and started
Sep 10 22:55:09.205381 sonic INFO /hostcfgd: Feature teamd is enabled and started
Sep 10 22:55:09.224877 sonic INFO /hostcfgd: Feature what-just-happened is enabled and started
Sep 10 22:55:09.627929 sonic INFO /hostcfgd: Feature lldp is enabled and started
Sep 10 22:55:10.086993 sonic INFO /hostcfgd: Feature swss is enabled and started
Sep 10 22:55:10.170312 sonic INFO /hostcfgd: cmd - service aaastatsd stop
Sep 10 22:55:11.012236 sonic INFO /hostcfgd: cmd - service aaastatsd stop
Sep 10 22:55:12.225946 sonic INFO /hostcfgd: Feature bgp is enabled and started
Sep 10 22:55:12.712792 sonic INFO /hostcfgd: Feature dhcp_relay is enabled and started
Sep 10 22:55:13.166656 sonic INFO /hostcfgd: Feature sflow is stopped and disabled
Sep 10 22:55:13.593639 sonic INFO /hostcfgd: Feature radv is enabled and started
Sep 10 22:55:14.034106 sonic INFO /hostcfgd: Feature syncd is enabled and started
Sep 10 22:55:14.113064 sonic INFO /hostcfgd: cmd - service aaastatsd stop
Sep 10 22:55:14.863601 sonic INFO /hostcfgd: RADIUS_SERVER update: key: 10.10.10.1, op: SET, data: {'auth_type': 'pap', 'passkey': 'p*****', 'retransmit': '1', 'timeout': '1'}
Sep 10 22:55:14.938605 sonic INFO /hostcfgd: cmd - service aaastatsd stop
Sep 10 22:55:15.667545 sonic INFO /hostcfgd: RADIUS_SERVER update: key: 10.10.10.3, op: SET, data: {'auth_type': 'chap', 'passkey': 'p*****', 'retransmit': '2', 'timeout': '2'}
Sep 10 22:55:15.667801 sonic INFO /hostcfgd: RADIUS (NAS) IP change - key:eth0, current global info {}
Sep 10 22:55:15.746531 sonic INFO /hostcfgd: cmd - service aaastatsd stop
Sep 10 23:04:47.435340 sonic INFO /hostcfgd: ntp server update key 0.debian.pool.ntp.org
Sep 10 23:04:47.435661 sonic INFO /hostcfgd: ntp server update, restarting ntp-config, ntp servers configured {'0.debian.pool.ntp.org'}
Sep 10 23:04:47.866394 sonic INFO /hostcfgd: NTP GLOBAL Update
Sep 10 23:04:47.866557 sonic INFO /hostcfgd: ntp global update for source intf old {''} new {'eth0', 'Loopback0'}, restarting ntp-config
Sep 10 23:16:25.157600 sonic INFO /hostcfgd: Running cmd: 'sudo systemctl unmask sflow.service'
Sep 10 23:16:25.178472 sonic INFO hostcfgd[192106]: Removed /etc/systemd/system/sflow.service.
Sep 10 23:16:25.582018 sonic INFO /hostcfgd: Running cmd: 'sudo systemctl enable sflow.service'
Sep 10 23:16:25.604534 sonic INFO hostcfgd[192123]: Created symlink /etc/systemd/system/sonic.target.wants/sflow.service → /lib/systemd/system/sflow.service.
Sep 10 23:16:26.029416 sonic INFO /hostcfgd: Running cmd: 'sudo systemctl start sflow.service'
Sep 10 23:16:26.691927 sonic INFO /hostcfgd: Feature sflow is enabled and started
```
2021-10-28 07:18:07 -07:00
Neetha John
d35b50b116
[minigraph] Add tagged vlan member support for storage backend (#9045)
Signed-off-by: Neetha John <nejo@microsoft.com>

Why I did it
Storage T0's have all vlan members as tagged

How I did it
Since currently minigraph does not have a unique way to identify if a vlan member is tagged/untagged and to ensure other scenarios are not broken, the logic used is to just update the vlan member type as 'tagged' when we determine that it is a storage backend device. This change will apply only to storage backend T0's since storage backend T1's will not have vlan member information

How to verify it
Updated the storage backend T0 testcases to check for tagged vlan members
Added testcase to check if a T1 and backend T1 device generates an empty vlan member table
Existing vlan member testcases are good enough for checking if any regression has been caused for regular T0's
Build sonic_config_engine-1.0-py3-none-any.whl successfully
2021-10-27 09:27:18 -07:00
Qi Luo
4bda0a921f
[build] Use pip to install setup.py dependency instead of python setup.py install (#8997)
#### Why I did it
Fix a recent build error introduced by a pre-release redis-py. This is a general issue because `python setup.py install` (ie `easy_instal`) does not ignore pre-release versions. The fix is suggested by https://github.com/pypa/setuptools/issues/855#issuecomment-583803959
2021-10-26 21:12:45 -07:00
jingwenxie
b0c73d9a73
[submodule] Update submodule for sonic-utilities (#9051)
8ea834b [sonic_installer] Change sonic_installer check ASIC mismatch by platforms list (#1836)
9017d99 Fix the option missing in kernel config issue (#1888)
6595ad4 [mlag] fix log print sequence (#1730)
e600e1c CLI command to load config in Yang format (#1781)
00948d0 Fix the target db version of portchannel-key test (#1842)
6412fea [sonic-package-manager] remove make_python_identifier (#1801)
f738818 [sonic-package-manager] stop service explicitelly before uninstalling package (#1805)
d8ee5e9 Remove exec from platform_reboot_plugin call to handle any hang issue. (#1879)
827fcee [chassis][routecheck]filter out the chassis internal interfaces (#1798)
4d732c6 [generic_config_updater] Logging (#1864)
25bb184 [config]: Add loopback interfaces to interface name checker (#1869)
c950a55 Validate input of config mirror_session add (#1825)
9ab20fd [show][config] fix the muxcable commands for interface naming mode (#1862)
476b3a4 [multi-asic][cli][chassis-db] Avoid connecting to chassis db for cli commands executed from linecard (#1707)
2021-10-26 15:09:24 +08:00
Ze Gan
d051bc4eb7
Update wpa supplicant (#8998)
Signed-off-by: Ze Gan <ganze718@gmail.com>

986a835153b3df3a37492fbd3a83fc8e38a40c10 Proactively rekey https://github.com/Azure/sonic-wpa-supplicant/pull/36
b84dd21ac7b76686caf53f2e9a2c8eb80519ab31 Fix azurepieline download sonic swss common deb pakcage https://github.com/Azure/sonic-wpa-supplicant/pull/37
66002de9d5e3165ccdbed40451db86ae0a8b3944 [macsec_sonic] driver support for macsec_include_sci https://github.com/Azure/sonic-wpa-supplicant/pull/35
dae8f59cb54c90bc9011bd675806a75dd0808d27 MACsec XPN changes https://github.com/Azure/sonic-wpa-supplicant/pull/34
c2271b2879ed157718edb51e842a3e33debeab7f Move SSCI from SC to SA and change packet number field name to adapt sai 1.7.1 https://github.com/Azure/sonic-wpa-supplicant/pull/26
1bbc8f1ef463dd21428ce80b72da107f3bd2f3f0 Fix for CP state machine issues https://github.com/Azure/sonic-wpa-supplicant/pull/33
2021-10-25 10:14:29 +08:00
vdahiya12
bb9c36c2a3
[sonic-platform-common] submodule update (#9022)
8bb9c5a (HEAD -> master, origin/master, origin/HEAD) Add retry reading/setting mux status to simulated y-cable driver (#221)
2ebd786 [sfp-refactor] Add initial support for SFF-8636 in sonic_xcvr (#218)
221fb8a Fix QSFP-DD power class mask (#212)
4598d40 [Y-Cable][Broadcom] upgrade to support Broadcom Y-Cable API to release 1.2 (#217)
0fdd198 [sfp-refactor] Add initial support for SFF-8436 in sonic_xcvr (#215)
a09f5a3 [sfp-refactor] Add new sonic_xcvr package for common transceiver logic (#201)
7ca4f51 Update SFP index definition (#214)

Signed-off-by: vaibhav-dahiya <vdahiya@microsoft.com>
2021-10-24 09:06:57 -07:00
vmittal-msft
8b5f33dbb7
[sonic-sairedis submodule] Update SAI header to ver 1.9.1 for MLNX SDK/SAI (#9012)
* Updated sonic-sairedis to point to SAI 1.9.1 and MLNX SAI to 1.19.5(API v1.9.1)
2021-10-22 13:49:55 -07:00
kellyyeh
ddfaa1d61f
[dhcp_relay] fix data type in dhcp6relay, add protection in packet data parsing (#9036) 2021-10-21 23:00:37 -07:00
liuh-80
5b5f3f06f0
[Bash] Fix bash build break when re-build bash issue. (#9027)
This pull request will fix bash build break issue when re-build bash.

#### Why I did it
    src/bash project using quilt to manage patches, and quilt can't apply patch correctly when cache folder '.pc' is not clean.

#### How I did it
    Add command in make file to remove quilt cache folder before apply patches.

#### How to verify it
    Re-build bash target target/debs/buster/bash_5.1-2_amd64.deb to validate this fix work.
    Pass all UT.


#### Which release branch to backport (provide reason below if selected)
    N/A

#### Description for the changelog
    Fix bash build break issue when re-build bash.

#### A picture of a cute animal (not mandatory but encouraged)
2021-10-22 10:29:12 +08:00
Qi Luo
12b8cacaa8
[devices]: Fix unit test script in order to run stretch python 3.5.3 (#9030)
It is required by stretch/sonic-device-data_1.0-1_all.deb, which is required by docker-sonic-mgmt.gz.
Stretch distribution has old Python 3.5.3.

scandir.close() is new in Python version 3.6.
ref: https://docs.python.org/3/library/os.html#os.scandir.close
2021-10-21 18:55:41 -07:00
Saikrishna Arcot
c1d5e0682f
docker-dhcp-relay: Fix waiting for interfaces to get set up (#9034)
Fix the check used to wait for interfaces to come up. The group name in
the supervisor config files has changed from isc-dhcp-relay to
dhcp-relay.

Also, in the wait script, wait 10 additional seconds after the vlans,
port channels, and any interfaces are up. This is because dhcrelay
listens on all interfaces (in addition to port channels and vlans), and
to ensure that it stays in a clean state during runtime, wait some extra
time to make sure that those interfaces are created as well.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-10-21 18:45:00 -07:00
Saikrishna Arcot
861e87812d
dhcp6relay: Save the dbgsym package into the target folder (#9013)
This makes it possible to install the debug symbols if needed. Also install
the package into the debug version of sonic-dhcp-relay container.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
2021-10-21 13:24:33 -07:00
shlomibitton
60e424e3be
Fix delay type from boot instead of unit activation (#8895)
Why I did it
With current code the delay will take place even if simple 'config reload' command executed and this is not desired.
This delay should be used only when fast-rebooting.

How I did it
Change the type of delay to OnBootSec instead of OnActiveSec.

How to verify it
Fast-reboot with this PR and observe the delay.
Run 'config-reload' command and observe no delay is running.
2021-10-20 16:08:36 -07:00
kellyyeh
14aca812e6
Fix dhcpmon bugs (#9008)
* Exclude incrementing on aggregate device if packet received on mgmt interface

* Fix DHCPv6 header offset calculation
2021-10-19 16:15:21 -07:00
ohu1
459d3d1f55
SONiC QoS MAPs and PORT_QOS_MAP Yang (#7375)
Why I did it
Created SONiC Yang model for the following QOS MAPs and PORT QOS MAP:
DSCP_TO_TC_MAP
DOT1P_TO_TC_MAP
TC_TO_QUEUE_MAP
TC_TO_PRIORITY_GROUP_MAP
MAP_PFC_PRIORITY_TO_QUEUE
PORT_QOS_MAP

How I did it
Defined Yang models for QOS MAPs based on Guideline doc:
https://github.com/Azure/SONiC/blob/master/doc/mgmt/SONiC_YANG_Model_Guidelines.md
and
https://github.com/Azure/sonic-utilities/blob/master/doc/Command-Reference.md

How to verify it
sonic_yang_models package build
The infra code was modified to handle the nested list definition in YANG and translate it to a flat list in DB.
2021-10-19 12:50:07 -07:00
Saikrishna Arcot
6432b508d9
redis-dump-load: Pin the redis package to use 3.5.3 (#9001)
Redis 4.0.0b1 has been uploaded to pip as a prerelease version. This
version drops support for Python 2 and only supports Python 3. Because
setup.py is being run, it will use the latest version of a package and
not the latest stable version (which is still 3.5.3).

Therefore, pin the redis package to version 3.5.3, so that it will work
for both Python 2 and 3.

#### How to verify it

Make sure that redis-dump-load for Python 2 builds today.
2021-10-18 20:57:26 -07:00
abdosi
3bb248bd67
[chassis-packet] minigraph parsing and BGP template changes (#8966)
1. Changes for Generation LC-Graph for packet-based chassis.
2. Added Support Ipv6 Peering on Loopback4096 for voq also
3. Updated asic topology yml files to be offset of slot
4. Made slot_num to take string slot<number> instead of number
5. Consolidated template_dpg_voq_asic.j2 into dpg_asic.j2
6. Remove Loopback4096 from asic topology and parse as dut invertory for
   multi-asic
7. Updated topo_facts parsing for asic topology_
8. Internal BGP Session rename from <VoqChassisInternal> to <ChassisInternal> and take switch_type as value.
Signed-off-by: Abhishek Dosi <abdosi@microsoft.com>
2021-10-18 18:44:24 -07:00
thomas.cappleman@metaswitch.com
c971fa7ff9
[swss, swss-common, sairedis] submodule update (#8996)
Sonic-swss-common:

[schema.h] Add trap flow counter support (#534) (Azure/sonic-swss-common@31f4253)
[schema] Add CBF table names (#525) (Azure/sonic-swss-common@b15e08d)

Sonic-sairedis:

[cbf] Add Class Based Forwarding support (#909) Azure/sonic-sairedis@ecb95a8
[azp] Enable pretty code coverage results xml (#946) Azure/sonic-sairedis@1148d16
[gearbox] startup gbsyncd in sync mode in vSonic (#939) Azure/sonic-sairedis@e59a085
[unittest] Add more Meta tests (#948) Azure/sonic-sairedis@812f7a5
[syncd] Fix SwitchNotifications to be const reference (#945) Azure/sonic-sairedis@5863ed3
[syncd] Refactor syncd request shutdown command line parser (#944) Azure/sonic-sairedis@d598dea
[unittest] Update meta tests (#943) Azure/sonic-sairedis@26b2237
[ci]: Support code diff coverage (#934) Azure/sonic-sairedis@e545b17
Sonic sairedis changes for SAI SRV6 and SAI refpoint update to v1.9.0 (#937) Azure/sonic-sairedis@921cf0b
[sairedis] Fail get/clear api on objects created in init view mode (#930) Azure/sonic-sairedis@362b34e
[vslib]: Remove invalid lane when create ports (#938) Azure/sonic-sairedis@db403f4
[Barefoot] enable bulk api`s in SAI (#927) Azure/sonic-sairedis@6df04d8
[unittest] Add NotificationBfdSessionStateChange tests (#940) Azure/sonic-sairedis@89d639b
[azp] Skip auto generated saimetadata lib code coverage (#935) Azure/sonic-sairedis@40e9c74
Remove tail white spaces Azure/sonic-sairedis@dabd1a7
Bring back pyext in Makefile.am Azure/sonic-sairedis@94d5545
Add RedisChannel tests Azure/sonic-sairedis@e16606a
Add RedisVidIndexGenerator tests Azure/sonic-sairedis@62b8fdd
Add ServerConfig tests Azure/sonic-sairedis@58725df
Add SkipRecordAttrContainer tests Azure/sonic-sairedis@6842d92
Update Switch tests Azure/sonic-sairedis@cd13f49
Add SwitchConfigContainer tests Azure/sonic-sairedis@6fc213d
Add SwitchConfigContainer tests Azure/sonic-sairedis@ee24c0e
Add SwitchContainer tests Azure/sonic-sairedis@e33c6e9
Add ZeroMQChannel tests Azure/sonic-sairedis@bcd1648
Add VirtualObjectIdManager tests Azure/sonic-sairedis@0a2cb2c
[sairedis] Remove legacy allocateSwitchIndex api Azure/sonic-sairedis@16fff7f

Sonic-swss:

[orchagent] Add separate next hop table and orch (#1702) Azure/sonic-swss@f248e26
[portorch]: Skip to create port if the lane set isn't available in ASIC (#1923) Azure/sonic-swss@fd0cafe
fix the type for SAI_BUFFER_PROFILE_ATTR_BUFFER_SIZE (#1942) Azure/sonic-swss@ef6b5d4
[cfgmgr] Fix for STATE_DB Port check (#1936) Azure/sonic-swss@b592ad7
2021-10-18 11:46:58 -07:00
Ashok Daparthi-Dell
a99d78dedb
[Yang model] SONiC QOS Scheduler, WRED, Queue Yangs (#7281) 2021-10-18 10:01:08 -07:00
Tamer Ahmed
56d4c34be7 [linkmgrd] Relocate Linkmgrd to Github
This PR deletes local-to-buildimage linkmgrd and creates new submodule
pointing to github repo of sonic-linkmgrd.

signed-off-by: Tamer Ahmed <tamer.ahmed@microsoft.com>
2021-10-15 09:59:59 -07:00
liuh-80
a4ac69e4f0
[TACACS+]: Extract tacacs support functions into library and fix memory leak issue. (#8659)
This pull request extract tacacs support functions into library to share TACACS config file parse code with other project. Also fix memory leak issue in parse config code.

Why I did it
    To support TACACS per command authorization, we need reuse the TACACS config file parse code in bash plugin project.

How I did it
    Add libtacsupport.pc.in to extract tacacs support functions into library.
    Fix memory leak issue in TACACS config parse code by convert the dynamic memory allocation memory to static memory allocation.

How to verify it
    Pass all current UT.
    Check shared library generated manually.

Which release branch to backport (provide reason below if selected)
    N/A

Description for the changelog
    Extract tacacs support functions into library, this will share TACACS config file parse code with other project.
    Also fix memory leak issue in parse config code.
2021-10-14 10:04:58 +08:00
Xichen96
4654f72f1c
[determine-reboot-cause] delay execution (#8935)
Since database.service has been moved to execute after rc-local.service,
and determine-reboot-cause.service rely on database.service, we have to
specify that in "After=".

Signed-off-by: Xichen Lin <xichenlin@microsoft.com>

Co-authored-by: Xichen Lin <xichenlin@microsoft.com>
2021-10-14 08:33:19 +08:00
Dmytro
e8adee2c83
[frrcfgd][bgpcfgd] Add portchannel support (#8911)
* To add portchannel support in frrcfgd and bgpcfgd
* Update is_zero_ip() to handle portchannel name
Signed-off-by: d-dashkov <Dmytro_Dashkov@Jabil.com>
2021-10-12 18:54:37 -07:00
gechiang
f52f97cfa5
[sonic-utilities] Update sonic-utilities submodule to pick set of new fixes (#8947) 2021-10-11 23:07:27 -07:00
liuh-80
7d40384c58
[TACACS+] Add plugin support to bash. (#8660)
This pull request add plugin support library to bash.
    And we will create a TACACS+ plugin for bash in an other PR, which will bring per command authorization feature to bash.

Why I did it
    To support TACACS per command authorization, we check user command before execute it.

How I did it
    Add plugin support to bash.

How to verify it
    UT with CUnit under bash project cover all new code in plugin.c.
    Also pass all current UT.

Which release branch to backport (provide reason below if selected)
    N/A

Description for the changelog
    Add plugin support to bash.
2021-10-11 15:20:51 +08:00
Sumukha Tumkur Vani
32e73b0872
[RESTAPI] Update Submodule (#8931)
Include the following commits:

f9bbed3cb86a3bab9a07745096835dbdbe5a4db6
Convert Unit Tests from unittest framework to pytest framework

e842c5ff317c67919dcbcab3358143cb9a16c9dd
Generate code coverage for Unit Tests
2021-10-09 15:41:22 -07:00
Qi Luo
add9b651b6
Add platform_asic file to each platform folder in sonic-device-data based package (#8542)
#### Why I did it
Add platform_asic file to each platform folder in sonic-device-data package. The file content will be used as the ground truth of mapping from PLATFORM_STRING to switch ASIC family.

One use case of the mapping is to prevent installing a wrong image, which targets for other ASIC platforms. For example, currently we have several ONIE images naming as sonic-*.bin, it's easy to mistakenly install the wrong image. With this mapping built into image, we could fetch the ONIE platform string, and figure out which ASIC it is using, and check we are installing the correct image.

After this PR merged, each platform vendor has to add one mandatory text file  `device/PLATFORM_VENDOR/PLATFORM_STRING/platform_asic`, with the content of the platform's switch ASIC family.

I will update https://github.com/Azure/SONiC/wiki/Porting-Guide after this PR is merged.

You can get a list of the ASIC platforms by `ls -b platform | cat`. Currently the options are
```
barefoot
broadcom
cavium
centec
centec-arm64
generic
innovium
marvell
marvell-arm64
marvell-armhf
mellanox
nephos
p4
vs
```

Also support
```
broadcom-dnx
```

#### How I did it

#### How to verify it
Test one image on DUT. And check the folders under `/usr/share/sonic/device`
2021-10-08 19:27:48 -07:00
Vaibhav Hemant Dixit
0780aea966
[master] Submodule advance sonic-swss (#8915)
[Submodule advance sonic-swss]
Include below commits to master image:

Cache routes for single nexthop for faster retrieval Azure/sonic-swss#1922
Reduce route count for route perf test (Azure/sonic-swss#1928)
[pytest]: Re-use DVS container when possible (Azure/sonic-swss#1816)
[PORTSYNCD] when no ports on config db on init, continue and set Port… (Azure/sonic-swss#1861)
[gearbox] Add gearbox unit test (Azure/sonic-swss#1920)
Reverted skipped test_buffer_dynamic test cases (Azure/sonic-swss#1937)
Revert "[buffer orch] Bugfix: Don't query counter SAI_BUFFER_POOL_STA… (Azure/sonic-swss#1945)
2021-10-08 17:29:23 -07:00
arlakshm
34267393b3
[yang] Feature yang changes (#7955)
Why I did it
Add yang model for Feature configuration

How I did it
Add feature.yang and unit tests

Signed-off-by: Arvindsrinivasan Lakshmi Narasimhan <arlakshm@microsoft.com>
2021-10-05 15:44:24 -07:00
Praveen Chaudhary
83108d9c9a
[YANG MGMT]: Support Grouping translation in YANG Models. (#8318)
Changes:
 -- pre Process Grouping section from all yang models, so it can be used
from any yang model.
-- add jsondiff in setup.py, it is useful for test debugging in case of
failures.
-- use 'stypes' instead of head.
-- pass config DB table name in _createLeafDict().
-- added test config for grouping.
-- white spaces changes.

Note: Changes are done in the way that we can add support for other
Generic YANG statement easily for translation.

Signed-off-by: Praveen Chaudhary pchaudhary@linkedin.com
2021-09-30 12:53:34 -07:00
Sudharsan Dhamal Gopalarathnam
1e35915dcf
Load global config in caclmgrd only in multi asic NPU (#8812)
How I did it
Added if multi npu check before invoking the load global config.

How to verify it
Restart caclmgrd after this change and check if no error log is thrown.
2021-09-30 12:45:51 -07:00
Sumukha Tumkur Vani
33e64a4e7e
[RESTAPI] submodule update (#8859)
Rejection of incorrect CIDR addresses while configuring routes.
2021-09-29 15:43:04 -07:00
Sumukha Tumkur Vani
67db126333
Reduce logging level for RESTAPI from trace to info (#8858) 2021-09-29 15:41:47 -07:00
Ashok Daparthi-Dell
6cbdf11e53
SONIC QOS YANG - Remove qos tables field value refernce format (#7752)
Depends on Azure/sonic-utilities#1626
Depends on Azure/sonic-swss#1754

QOS tables in config db used ABNF format i.e "[TABLE_NAME|name] to refer fieldvalue to other qos tables.

Example:
Config DB:
"Ethernet92|3": {
"scheduler": "[SCHEDULER|scheduler.1]",
"wred_profile": "[WRED_PROFILE|AZURE_LOSSLESS]"
},
"Ethernet0|0": {
"profile": "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet0": {
"dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]",
"pfc_enable": "3,4",
"pfc_to_queue_map": "[MAP_PFC_PRIORITY_TO_QUEUE|AZURE]",
"tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]",
"tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]"
},

This format is not consistent with other DB schema followed in sonic.
And also this reference in DB is not required, This is taken care by YANG "leafref".

Removed this format from all platform files to consistent with other sonic db schema.
Example:
"Ethernet92|3": {
"scheduler": "scheduler.1",
"wred_profile": "AZURE_LOSSLESS"
},

Dependent pull requests:
#7752 - To modify platfrom files
#7281 - Yang model
Azure/sonic-utilities#1626 - DB migration
Azure/sonic-swss#1754 - swss change to remove ABNF format
2021-09-28 09:21:24 -07:00
Sudharsan Dhamal Gopalarathnam
b2659dcdbc
Handle feature flow when state is always_enabled (#8811)
Why I did it
When feature state is set to always_enabled hostcfgd throws error message
Sep 21 22:30:55.135377 r-leopard-32 ERR /hostcfgd: Unexpected state value 'always_enabled' for feature bgp
Sep 21 22:30:55.420268 r-leopard-32 ERR /hostcfgd: Unexpected state value 'always_enabled' for feature database
Sep 21 22:30:58.672714 r-leopard-32 ERR /hostcfgd: Unexpected state value 'always_enabled' for feature swss
This is due to feature == always_enabled not handled properly.

How I did it
Handled the scenario when feature is always enabled

How to verify it
Restart hostcfgd with feature state configured as always_enabled and check if there are no errors.
Added UT to cover the scenario.
2021-09-28 08:52:03 -07:00
ArthiSivanantham
ada8043ed3
SONiC Yang for Warm Restart (#7698)
Why I did it
SONiC YANG model support for warm restart.

How I did it
Defined warm restart YANG containers and lists based on config-DB schema.

How to verify it
Successful build of the following packages:
make target/python-wheels/sonic_yang_models-1.0-py3-none-any.whl
make target/python-wheels/sonic_yang_mgmt-1.0-py3-none-any.whl

Signed-off-by: Arthi Sivanantham <arthi_sivanantham@dell.com>
2021-09-28 08:51:26 -07:00
Junchao-Mellanox
c770375b3f
[submodule] Update submodule for sonic-utilities (#8752)
0d538d3 [ci]: Support code diff coverage (#1834)
48887d1 [config] support for configuring muxcable to standby mode of operation (#1837)
2088a9a Provide support to install platform extensions (#1578)
c97fe54 Add check_db_integrity script to setup.py (#1828)
c0b9917 [debug dump util] COPP Module Added (#1670)
826311c [techsupport] Removed interactive option for docker commands and Improved Error Reporting (#1723)
ce11545 [config reload] Removed job-mode for sonic.target restart (#1820)
f76f672 [fdbshow]: Fix typo in comment (#1809)
17208a0 [ci]: Support PR coverage (#1806)
c2c2354 fix wrong code indent in sfputil (#1808)
47a9a0f [portconfig] Validate duplicate speed value and interface type value (#1745)
f1086ee [sonic_installer]Add --skip-platform-check option for sonic_installer when image mismatch (#1791)
c007d65 [warm-reboot] Add new preboot health check: verify database integrity (#1785)
41e31e8 Fix PatchApplier init order (#1762)
2416175 [config reload] Fix config reload failure due to sonic.target job cancellation (#1814)
2b12aad [portstat, intfstat] added rates and utilization (#1750)
26e700a [debug dump util] Techsupport addition (#1669)
9f2326e [debug dump util] Base Skeleton and Click Class added (#1668)
2021-09-28 02:52:04 -07:00
Ashok Daparthi-Dell
6c40fe4f44
[Submodule] update for swss (#8839)
*[Submodule] update for swss with following commits:
a3fdaf4 QOS fieldvalue reference ABNF format to string changes ([sonic-platform-daemons] Update submodule #1754)
a8fcadf Add sleep to ensure starting route perf test after the vs is stable ([mellanox]: Update hw-mgmt service with the stop action #1929)
a89d1f8 Fix failing DPB LAG tests ([socat]: build socat with readline #1919)
86b4ede [portsorch] Avoid orchagent crash when set invalid interface types to port (Upgrade azure-keyvault to known compatible version #1906)
025032f [VS] Skip failing test - test_recirc_port ([rsyslog]: use # to separate container and program name in syslog msg #1918)
d338bd0 [pfcwd] Fix the polling interval time granularity (Download newer version (8.23.0-2) of rsyslog from jessie-backports in hopes of eliminating memory leaks #1912)
14c937e Enabling copp tests ([Mellanox] Update hw-management service config #1914)
fbdcaae [teammgrd]: Improve LAGs cleanup on shutdown: send SIGTERM directly to PID. ([docker-syncd-mlnx] add new mlnx-sfpd daemon to docker-syncd-mlnx #1841)
002bb1d [tlm teamd] Add retry mechanism before logging the ERR in get_dumps. ([py-swss/config] config load-minigraph failure leaves database in wrong state #1629)
57d21e7 [pfcwd] Convert polling interval from ms to us in LUA scripts ([interfaces]: Move IP/MTU information from interfaces file into database #1908)
d01524d [fgnhgorch] Enable packet flow when no FG ECMP neighbors are resolved (Update arista driver submodule to includes interrupt handling changes #1900)
8cf355d Mux state order change ([submodule] update snmpagent and dbsyncd, extending/implementing ieee802.1ab, rfc3433, rfc2737 MIBs #1902)
2021-09-27 18:20:08 -07:00
arunlk-dell
b0b0ba828a
DellEMC: N3248PXE Initial platform commit (#8562)
Why I did it
Added support for the device N3248PXE

How I did it
Implemented the support for the platform N3248PXE
n3248pxe_unit_test_log.txt

Switch Vendor: DellEMC
* Switch SKU: N3248PXE
* ASIC Vendor: Broadcom
* SONiC Image: sonic-broadcom.bin

How to verify it
Verified the show platform commands
2021-09-25 15:35:16 -07:00
arunlk-dell
8325500560
DellEMC: N3248TE Initial platform commit (#8809)
Why I did it
Added support for the device N3248TE

How I did it
Implemented the support for the platform N3248TE

Switch Vendor: DellEMC

Switch SKU: N3248TE
ASIC Vendor: Broadcom
SONiC Image: sonic-broadcom.bin
How to verify it
Verified the show platform commands
2021-09-23 20:47:32 -07:00
Junhua Zhai
27aef53054
[submodule] update sonic-swss-common to latest (#8828)
The following fixes are included:
b502743 [gearbox] Since ASIC_DB, as well its COUNTER_DB, FLEX_COUNTER_DB use separator ':', GB_ASIC_DB
        should use same ((Azure/sonic-swss-common#532)
81182ec Added support for setting TTL on a Table managed entry. ((Azure/sonic-swss-common#526)
2021-09-24 10:25:27 +08:00
bingwang-ms
1d7e82b96d
Update minigraph parser to support type MIRROR_DSCP (#8819)
* Update minigraph parser to support MIRROR_DSCP

Signed-off-by: bingwang <bingwang@microsoft.com>
2021-09-23 16:18:56 +08:00
kellyyeh
bc06c6fcb5
Incorporate DHCPv6 Relay Agent into dhcp-relay docker (#8321) 2021-09-22 16:05:03 -07:00
Sumukha Tumkur Vani
34dddb8ce4
[RESTAPI] Update submodule
Commits included:

1. Update API description for default vrf and ecmp routes
    fad87fa20f6b15e28c90e02a131c44d236d6a751

2. Fix WS-2018-0594 potential non-random UUIDs security issue
    8d4fd4a56b637d3b7403c321aef36b8dff58cd62

3. Add BFD config to subinterface and neighbor
    d3e8b8e4aee278fa11d7d86acabdab3fffc70d5a

4. Default Vrf static route support
    6cfc8fe110c46a1ee5a8430e02a440b5a7b4006d

5. Added flag to make go/pkg/ folder writable (removable)
    ee887c785c10d8b4f70db90ca50cc398327c5d73
2021-09-21 10:13:48 -07:00
AmitKaushik7
4049067534
[yang]: Adding yang model for PFC watch dog parameters (#7839)
Added sonic-pfcwd.yang file that defines the yang model for PFC watch dog parameters
sonic-pfcwd.yang is required for configuring action, detection_time, restoration time of PFC watchdog on the interface port.
2021-09-20 14:58:30 -07:00
Prince George
f1dac178f0
Update sonic-platform-daemon submodule (#8788)
Signed-off-by: Prince George <prgeor@microsoft.com>
2021-09-18 12:31:05 +05:30
Sudharsan Dhamal Gopalarathnam
508b6497a1
Advancing sonic-sairedis submodule pointer (#8775) 2021-09-16 20:04:46 +02:00
Lior Avramov
2662a19eec
[sonic-py-swsssdk]: submodule update (#8757)
2cd6236 [voq][chassis] Fix for issue in chassis redis server connection check (#110)
9da577d [port_util] Fix issue in function get_interface_oid_map (#114)
740a44c [port_util] Allow system without ports in config db run without errors (#109)
d07682e Merge pull request #111 from xumia/azp-coverage
482cac2 [Ethernet-IB][index] Modifed the port_util to support the VoQ Inband Port (#113)
69eac92 Support azp diff coverage

Signed-off-by: liora <liora@nvidia.com>
2021-09-15 14:00:43 -07:00
vganesan-nokia
1863e1fa26
[multi-asic][cli][chassis-db] Avoid connecting to chassis db when cli commands are executed from linecards (#8065)
* [multi-asic][cli][chassis-db] Avoiding connecting to chassis db

Currently, for all the cli commands, we connect to all databases
mentioned in the database_config.json. The database_config.json also
includes the databases from chassis redis server from supervisor card.
It is unneccessary to connect to databases from chassis redis server
when cli commands are executed form linecard. But we need to allow
connection to chassis databases when the cli commands are executed from
supervisor card.

The changes in this PR fixes this problem. This PR requires that
asic.conf in supervisor card includes VOQ_SUPERVISOR with value 1 to
indentify the supervisor card. The connect_to_all_dbs_for_ns() is
changed to skip chassis databases form the list of collected databases
if the card is not supervisor card.
2021-09-14 11:04:19 -07:00
Ying Xie
66ca6d33c7
Revert "Revert "[hostcfgd] Delay hostcfgd and aaastatsd for faster boot time (#7965)" (#8705)" (#8724)
This reverts commit f4dea87cf9.
2021-09-14 07:57:43 -07:00
Sudharsan Dhamal Gopalarathnam
b423b17221
[DPB]Removing default admin status initialization in DPB flow while loading minigraph (#8711)
To Fix #8697 . The config load_minigraph initializes 'admin_status' to up when platform.json has DPB configs. This doesn't happen when using port_config.ini
The update minigraph has logic to initialize only the ports whose neighbors are defined or those belonging to portchannel
However, a change was introduced to have default admin status to be 'up' in portconfig.py when the minigraph was using platform.json

This will lead to sanity check failure in sonic-mgmt and thus no test cases could be run
2021-09-13 09:01:29 -07:00
Guohan Lu
1652613ad7
[submodule]: retreat sonic-swss submodule (#8732)
Fix #8722

retreat two commits which cause warm reboot regression

* eb79ca4 2021-09-01 | [pbh]: Add PBH OA (#1782) [Nazarii Hnydyn]
* 3d6b1f0 2021-08-31 | [buffer orch] Bugfix: Don't query counter SAI_BUFFER_POOL_STAT_XOFF_ROOM_WATERMARK_BYTES on a pool where it is not supported (#1857) [Stephen Sun]

Signed-off-by: Guohan Lu <lguohan@gmail.com>
2021-09-10 20:17:15 -07:00
Nazarii Hnydyn
f8949547d7
[submodule]: Advance sonic-sairedis. (#8706)
Signed-off-by: Nazarii Hnydyn <nazariig@nvidia.com>
2021-09-10 11:29:37 +02:00
Sudharsan Dhamal Gopalarathnam
8171bfefc8
Enhancing vs support to mock based on platform (#8685) 2021-09-09 20:03:22 +02:00
pettershao-ragilenetworks
8514a484cd
[platform/ragile] support ra-b6910-64c (#7950)
What I did it
Add new platform x86_64-ragile_ra-b6910-64c-r0 (Tomahawk 3)
ASIC Vendor: Broadcom
Switch ASIC: Tomahawk 3
Port Config: 64x100G

-How I did it
Provide device and platform related files.

-How to verify it
show platform fan
show platform ssdhealth
show platform psustatus
show platform summary
show platform syseeprom
show platform temperature
show interface status
2021-09-09 10:49:37 -07:00
Longxiang Lyu
7e02f7b4ba
[submodule] advance sonic-utilities (#8695)
To include sonic_installer swap setup changes

171eb4f [sonic_installer] Add swap setup support (#1787)
6483b0b QOS fieldvalue refernce ABNF format to string (#1626)
8d16eb5 [Fast-reboot] Set flex counters delay indicator to prevent flex counters enablement after fast-reboot (#1768)
1bc24ca [portstat pfcstat] Unify the packet number format in the output of portstat and pfcstat in all cases (#1755)
d7900dd [config][generic-update] Implementing patch sorting (2nd attempt) (#1794)
7ed9a91 [show] Allow system with no ports in config db run without errors (#1754)

Signed-off-by: Longxiang Lyu <lolv@microsoft.com>
2021-09-09 07:25:14 -07:00
Guohan Lu
f4dea87cf9
Revert "[hostcfgd] Delay hostcfgd and aaastatsd for faster boot time (#7965)" (#8705)
cause regression on the kvm testing

This reverts commit 76d5223c9a.
2021-09-08 08:45:16 -07:00
Qi Luo
74134c0bb6
[sonic-utilities] submodule update (#8658)
Includes commits
```
d7900dd 2021-09-01 | [config][generic-update] Implementing patch sorting (2nd attempt) (#1794) [Mohamed Ghoneim]
7ed9a91 2021-09-01 | [show] Allow system with no ports in config db run without errors (#1754) [Lior Avramov]
```
2021-09-08 04:09:45 -07:00
Ann Pokora
7c9be314e2
[yang]: sonic-yang-models updates for MPLS (#7881)
SONiC YANG model support in buildimage for MPLS:

sonic-yang-model support for MPLS enable/disable
sonic-yang-model support for MPLS CRM thresholds
2021-09-02 10:32:27 -07:00
Nazarii Hnydyn
124e6d42e6
[submodule]: Advance sonic-swss. (#8652)
Commits on Aug 17, 2021
[VS Test] Skip flaky tests (#1875) f501e1c
Skipping another flaky test temporarily (#1878) 15a014b

Commits on Aug 18, 2021
Change rif_rates.lua and port_rates.lua scripts to calculate rates co… ed867b1

Commits on Aug 20, 2021
[ACL] Match TCP protocol while matching TCP_FLAG (#1854) 756471a

Commits on Aug 23, 2021
[macsecmgrd] MACsec XPN changes (#1821) 4bf3d61

Commits on Aug 24, 2021
[ci]: fix artifacts download from swss-common and sairedis (#1882) 12f0ee7

Commits on Aug 26, 2021
[gearbox] Set port speed to SAI_PORT_ATTR_SPEED for gearbox (#1785) fc6cd81
[fpmsyncd][MPLS] updates for MPLS plus AZP libnl3 install (#1871) 76e3406

Commits on Aug 27, 2021
Fix vs test failure in test_buffer_traditional (#1881) db9ca83

Commits on Aug 31, 2021
[buffer orch] Bugfix: Don't query counter SAI_BUFFER_POOL_STAT_XOFF_R… 3d6b1f0

Commits on Sep 01, 2021
[pbh]: Add PBH OA (#1782) eb79ca4 

Signed-off-by: Nazarii Hnydyn <nazariig@nvidia.com>
2021-09-02 01:04:12 -07:00
shlomibitton
112fda7877
[Flex Counters] Reset flex counters delay flag on config DB when enable_counters script is called (#8500)
#### Why I did it
Reset flex counters delay flag on config DB when enable_counters script is called to allow enablement of flex counters in orchagent.

#### How I did it
Push to config DB 'false' value for delay indication when enable_counters script is called before enabling the counters.

#### How to verify it
Observe counters are created when enable_counters script is called.
2021-09-01 21:17:36 -07:00
Nazarii Hnydyn
b7cad1c569
[submodule]: Advance sonic-utilities (#8653)
Commits on Aug 25, 2021
[show][config] cli refactor for muxcable with abstract class implemen… 37039f5
[voq][chassis] VOQ cli show commands implementation (#1689) 7ebb2f7
[PBH] CLI for Policy Based Hashing (#1701) 6fd0675

Commits on Aug 26, 2021
[config reload] Call systemctl reset-failed for snmp,telemetry,mgmt-f… f5ce87a

Commits on Aug 27, 2021
Fix logic in RIF counters print (#1732) 83309c6

Commits on Aug 30, 2021
[ecnconfig] Fix exception seen during display and add unit tests (#1784) 3e8626e

Commits on Aug 31, 2021
[debug dump util] Module implementation Logic and Port Module (#1667) 720b650
2021-09-01 19:11:17 -07:00
Mohamed Ghoneim
3fa8c2595f
[yang-models] Removing sonic-acl import from sonic-nat.yang (#8632)
#### Why I did it
Fixing issue [[sonic-utilities] Unit test failed when building sonic-utilities #1761](https://github.com/Azure/sonic-utilities/issues/1761)

Importing `sonic-acl` caused getting references by `backlinks()` to break, 

#### How I did it
solution is to comment out the importing statement as it is not used anyway.

#### How to verify it
Ran sonic-utilities unit-tests locally after the fix, and all passed.
2021-09-01 07:29:17 -07:00
Myron Sosyak
0ab28bfd3d
Add thrift 0.13.0 (#8307)
#### Why I did it
To bump thrift version to 0.13.0, to fix some dependencies issues.

#### How I did it
As there are dependencies between thrift and saithrinft server  (bf3630316c/test/saithrift) which is used by syncd-rpc to update thrift version, I also need to make changes in saithrinft server, and then SAI ref point should be updated in sairedis, and then sairedis ref point should be updated too. It is too many change, so I decided to add thrift 0.13.0 as separeate target to be able to work and test father changes in saithrinft and one when appropriate changes will be merged to SAI and ref points will be updated I will squash this and the old thrift target.  I was not able to build thrift deb pkg by original rules, so I copied `debian `folder from the old version and tune it for newer one.

#### How to verify it
```
make init
make configure PLATFORM=vs
make target/debs/buster/libthrift_0.13.0_amd64.deb
```

```
2021-09-01 06:10:14 -07:00
vdahiya12
c7fcbe1ab3
[sonic-platform-daemons][sonic-platform-common] submodule update (#8577)
This PR updates the following commits in sonic-platform-daemons

e038bc2 [xcvrd] initial support for integrating vendor specfic class objects for calling Y-Cable API's inside xcvrd (#197)
57e3d78 Fix issue#8230 (#210)
f63fc94 [thermalctld] Use interval set in thermal policy if available (#164)
8b2227d [CI] Sum up Azp unit test code coverage (#209)
b880c48 [xrcvd]: Added unit test for sfp oir events (#205)
4a32b5a [y-cable] fix for logging the xcvrd metrics before writing the state to the State-DB (#208)
53e1532 (origin/shilong-test) Add str conversion for numeric xcvr info fields to xcvrd (#200)
03a4add Introduce mgmtinit delay after transceiver module insertion (#201)

This PR updates the following commits in sonic-platform-common
0dc71c1 Add y-cable driver for simulated mux (#213)

Signed-off-by: vaibhav-dahiya <vdahiya@microsoft.com>
2021-08-30 15:56:41 -07:00