Skip to content

RDKB-64864: [Sprint][Automation] syscfg_recover.sh is not present in crontab - #415

Merged
snayak002c merged 2 commits into
developfrom
topic/RDKB-64864_1
Sep 17, 2026
Merged

snayak002c merged 2 commits into
developfrom
topic/RDKB-64864_1

Conversation

@JESTINJM

@JESTINJM JESTINJM commented Sep 14, 2026

Copy link
Copy Markdown
Contributor

RDKB-64864: [Sprint][Automation] syscfg_recover.sh is not present in crontab

Reason for change: Made changes to ensure resource_monitor_recover.sh is added to crontab

Test Procedure:
Verification of resource_monitor_recover script entry in CRONTAB.

Risks: Low
Priority: P1

Corresponding changes in PR rdkcentral/test-and-diagnostic#244

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

Ensure the recovery entry is added to existing crontabs without duplication.

Get a fresh assessment by requesting another Copilot review.

Pull request overview

Adds a five-minute resource_monitor_recover.sh cron job to improve recovery monitoring.

Changes:

  • Adds the recovery script to the generated crontab.
  • Keeps the existing recovery scheduling configuration.
File summaries
File Summary
source/scripts/init/service.d/service_crond.sh The cron entry may not be added when the existing crontab setup bypasses the initialization guard.
Review details
  • Files reviewed: 1/1 changed files
  • Comments generated: 1
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread source/scripts/init/service.d/service_crond.sh Outdated
Copilot AI review requested due to automatic review settings September 15, 2026 12:28
…crontab

Reason for change:  Made changes to ensure resource_monitor_recover.sh is
added to crontab

Test Procedure:
Verification of resource_monitor_recover script entry in CRONTAB.
Tested in both cron and non-cron mode.

Risks: Low
Priority: P1
Signed-off-by: jmathe064 <Jestin_Mathew@comcast.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approval recommended

No blocking issues were identified in the reviewed changes.

Review details
  • Files reviewed: 1/1 changed files
  • Comments generated: 0 new
  • Review effort level: Lite

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🔵 Needs a closer look

Recovery entries do not reliably repair existing crontabs, and the syscfg recovery requirement is not implemented.

Review details

Suppressed comments (2)

source/scripts/init/service.d/service_crond.sh:196

  • This fi still leaves both recovery entries inside the outer initialization guard at line 66. If $CRONTAB_FILE already exists—which is precisely the case for devices whose existing crontab is missing this entry—the body containing these echo commands is skipped, so the change never repairs that crontab. Add the recovery rules through an idempotent path that runs for existing crontabs as well (without duplicating them).
      fi

source/scripts/init/service.d/service_crond.sh:196

  • The syscfg_recover.sh echo at line 204 is outside the self-heal conditional in both versions and is unchanged; moving this fi only changes whether resource_monitor_recover.sh is emitted. If the PR title's syscfg-recovery issue is the intended requirement, this diff does not implement that behavior.
      fi
  • Files reviewed: 1/1 changed files
  • Comments generated: 0 new
  • Review effort level: Lite

Copilot AI review requested due to automatic review settings September 17, 2026 16:04

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

Existing crontabs may still not receive the recovery entry because the code remains behind the one-time initialization guard.

Get a fresh assessment by requesting another Copilot review.

Review details

Suppressed comments (1)

source/scripts/init/service.d/service_crond.sh:196

  • This relocation still leaves the recovery-job echo inside the one-time initialization guard at line 66 (if [ ! -e $CRONTAB_FILE ] || [ ! -e /etc/cron/cron.monthly ]). On an existing device whose crontab lacks this entry, that guard is false, so this code is skipped and the missing job is never added. Please make the entry (and the syscfg entry) idempotently ensured on every start, or extend the guard to detect missing entries.
      fi
  • Files reviewed: 1/1 changed files
  • Comments generated: 1
  • Review effort level: Lite


else
echo_t "Selfheal cron is disabled"
fi
snayak002c added a commit to rdkcentral/test-and-diagnostic that referenced this pull request Sep 17, 2026
…crontab (#244)

RDKB-64864: [Sprint][Automation] syscfg_recover.sh is not present in
crontab

Reason for change: Made changes to ensure resource_monitor_recover.sh is
added to crontab

Test Procedure:
Verification of resource_monitor_recover script entry in CRONTAB.

Risks: Low
Priority: P1

Corresponding changes in PR
rdkcentral/utopia#415

Signed-off-by: jmathe064 <Jestin_Mathew@comcast.com>
Co-authored-by: jmathe064 <Jestin_Mathew@comcast.com>
Co-authored-by: Santosh Nayak <70348540+snayak002c@users.noreply.github.com>
@snayak002c
snayak002c merged commit 5f0834b into develop Sep 17, 2026
12 of 13 checks passed
@github-actions github-actions Bot locked and limited conversation to collaborators Sep 17, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants