Skip to content

Commit 5bb9956

Browse files
authored
Revert "add support for MCLAG (#453)"
This reverts commit 8aea564.
1 parent 6f54e8c commit 5bb9956

File tree

2 files changed

+0
-59
lines changed

2 files changed

+0
-59
lines changed

config/main.py

-41
Original file line numberDiff line numberDiff line change
@@ -409,14 +409,6 @@ def _abort_if_false(ctx, param, value):
409409
if not value:
410410
ctx.abort()
411411

412-
def _get_optional_services():
413-
config_db = ConfigDBConnector()
414-
config_db.connect()
415-
optional_services_dict = config_db.get_table('FEATURE')
416-
if not optional_services_dict:
417-
return None
418-
return optional_services_dict.keys()
419-
420412
def _stop_services():
421413
# on Mellanox platform pmon is stopped by syncd
422414
services_to_stop = [
@@ -447,17 +439,6 @@ def _stop_services():
447439
log_error("Stopping {} failed with error {}".format(service, e))
448440
raise
449441

450-
# For optional services they don't start by default
451-
for service in _get_optional_services():
452-
(out, err) = run_command("systemctl status {}".format(service), return_output = True)
453-
if not err and 'Active: active (running)' in out:
454-
try:
455-
click.echo("Stopping service {} ...".format(service))
456-
run_command("systemctl stop {}".format(service))
457-
except SystemExit as e:
458-
log_error("Stopping {} failed with error {}".format(service, e))
459-
raise
460-
461442
def _reset_failed_services():
462443
services_to_reset = [
463444
'bgp',
@@ -493,17 +474,6 @@ def _reset_failed_services():
493474
log_error("Failed to reset failed status for service {}".format(service))
494475
raise
495476

496-
# For optional services they don't start by default
497-
for service in _get_optional_services():
498-
(out, err) = run_command("systemctl is-enabled {}".format(service), return_output = True)
499-
if not err and 'enabled' in out:
500-
try:
501-
click.echo("Resetting failed status for service {} ...".format(service))
502-
run_command("systemctl reset-failed {}".format(service))
503-
except SystemExit as e:
504-
log_error("Failed to reset failed status for service {}".format(service))
505-
raise
506-
507477
def _restart_services():
508478
# on Mellanox platform pmon is started by syncd
509479
services_to_restart = [
@@ -538,17 +508,6 @@ def _restart_services():
538508
log_error("Restart {} failed with error {}".format(service, e))
539509
raise
540510

541-
# For optional services they don't start by default
542-
for service in _get_optional_services():
543-
(out, err) = run_command("systemctl is-enabled {}".format(service), return_output = True)
544-
if not err and 'enabled' in out:
545-
try:
546-
click.echo("Restarting service {} ...".format(service))
547-
run_command("systemctl restart {}".format(service))
548-
except SystemExit as e:
549-
log_error("Restart {} failed with error {}".format(service, e))
550-
raise
551-
552511
def is_ipaddress(val):
553512
""" Validate if an entry is a valid IP """
554513
if not val:

scripts/fast-reboot

-18
Original file line numberDiff line numberDiff line change
@@ -430,24 +430,6 @@ debug "Stopped bgp ..."
430430
docker kill lldp &> /dev/null || debug "Docker lldp is not running ($?) ..."
431431
systemctl stop lldp
432432
433-
if [[ "$REBOOT_TYPE" = "fast-reboot" ]]; then
434-
if echo $(docker ps) | grep -q iccpd; then
435-
docker kill iccpd > /dev/null || [ $? == 1 ]
436-
fi
437-
fi
438-
439-
# Stop iccpd gracefully
440-
if [[ "$REBOOT_TYPE" = "warm-reboot" || "$REBOOT_TYPE" = "fastfast-reboot" ]]; then
441-
if echo $(docker ps) | grep -q iccpd; then
442-
debug "Stopping iccpd ..."
443-
# Send USR1 signal to iccpd to stop it
444-
# It will prepare iccpd for warm-reboot
445-
# Note: We must send USR1 signal before syncd, or some state of iccpd maybe lost
446-
docker exec -i iccpd pkill -USR1 iccpd || [ $? == 1 ] > /dev/null
447-
debug "Stopped iccpd ..."
448-
fi
449-
fi
450-
451433
if [[ "$REBOOT_TYPE" = "fast-reboot" ]]; then
452434
# Kill teamd processes inside of teamd container with SIGUSR2 to allow them to send last LACP frames
453435
# We call `docker kill teamd` to ensure the container stops as quickly as possible,

0 commit comments

Comments
 (0)