Commit Graph

571 Commits

Author SHA1 Message Date
anish-n
733f7091ac [bgpcfgd]: Add Vlan prefix list to the FRR templates (#5005)
add the Vlan prefix list to the FRR templates
2020-07-26 11:17:29 -07:00
Danny Allen
0824509373 [docker-ptf] Add support for spytest to ptf container (#4410)
- Install apt and pip dependencies
- Define traffic generator service

Signed-off-by: Danny Allen <daall@microsoft.com>
2020-07-14 22:06:05 -07:00
abdosi
b725572023
Fix the below frr start.sh jija2 exception in 201911 image syslog: (#4958)
File "/usr/local/bin/sonic-cfggen", line 380, in <module>
     main()
   File "/usr/local/bin/sonic-cfggen", line 354, in main
     print(template.render(data))
   File "/usr/local/lib/python2.7/dist-packages/jinja2/environment.py", line 1090, in render
     self.environment.handle_exception()
   File "/usr/local/lib/python2.7/dist-packages/jinja2/environment.py", line 832, in handle_exception
     reraise(*rewrite_traceback_stack(source=source))
   File "<template>", line 1, in top-level template code
   File "/usr/local/lib/python2.7/dist-packages/jinja2/environment.py", line 471, in getattr
     return getattr(obj, attribute)
 jinja2.exceptions.UndefinedError: 'WARM_RESTART' is undefined

Signed-off-by: Abhishek Dosi <abdosi@microsoft.com>
2020-07-14 08:02:32 -07:00
Ying Xie
6427f1a4f8 [mgmt docker] move pycryptodome installation to the end of the docker building (#4917)
* [mgmt docker] move pycryptodome installation to the end of the docker building

Signed-off-by: Ying Xie <ying.xie@microsoft.com>

* pin down the version to current: 3.9.8

* comment
2020-07-11 09:46:51 -07:00
Tamer Ahmed
1bb3918a55 [telemetry] Call sonic-cfggen Once (#4901)
sonic-cfggen call is slow and this is taking place in the SONiC
boot up process. The change uses templates to assemble all required
vars into single template file. With this change, telemetry now calls
once into sonic-cfggen.

signed-off-by: Tamer Ahmed <tamer.ahmed@microsoft.com>
2020-07-11 09:45:22 -07:00
arlakshm
aef3f7dc5a "[config]: Multi ASIC loopback changes (#4895)
Resubmitting the changes for (#4825) with fixes for sonic-bgpcdgd test failures
Signed-off-by: Arvindsrinivasan Lakshmi Narasimhan <arlakshm@microsoft.com>
2020-07-08 09:03:41 -07:00
Shuba Viswanathan
b7b602bb11 [sonic-mgmt]: Support for pytest-html to control logs better (#4791)
The current stdout file which also includes the dut logs are very verbose and noisy.

We have manually installed it in the sonic-mgmt docker in our organization and tuned the pytest settings to produce very helpful and concise logs.

pytest-html plugins can be used to post-process the output in various ways based on our different and unique organizational needs.

Hence proposing to add this pkt to the docker file
2020-07-06 18:33:50 -07:00
Danny Allen
fbdd77594f [mgmt docker] Clean up docker-sonic-mgmt dockerfile (#4759)
- Alphabetize dependencies to prevent duplicates
- Remove unneccesary git clone

Signed-off-by: Danny Allen <daall@microsoft.com>
2020-07-06 18:33:37 -07:00
Arun Saravanan Balachandran
abe2d40cdf [docker-sonic-mgmt]: import patch to support 'become' and 'become_user' arguments in pytest-ansible (#4681) 2020-07-06 18:33:25 -07:00
Ying Xie
8a26951eb2 [sonic-mgmt] upgrade ansible to 2.7.12 (#4751)
Signed-off-by: Ying Xie <ying.xie@microsoft.com>
2020-07-06 18:33:14 -07:00
Ying Xie
3129451239 [sonic-mgmt] upgrade paramilo to version 2.7.1 (#4750)
spytest requires higher paramiko version. Fix it to 2.7.1.

Signed-off-by: Ying Xie <ying.xie@microsoft.com>
2020-07-06 18:33:00 -07:00
Guohan Lu
86955e2b04 [docker-sonic-mgmt]: fix pip version to 20.1.1
Signed-off-by: Guohan Lu <lguohan@gmail.com>
2020-07-06 18:32:48 -07:00
Wei Bai
9b32171664 [docker-sonic-mgmt] Add IxNetwork python client (#4533)
* Add IxNetwork python client to sonic mgmt docker
2020-07-06 18:32:35 -07:00
Danny Allen
1652206852 [docker-sonic-mgmt] Merge spytest dependencies into mgmt docker (#4411)
Signed-off-by: Danny Allen <daall@microsoft.com>
2020-07-06 18:32:23 -07:00
xumia
276310dceb [docker-sonic-mgmt]: Fix virtual environment bug (#4370) 2020-07-06 18:32:11 -07:00
xumia
d28945987c [sonic-mgmt]: Support virtual environment for ansible 2.0.0.2 (#4325)
. env-201811/bin/activate

The ansible 2.0.0.2 will be used.
2020-07-06 18:32:01 -07:00
Xin Wang
db15b88bfc [docker-sonic-mgmt]: Add the snmp tool to the sonic-mgmt docker (#4110)
The snmp tool is required for interacting with certain type
of PDU hosts in platform PSU/power related testing. This
change is to have the snmp tool pre-built in the sonic-mgmt
docker image.

Signed-off-by: Xin Wang <xinw@mellanox.com>
2020-07-06 18:31:46 -07:00
Guohan Lu
5310b0946d [docker-sonic-mgmt]: set wheel version to 0.33.6 to fix sonic-mgmt build break
looks like version 0.42 has build issues

Signed-off-by: Guohan Lu <gulv@microsoft.com>
2020-07-06 18:31:34 -07:00
Guohan Lu
c9e012d327 [docker-sonic-mgmt]: fix installation permission issue 2020-07-06 18:31:14 -07:00
Iris Hsu
3eac616dc4 [sonic-mgmt]: Install python-subnettree to sonic-mgmt container. (#3978)
* Install python-subnettree to sonic-mgmt container.
2020-07-06 18:31:01 -07:00
Myron Sosyak
35e9d5bc72 [docker-sonic-mgmt]: Add docker-ce-cli to sonic-mgmt container (#3868)
In the scope of migration from docker shell plugin to docker connection plugin, we need to have docker-ce-cli installed in docker-sonic-mgmt. Azure/sonic-mgmt#1269

Added docker-ce-cli package to docker-sonic-mgmt.
2020-07-06 18:30:45 -07:00
pavel-shirshov
6958441959 Tests for bgpcfgd templates (#4841)
* Tests for bgpcfgd templates
2020-07-05 15:55:18 -07:00
pavel-shirshov
1930b3ac89 [bgpcfgd]: make a package for bgpcfgd (#4813) 2020-07-05 15:51:05 -07:00
pavel-shirshov
9c62ce9ebb Tests of FRR templates which rendered by sonic-cfggen (#4875)
* Tests of FRR templates which rendered by sonic-cfggen
2020-07-05 15:37:04 -07:00
abdosi
4869fa7173 [sonic-buildimage] Changes to make network specific sysctl common for both host and docker namespace (#4838)
* [sonic-buildimage] Changes to make network specific sysctl
common for both host and docker namespace (in multi-npu).

This change is triggered with issue found in multi-npu platforms
where in docker namespace
net.ipv6.conf.all.forwarding was 0 (should be 1) because of
which RS/RA message were triggered and link-local router were learnt.

Beside this there were some other sysctl.net.ipv6* params whose value
in docker namespace is not same as host namespace.

So to make we are always in sync in host and docker namespace
created common file that list all sysctl.net.* params and used
both by host and docker namespace. Any change will get applied
to both namespace.

Signed-off-by: Abhishek Dosi <abdosi@microsoft.com>

* Address Review Comments and made sure to invoke augtool
only one and do string concatenation of all set commands

* Address Review Comments.
2020-07-05 15:32:30 -07:00
judyjoseph
a80683dcd1 Support for connecting to DB in namespace via TCP port in multi-asic platform. (#4779)
* Support for connecting to DB in namespace via IP:port ( using docker bridge network ) for applications in multi-asic platform.

* Added the default IP as 127.0.0.1 if the IPaddress derivation from interface fails.
Moved the localhost loopback IP binding logic into the supervisor.j2 file.
2020-07-05 15:27:00 -07:00
abdosi
75d5e30f07 Changes to make default route programming correct in multi-npu platforms (#4774)
* Changes to make default route programming
correct in multi-asic platform where frr is not running
in host namespace. Change is to set correct administrative distance.
Also make NAMESPACE* enviroment variable available for all dockers
so that it can be used when needed.

Signed-off-by: Abhishek Dosi <abdosi@microsoft.com>

* Fix review comments

* Review comment to check to add default route
only if default route exist and delete is successful.
2020-07-05 15:21:09 -07:00
yozhao101
d32beffed0
[201911][docker-lldp] Correct lldp-syncd program name in critical_processes file (#4863)
The program name in critical_processes file must match the program name defined in supervisord.conf file.

Signed-off-by: Yong Zhao <yozhao@microsoft.com>
2020-06-28 11:09:27 -07:00
Tamer Ahmed
10cd212577 [fast-reboot] Back up FDB/ARP/Default routes (#4795)
FDB/ARP/Default routes files are deleted after swssconfig. This
makes debugging/validation of device conversion hard. This PR
saves those files in order to facilitate debugging of device conversion.

signed-off-by: Tamer Ahmed <tamer.ahmed@microsoft.com>
2020-06-28 07:27:55 -07:00
yozhao101
c2364cf03e
[201911][dockers] Update critical_processes file syntax (#4854)
Backport of https://github.com/Azure/sonic-buildimage/pull/4831 to the 201911 branch
2020-06-26 11:37:05 -07:00
arlakshm
c5807c2dd2 [bgp]:Add redistribution connected for ipv6 also for Frontend ASICs (#4767)
* fix redistribution connected for ipv6 also

Signed-off-by: Arvindsrinivasan Lakshmi Narasimhan <arlakshm@microsoft.com>
2020-06-16 08:18:19 -07:00
Junchao-Mellanox
0a70571011
[201911][thermal control] Backport feature from master branch (#4677)
Backport thermal control feature from master branch to 201911 branch by cherry-picking commits and manually resolving conflicts.
2020-06-08 11:20:43 -07:00
judyjoseph
7bd7756129 Adding new BGP peer groups PEER_V4_INT and PEER_V6_INT. (#4620)
* Adding new BGP peer groups PEER_V4_INT and PEER_V6_INT. The internal BGP sessions
will be added to this peer group while the external BGP sessions will be added
to the exising PEER_V4 and PEER_V6 peer group.

* Check for "ASIC" keyword in the hostname to identify the internal neighbors.
2020-05-20 22:44:14 -07:00
arlakshm
321b99b48c Change to enable redistribute connected on Frontend asics instead of backend asics (#4588)
Signed-off-by: Arvindsrinivasan Lakshmi Narasimhan <arlakshm@microsoft.com>
2020-05-20 07:53:50 -07:00
abdosi
9ea746e25f Changes for LLDP docker to support multi-npu platforms (#4530)
* Changes for LLDP for Multi NPU Platoforms:-
a) Enable LLDP for Host namespace for Management Port
b) Make sure Management IP is avaliable in per asic namespace
   needed for LLDP Chassis configuration
c) Make sure chassis mac-address is correct in per asic namespace
d) Do not run lldp on eth0 of per asic namespace and avoid chassis
   configuration for same
e) Use Linux hostname instead from Device Metadata for lldp chassis
   configuration since in multi-npu platforms device metadata hostname
   will be differnt

Signed-off-by: Abhishek Dosi <abdosi@microsoft.com>

* Address Review Comment with following changes:
a) Use Device Metadata hostname even in per namespace conatiner.
   updated minigraph parsing for same to have hostname as system
   hostname and add new key for asic name

b) Minigraph changes to have MGMT_INTERFACE Key in per asic/namespace
   config also as needed for LLDP for setting chassis management IP.

Signed-off-by: Abhishek Dosi <abdosi@microsoft.com>

* Address Review Comments
2020-05-20 07:51:49 -07:00
judyjoseph
c808640f4e Multi DB with namespace support, Introducing the database_global.json… (#4477)
* Multi DB with namespace support, Introducing the database_global.json file
for supporting accessing DB's in other namespaces for service running in
linux host

* Updates based on comments

* Adding the j2 templates for database_config and database_global files.

* Updating to retrieve the redis DIR's to be mounted from database_global.json file.

* Additional check to see if asic.conf file exists before sourcing it.

* Updates based on PR comments discussion.

* Review comments update

* Updates to the argument "-n" for namespace used in both context of parsing minigraph and multi DB access.

* Update with the attribute "persistence_for_warm_boot" that was added to database_config.json file earlier.

* Removing the database_config.json file to avioid confusion in future.
We use the database_config.json.j2 file to generate database_config.json files dynamically.

* Update the comments for sudo usage in docker_image_ctrl.j2

* Update with the new logic in PING PONG tests using sonic-db-cli. With this we wait till the
PONG response is received when redis server is up.

* Similar changes in swss and syncd scripts for the PING tests with sonic-db-cli

* Updated with a missing , in the database_config.json.j2 file, Do pip install of j2cli in docker-base-buster.
2020-05-09 21:33:07 -07:00
Dong Zhang
3faa4e936e [MultiDB] use sonic-db-cli PING and fix wrong multiDB API in NAT (#4541) 2020-05-09 18:16:48 -07:00
abdosi
5e17126ffe [bgpcfgd]: Fix for BGP peer not coming up even after config BGP startup all (#4547)
Issue was key not correct to look into self.peer. It need to be tuple of
(vrf,nbr). Updated for both add/del
2020-05-06 22:30:18 -07:00
arlakshm
139d37338a [bgp]: align the bgp templates with new minigraph for multi NPU platforms (#4488)
- change the references to 'type' field to 'sub_role'
- change the references to 'InternalFrontend' and 'InternalBackend' to 'FrontEnd' and 'BackEnd' respectively
- add a statement to reflect route-reflector for backend asics
- add a change to set "next-hop-self force" configuration for internal BGP session in multi asic platform.

Signed-off-by: Arvindsrinivasan Lakshmi Narasimhan <arlakshm@microsoft.com>
2020-05-06 22:30:18 -07:00
lguohan
cb22310a52 [docker-ptf]: install ntp related package (#4275)
setup ntp server to do the test

Signed-off-by: Guohan Lu <lguohan@gmail.com>
2020-05-05 11:02:35 -07:00
lguohan
1f72d2b60a [docker-ptf]: install tacacs+ server to test tacacs (#4224)
Signed-off-by: Guohan Lu <lguohan@gmail.com>
2020-05-05 11:00:54 -07:00
Nazarii Hnydyn
c266435d40
Revert "Add thermal control support for SONiC (#3949)" (#4527)
This reverts commit 109a13cc03.

Conflicts:
	dockers/docker-platform-monitor/docker-pmon.supervisord.conf.j2
2020-05-04 21:20:47 +03:00
Sujin Kang
9cbc07996e [pmon]: Fix the continous syseepromd autorestart issue on 201911 (#4478)
- Remove syseepromd from the critical process of pmon docker
- Fix supervisor autorestart configuration of syseepromd
2020-04-30 22:40:46 -07:00
Junchao-Mellanox
109a13cc03 Add thermal control support for SONiC (#3949) 2020-04-30 22:39:17 -07:00
judyjoseph
db5da0f712
Pass instance ID while starting orchagent process. Getting Azure#4465 in 201911 (#4514) 2020-04-30 22:07:32 -07:00
Judy Joseph
15c5aa086b Revert "Getting https://github.com/Azure/sonic-buildimage/pull/4465 in 201911"
This reverts commit a3cb8a6e56.
2020-04-30 11:16:38 -07:00
Judy Joseph
a3cb8a6e56 Getting https://github.com/Azure/sonic-buildimage/pull/4465 in 201911 2020-04-30 10:40:01 -07:00
Kebo Liu
e12d2e8bee
[PMON] Extend pmon daemon start control to lm-sensors and fancontrol for 201911 (#4487)
Extend the PMON daemon start control to lm-sensors and fancontrol.

change template docker-pmon.supervisord.conf.j2 and start.sh.j2 to have lm-sensors and fancontrol start scripts and supervisord config file controlled by pmon_daemon_control.json.

the intention is to avoid wrong daemon status in "supervisorctl status" output. For example, on some platform, if there is no fancontrol config file, and it is not ruled out from supervisord conf file and start.sh, we'll see fancontrol in "STOPPED" status from "supervisorctl status" output, which will violate some check in the platform test(check daemon status as expected)
2020-04-28 18:39:10 -07:00
Prince Sunny
8c43deaa7a Fix docker restapi start issue, undefined error (#4475) 2020-04-27 08:50:23 -07:00
Sujin Kang
c34dcbec4c [fancontrol] Restart process upon unexpected exit, not entire pmon container (#4101)
* fancontrol restart

* Cleanup the default setting for exitcodes

* Remove the unnecessary stopwaitsecs default settin
2020-04-27 06:23:19 +00:00