-
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
sonic-installer does not work when there is no database running #10434
Comments
@prsunny the above mentioned PR is not a fix for this issue |
sonic installer import utilities_common.cli because it need use following class: However the global variable iface_alias_converter in utilities_common.cli will connect to config db when initialize. But actually this global variable is not necessary, because most place outside this file using this class will create a new instance. |
PR for this issue: sonic-net/sonic-utilities#2183 |
…cker not running issue. (#2183) Fix sonic-installer and 'show version' command crash when database docker not running issue. #### Description Global variable utilies_common.cli.iface_alias_converter will connect to config DB when initialize itself. If database docker not running, the initialize code will crash. To fix this issue, change the variable to lazy initialize variable with lazy_object_proxy. #### Motivation and Context Fix this issue: sonic-net/sonic-buildimage#10434 #### How Has This Been Tested? Pass all UT and sonic-buildimage E2E test. #### Additional Information (Optional)
Fixed by sonic-net/sonic-utilities#2183 |
…cker not running issue. (#2183) Fix sonic-installer and 'show version' command crash when database docker not running issue. #### Description Global variable utilies_common.cli.iface_alias_converter will connect to config DB when initialize itself. If database docker not running, the initialize code will crash. To fix this issue, change the variable to lazy initialize variable with lazy_object_proxy. #### Motivation and Context Fix this issue: sonic-net/sonic-buildimage#10434 #### How Has This Been Tested? Pass all UT and sonic-buildimage E2E test. #### Additional Information (Optional)
…cker not running issue. (#2183) Fix sonic-installer and 'show version' command crash when database docker not running issue. #### Description Global variable utilies_common.cli.iface_alias_converter will connect to config DB when initialize itself. If database docker not running, the initialize code will crash. To fix this issue, change the variable to lazy initialize variable with lazy_object_proxy. #### Motivation and Context Fix this issue: sonic-net/sonic-buildimage#10434 #### How Has This Been Tested? Pass all UT and sonic-buildimage E2E test. #### Additional Information (Optional)
Description
sonic-installer
andshow version
commands don't work when there is no database running.These utilities should be working regardless of database state.
If there is an issue in the image with the database it won't be possible to reinstall the image.
Steps to reproduce the issue:
docker ps -q
Describe the results you received:
Describe the results you expected:
sonic-installer and show version working properly when there is no connection to the database.
Output of
show version
:Output of
show techsupport
:Additional information you deem important (e.g. issue happens only occasionally):
The text was updated successfully, but these errors were encountered: