Skip to content
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

CLI to show 'system ready' message when the system is ready take config commands #693

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

Kalimuthu-Velappan
Copy link
Contributor

@Kalimuthu-Velappan Kalimuthu-Velappan commented Oct 4, 2019

- What I did
Support for System ready message:

New CLI command to show that the system is ready to handle the config commands.

   root# show system status

- How I did it

Added support in the show utilities to read all the core service status and port init status. If both are up, then print a �message that 'system is ready', else 'system is not ready'

- How to verify it

 root@sonic:/home/admin# show system status
  System is not ready - Core services are not up
       swss : Up
       bgp : Up
       teamd : Down
       pmon : Up
       syncd : Up
       database : Up
  root@sonic:/home/admin# show system status
       System is not ready - Ports are not up

  root@sonic:/home/admin# show system status
  System is ready

- Previous command output (if the output of a command-line utility has changed)

- New command output (if the output of a command-line utility has changed)

-->

@Kalimuthu-Velappan Kalimuthu-Velappan marked this pull request as ready for review October 11, 2019 10:03
@Kalimuthu-Velappan Kalimuthu-Velappan changed the title Systemready Print 'system ready' syslog message when the system is ready take config commands Oct 22, 2019
@Kalimuthu-Velappan Kalimuthu-Velappan changed the title Print 'system ready' syslog message when the system is ready take config commands CLI to show 'system ready' message when the system is ready take config commands Oct 22, 2019
Comment on lines +11 to +12
import logging
import swsssdk
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These modules are not used. Remove?

@@ -1579,5 +1589,134 @@ def del_ntp_server(ctx, ntp_ip_address):
except SystemExit as e:
ctx.fail("Restart service ntp-config failed with error {}".format(e))

g_ext_cfg = {}

@config.group('export', invoke_without_command=False)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This 'export' group does not appear to be relevant to the 'system ready' changes as stated in the PR title and description. Can these be removed and a separate PR created for them?

@Kalimuthu-Velappan
Copy link
Contributor Author

I will resubmit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants