github-actions[bot] commented on issue #12122:
URL: https://github.com/apache/cloudstack/issues/12122#issuecomment-4856145599

   ## ๐ŸŽฏ Triage report
   
   NAS (CIFS/SMB) backups randomly fail on KVM with `umount: target is busy` 
because the CIFS mount point remains in use when the backup script tries to 
unmount it. The script treats any `umount` error as a backup failure, even 
though the actual backup completed successfully. The issue includes a detailed 
root-cause analysis and a proposed shell fix using `fuser` to wait for the 
mount to be released. A PR from the reporter is invited by the maintainer.
   
   ### ๐Ÿ“Š Assessment
   
   | Dimension | Value | Reasoning |
   |---|---|---|
   | **Type** | type:bug | Successful backups are incorrectly reported as 
failures due to a race in unmount logic |
   | **Component** | component:kvm | `nasbackup.sh` KVM hypervisor script |
   | **Severity** | Severity:Major | Backup operations randomly fail in 
production; false-failure causes operators to lose confidence in backup 
integrity |
   | **Labels** | type:bug, component:kvm, Severity:Major | As above |
   | **Coding agent** | Suitable | Root cause confirmed, fix code proposed in 
the issue and refined in comments; self-contained to `nasbackup.sh` |
   
   <details><summary>๐Ÿ’ก Notes and suggestions</summary>
   
   - Affected script: `scripts/vm/hypervisor/kvm/nasbackup.sh` around line 151.
   - Fix: after `virsh domjobinfo` / `du`, poll with `fuser -m $mount_point` 
before attempting `umount`; if still busy after a timeout, log a warning but do 
**not** `exit 1` (backup data is already on the share).
   - Same fix should be applied to `backup_stopped_vm` which also omits the 
unmount step.
   - Consider extracting the unmount-with-retry logic into a shared helper 
function called from both `backup_running_vm` and `backup_stopped_vm`.
   - The CIFS mount opts `soft` + `closetimeo=1` may contribute to the race โ€” 
adding a small sleep after `sync` before unmount could also help.
   
   </details>
   
   
   
   > Generated by [Daily Issue 
Triage](https://github.com/apache/cloudstack/actions/runs/28523943189) ยท 
[โ—ท](https://github.com/search?q=repo%3Aapache%2Fcloudstack+%22gh-aw-workflow-call-id%3A+apache%2Fcloudstack%2Fdaily-issue-triage%22&type=issues)
   >
   <details>
   <summary>Add this agentic workflows to your repo</summary>
   
   To install this agentic workflow, run
   
   ```
   gh aw add 
githubnext/agentics/workflows/daily-issue-triage.md@d7c1dc4b72b00607a67caaffdcc216cb64379cf9
   ```
   </details>
   
   
   <!-- gh-aw-agentic-workflow: Daily Issue Triage, engine: copilot, version: 
1.0.52, model: claude-sonnet-4.6, id: 28523943189, workflow_id: 
daily-issue-triage, run: 
https://github.com/apache/cloudstack/actions/runs/28523943189 -->
   <!-- gh-aw-workflow-call-id: apache/cloudstack/daily-issue-triage -->


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to