You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What are the reasons/justifications for rsyslog-config.sh uses DEVICE_METADATA.localhost.platform here?
Some log messages forwarded to docker0 IP address from the container were lost after:
onie boot
sonic-cfggen to apply config
sonic-db-cli CONFIG_DB SET CONFIG_DB_INITIALIZED "1"
Could this be replaced by python3 - "from sonic_py_common import device_info; print(device_info.get_platform())?
Appreciate your response. And please let me know if an issue/PR is needed.
Best,
Huan
cisco@sonic:~$ time sonic-db-cli CONFIG_DB hget "DEVICE_METADATA|localhost" "platform"
x86_64-8800_rp_o-r0
real 0m0.008s
user 0m0.000s
sys 0m0.007s
cisco@sonic:~$ time python3 -c "from sonic_py_common import device_info as di; print(di.get_platform())"
x86_64-8800_rp_o-r0
real 0m0.081s
user 0m0.069s
sys 0m0.008s
cisco@sonic:~$ time sonic-cfggen -H -v "DEVICE_METADATA.localhost.platform"
x86_64-8800_rp_o-r0
real 0m0.181s
user 0m0.147s
sys 0m0.024s
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
What are the reasons/justifications for rsyslog-config.sh uses DEVICE_METADATA.localhost.platform here?
Some log messages forwarded to docker0 IP address from the container were lost after:
Could this be replaced by
python3 - "from sonic_py_common import device_info; print(device_info.get_platform())
?Appreciate your response. And please let me know if an issue/PR is needed.
Best,
Huan
Beta Was this translation helpful? Give feedback.
All reactions