-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support building multi-ASIC components #3269
Support building multi-ASIC components #3269
Conversation
* indicate 'virsh' should be run as sudo * add instructions to get DHCP lease for SSH connections Signed-off-by: Lawrence Lee <[email protected]>
* prepare slave.mk to build multi-asic services * move systemd services into single and multi instance folders * prepare sonic_debian_extension to copy over single and multi instance services * detect single or multi-asic platform in systemd-sonic-generator and enable correct services Signed-off-by: Lawrence Lee <[email protected]>
…ulti-instance container support [build_templates]: * add network namespace creation/linking to docker_image_ctl.j2 * add support for multi-instance containers to docker_image_ctl.j2 * add support for hostnames in multi-asic containers * don't try and copy single instance version of namespace service in sonic_debian_extension [rules]: * add rule for creating network namespace docker * removes "--net=host" from DOCKER_RUN_OPTS in all other docker rules (it now lives in docker_image_ctl.j2) [build]: * retry docker build without squashing if squashing fails [platform/vs]: add network interfaces to virtual switch * add 32 more network interfaces, for a total of 64 Signed-off-by: Lawrence Lee <[email protected]>
* add script to configure virtual switch internal topology * create service to manage topology * install topology service in sonic_debian_extension Signed-off-by: Lawrence Lee <[email protected]>
@@ -0,0 +1,2 @@ | |||
FROM debian:stretch |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do we need this docker?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can use the database as the namespace container, all other containers will use the same namespace as the database container. we do not need a separate namespace container.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have this since I start the namespaces, then the topology service is started, then the other containers start. I wanted to have the topology set up before any SONiC containers were started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
topology service is only required for kvm image. it is not necessary to have topology build before all containers start. We can build topology after database docker started. in fact, the bgp session will not be able to setup until host interfaces are created.
the only hard requirement I see is that the peer links has to be start before the syncd docker starts. since syncd will link the peer device with the host interface.
--build-arg frr_user_uid=$(FRR_USER_UID) \ | ||
--build-arg frr_user_gid=$(FRR_USER_GID) \ | ||
--label Tag=$(SONIC_GET_VERSION) \ | ||
-t $* $($*.gz_PATH) $(LOG) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why this change?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is needed if we want to keep the namespace container, since the docker build fails when it tries to squash the container
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so, it is tight to namespace container, let me resolve this in the conversation above.
@@ -12,10 +12,12 @@ | |||
#define MAX_NUM_TARGETS 5 | |||
#define MAX_NUM_INSTALL_LINES 5 | |||
#define MAX_NUM_UNITS 128 | |||
#define NUM_ASICS 6 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why hard code here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not really sure how else to get this information to the generator - later on it can probably read from a file somewhere.
@@ -0,0 +1,13 @@ | |||
DOCKER_NAMESPACE = docker-namespace.gz |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should remove this file
* remove extra line from slave.mk * change namespace names to 'asic#' Signed-off-by: Lawrence Lee <[email protected]>
* use 'asic' as namespace prefix instead of 'namespace' in accordance with PR sonic-net#3269 Signed-off-by: Lawrence Lee <[email protected]>
* use 'asic' as namespace prefix instead of 'namespace' in accordance with PR #3269 Signed-off-by: Lawrence Lee <[email protected]> (cherry picked from commit c1444e3)
…lly (sonic-net#20457) #### Why I did it src/sonic-swss ``` * 766e7553 - (HEAD -> master, origin/master, origin/HEAD) Fix port up/bfd sessions bringup notification delay issue. (sonic-net#3269) (35 hours ago) [Hua Liu] ``` #### How I did it #### How to verify it #### Description for the changelog
…lly (#20499) #### Why I did it src/sonic-swss ``` * b0ed969c - (HEAD -> 202405, origin/202405) Fix portmgr write partial port config to app DB issue. (#3304) (7 hours ago) [Hua Liu] * b4e04631 - Fix port up/bfd sessions bringup notification delay issue. (#3269) (7 hours ago) [Hua Liu] * 7ac0d4fc - Fix the issue where the test case randomly fails due to not waiting after updating the config DB. (#3323) (11 hours ago) [Hua Liu] ``` #### How I did it #### How to verify it #### Description for the changelog
…lly (sonic-net#20457) #### Why I did it src/sonic-swss ``` * 766e7553 - (HEAD -> master, origin/master, origin/HEAD) Fix port up/bfd sessions bringup notification delay issue. (sonic-net#3269) (35 hours ago) [Hua Liu] ``` #### How I did it #### How to verify it #### Description for the changelog
- What I did
- How to verify it
Build should succeed - running the image on a single-ASIC platform should perform normally.
- Description for the changelog
- A picture of a cute animal (not mandatory but encouraged)