diff --git a/dockers/docker-orchagent/orchagent.sh b/dockers/docker-orchagent/orchagent.sh index 45571944db30..f407e266ca2a 100755 --- a/dockers/docker-orchagent/orchagent.sh +++ b/dockers/docker-orchagent/orchagent.sh @@ -69,4 +69,10 @@ else ORCHAGENT_ARGS+="-m $MAC_ADDRESS" fi +# Enable ZMQ for SmartSwitch +LOCALHOST_SUBTYPE=`sonic-db-cli CONFIG_DB hget localhost "subtype"` +if [[ x"${LOCALHOST_SUBTYPE}" == x"SmartSwitch" ]]; then + ORCHAGENT_ARGS+=" -q tcp://127.0.0.1:8100" +fi + exec /usr/bin/orchagent ${ORCHAGENT_ARGS} diff --git a/dockers/docker-sonic-telemetry/telemetry.sh b/dockers/docker-sonic-telemetry/telemetry.sh index c7693adc161b..5f4e38a3aeb2 100755 --- a/dockers/docker-sonic-telemetry/telemetry.sh +++ b/dockers/docker-sonic-telemetry/telemetry.sh @@ -70,6 +70,12 @@ else TELEMETRY_ARGS+=" -v=2" fi +# Enable ZMQ for SmartSwitch +LOCALHOST_SUBTYPE=`sonic-db-cli CONFIG_DB hget localhost "subtype"` +if [[ x"${LOCALHOST_SUBTYPE}" == x"SmartSwitch" ]]; then + TELEMETRY_ARGS+=" -zmq_address=tcp://127.0.0.1:8100" +fi + # Server will handle threshold connections consecutively THRESHOLD_CONNECTIONS=$(echo $GNMI | jq -r '.threshold') if [[ $THRESHOLD_CONNECTIONS =~ ^[0-9]+$ ]]; then