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

[Backport 6.2] fix(ipv6-reboot): ignore Prometheus failures in node init #9535

Merged
merged 1 commit into from
Dec 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions sdcm/nemesis.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@
ignore_raft_transport_failing,
decorate_with_context_if_issues_open,
ignore_take_snapshot_failing,
ignore_ipv6_failure_to_assign,
)
from sdcm.sct_events.health import DataValidatorEvent
from sdcm.sct_events.loaders import CassandraStressLogEvent, ScyllaBenchEvent
Expand Down Expand Up @@ -3874,6 +3875,9 @@ def _run_commands_wait_and_cleanup( # pylint: disable=too-many-arguments
@decorate_with_context([
ignore_ycsb_connection_refused,
])
@decorate_with_context_if_issues_open(
ignore_ipv6_failure_to_assign,
issue_refs=['https://github.com/scylladb/scylladb/issues/20387'])
def reboot_node(self, target_node, hard=True, verify_ssh=True):
target_node.reboot(hard=hard, verify_ssh=verify_ssh)
if self.tester.params.get('print_kernel_callstack'):
Expand Down
16 changes: 16 additions & 0 deletions sdcm/sct_events/group_common_events.py
Original file line number Diff line number Diff line change
Expand Up @@ -474,6 +474,22 @@ def ignore_take_snapshot_failing():
yield


@contextmanager
def ignore_ipv6_failure_to_assign():
with ExitStack() as stack:
stack.enter_context(EventsSeverityChangerFilter(
new_severity=Severity.WARNING,
event_class=DatabaseLogEvent,
regex=r".*init - Startup failed:.*Cannot assign requested address",
extra_time_to_expiration=60))
stack.enter_context(EventsSeverityChangerFilter(
new_severity=Severity.WARNING,
event_class=DatabaseLogEvent,
regex=r".*init - Could not start Prometheus API server.*Cannot assign requested address",
extra_time_to_expiration=60))
yield


def decorate_with_context(context_list: list[Callable | ContextManager] | Callable | ContextManager):
"""
helper to decorate a function to run with a list of callables that return context managers
Expand Down
Loading