-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
ONEImage - Read all platform dependent information from sonic-config-engine #238
Changes from all commits
7e871f3
f109ce3
42a7276
a5e1fa6
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,32 +25,28 @@ trap clean_up SIGTERM SIGKILL | |
|
||
. /host/machine.conf | ||
|
||
HWSKU=`sonic-cfggen -m /etc/sonic/minigraph.xml -v minigraph_hwsku` | ||
|
||
MAC_ADDRESS=`ip link show eth0 | grep ether | awk '{print $2}'` | ||
|
||
ORCHAGENT_ARGS="" | ||
|
||
PORTSYNCD_ARGS="" | ||
PORTSYNCD_ARGS="-p /usr/share/sonic/$HWSKU/port_config.ini" | ||
|
||
SWSSCONFIG_ARGS="00-copp.config.json " | ||
|
||
if [ "$onie_platform" == "x86_64-dell_s6000_s1220-r0" ]; then | ||
if [ "$HWSKU" == "Force10-S6000" ]; then | ||
ORCHAGENT_ARGS+="-m $MAC_ADDRESS" | ||
PORTSYNCD_ARGS+="-p /etc/ssw/Force10-S6000/port_config.ini" | ||
SWSSCONFIG_ARGS+="td2.32ports.qos.1.json td2.32ports.qos.2.json td2.32ports.qos.3.json td2.32ports.qos.4.json td2.32ports.qos.5.json td2.32ports.qos.6.json " | ||
SWSSCONFIG_ARGS+="td2.32ports.buffers.1.json td2.32ports.buffers.2.json td2.32ports.buffers.3.json " | ||
elif [ "$onie_platform" == "x86_64-dell_s6100_c2538-r0" ]; then | ||
elif [ "$HWSKU" == "Force10-S6100" ]; then | ||
ORCHAGENT_ARGS+="-m $MAC_ADDRESS" | ||
PORTSYNCD_ARGS+="-p /etc/ssw/Force10-S6100/port_config.ini" | ||
elif [ "$aboot_platform" == "x86_64-arista_7050_qx32" ]; then | ||
elif [ "$HWSKU" == "Arista-7050-QX32" ]; then | ||
ORCHAGENT_ARGS+="-m $MAC_ADDRESS" | ||
PORTSYNCD_ARGS+="-p /etc/ssw/Arista-7050-QX32/port_config.ini" | ||
SWSSCONFIG_ARGS+="td2.32ports.qos.1.json td2.32ports.qos.2.json td2.32ports.qos.3.json td2.32ports.qos.4.json td2.32ports.qos.5.json td2.32ports.qos.6.json " | ||
SWSSCONFIG_ARGS+="td2.32ports.buffers.1.json td2.32ports.buffers.2.json td2.32ports.buffers.3.json " | ||
elif [ "$onie_platform" == "x86_64-mlnx_x86-r5.0.1400" ] || [ "$onie_platform" == "x86_64-mlnx_msn2700-r0" ]; then | ||
PORTSYNCD_ARGS+="-p /etc/ssw/ACS-MSN2700/port_config.ini" | ||
elif [ "$onie_platform" == "x86_64-accton_as7512_32x-r0" ]; then | ||
elif [ "$HWSKU" == "AS7512" ]; then | ||
ORCHAGENT_ARGS+="-m $MAC_ADDRESS" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @taoyl-ms why mlnx platform is removed? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Because nothing special is needed to do with it. port_config is done in line 34. In reply to: 99408908 [](ancestors = 99408908) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think we could also move ORCHAGENT_ARGS+="-m $MAC_ADDRESS" out of the if statement. We could do it later. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I didn't do that because I didn't see that line in MLNX platform. Was not sure whether it is OK to add it. In reply to: 99411855 [](ancestors = 99411855) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I see. it makes the file a little bit confusion because for now we don't have a full list of supported SKUs here. |
||
PORTSYNCD_ARGS+="-p /etc/ssw/AS7512/port_config.ini" | ||
fi | ||
|
||
service rsyslog start | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
SONiC Software Version: {{ sonic_baseimage_version}}.SONiC.{{ sonic_version }} - HwSku: {{ minigraph_hwsku }} | ||
SONiC Software Version: {{ build_version }}.SONiC.v2 - HwSku: {{ minigraph_hwsku }} - Distribution: Debian {{ debian_version }} - Kernel: {{ kernel_version }} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
build_version: {{git_revision}} | ||
build_hwsku: {{sonic_hwsku}} | ||
debian_version: {{debian_version}} | ||
kernel_version: {{kernel_version}} |
This file was deleted.
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,33 @@ | ||
# TODO: Add correct info here | ||
# alias lanes | ||
Ethernet0 16,17,18,19 | ||
Ethernet4 20,21,22,23 | ||
Ethernet8 24,25,26,27 | ||
Ethernet12 28,29,30,31 | ||
Ethernet16 32,33,34,35 | ||
Ethernet20 36,37,38,39 | ||
Ethernet24 40,41,42,43 | ||
Ethernet28 44,45,46,47 | ||
Ethernet32 0,1,2,3 | ||
Ethernet36 4,5,6,7 | ||
Ethernet40 8,9,10,11 | ||
Ethernet44 12,13,14,15 | ||
Ethernet48 48,49,50,51 | ||
Ethernet52 52,53,54,55 | ||
Ethernet56 56,57,58,59 | ||
Ethernet60 60,61,62,63 | ||
Ethernet64 127,126,125,124 | ||
Ethernet68 123,122,121,120 | ||
Ethernet72 115,114,113,112 | ||
Ethernet76 119,118,117,116 | ||
Ethernet80 79,78,77,76 | ||
Ethernet84 75,74,73,72 | ||
Ethernet88 64,65,66,67 | ||
Ethernet92 71,70,68,69 | ||
Ethernet96 111,110,109,108 | ||
Ethernet100 107,106,105,104 | ||
Ethernet104 103,102,101,100 | ||
Ethernet108 99,98,97,96 | ||
Ethernet112 95,94,93,92 | ||
Ethernet116 91,90,89,88 | ||
Ethernet120 87,86,85,84 | ||
Ethernet124 83,82,81,80 |
This file was deleted.
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.
@taoyl-ms do we need to remove them after the configurations are generated?
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' don't really have a timing to remove them (as config is done upon entrypoint).
And leaving them there will give us the potential to update config later.
In reply to: 99409145 [](ancestors = 99409145)
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.
for each docker to install this, around how large will the packages occupy? some platforms have very limited space.
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.
several mega each. We have discussed about putting those into docker-base, and the decision is to keep it as it is by now and find workaround later if needed.
In reply to: 99411007 [](ancestors = 99411007)