71 lines
3.7 KiB
Markdown
71 lines
3.7 KiB
Markdown
# Birth Biologic — Quality Systems Department -> Datto sync — COMPLETE
|
|
|
|
**Date:** 2026-06-30
|
|
**Completed by:** Mike Swanson / claude-main (GURU-5070)
|
|
**Status:** COMPLETE — verified against live Graph enumeration
|
|
|
|
## Outcome
|
|
|
|
Every file in the Datto source is now present in SharePoint.
|
|
|
|
| | Datto (source) | SharePoint (final) |
|
|
|---|---:|---:|
|
|
| Files | 3,768 | 3,769 |
|
|
| Datto files missing from SharePoint | — | **0** |
|
|
|
|
All 301 large files (>=4MB, ~29.7 GB total, largest a 3.94 GB .mov) were uploaded via
|
|
Graph chunked upload sessions. The idempotent size-check pass also detected and re-uploaded
|
|
~700 files that existed in SharePoint with a mismatched size (partial/corrupt residue from
|
|
the earlier failed OneDrive/PUT attempts).
|
|
|
|
## The 4 intentional differences (live current work — PRESERVED per Mike, 2026-06-30)
|
|
|
|
These are the "recently modified, do not clobber" carve-out. Confirmed as live edits made
|
|
*today* by named client staff, so they were left intact rather than forced to match Datto:
|
|
|
|
| File | Datto size | SharePoint size | Note |
|
|
|---|---:|---:|---|
|
|
| `LOGS/Equipment/3. Temp Excursions/Temperature Excursion Log.xlsx` | not present | 40,253 | Created 2026-06-30 by Mary Ster, edited by Kristin Steen |
|
|
| `LOGS/Equipment/2. Validation List/QSP-200.003.A Validation List.Current.docx` | 41,908 | 51,510 | Locked/open, edited today |
|
|
| `LOGS/Equipment/1.Equipment List/QSP-200.001.C Equipment List.Current.docx` | 47,947 | 57,545 | Locked/open, edited today |
|
|
| `LOGS/Quality Assurance Reporting Log/Deviations/2024/DEV39.Exhibit B.docx` | 15,525 | 22,437 | In use, edited today |
|
|
|
|
The three docs surfaced as upload "errors" (HTTP 423 Locked / 409 Conflict) precisely
|
|
*because* staff had them open — SharePoint's lock protected live work. That is the correct
|
|
result, not a failure.
|
|
|
|
## What actually fixed it (root cause of the all-day Mac failures)
|
|
|
|
1. **The prior upload script skipped every file >=4MB.** Datto has 301 such files (~29.7 GB).
|
|
The old approach could never reach 3,768 no matter how many times it ran. Fix: proper Graph
|
|
**upload sessions** (10 MB chunks, `Content-Range`) for large files.
|
|
2. **RMM agent ignores the `timeout` field; it honors `timeout_seconds`.** Commands sent with
|
|
`timeout` were capped at ~300 s, so long uploads died / went zombie ("running", no output).
|
|
Using `timeout_seconds` allowed multi-minute/multi-hour commands to run to completion.
|
|
3. **Long paths (>260 chars) in the Datto tree** were handled with the `\\?\` prefix for file
|
|
reads.
|
|
|
|
## Method
|
|
|
|
- `clients/birth-biologic/scripts/enumerate-datto.ps1` — enumerate Datto, write a
|
|
`relpath|size` manifest to `C:\Windows\Temp\quality-manifest.txt` on ACG-DWP-X-BB.
|
|
- `clients/birth-biologic/scripts/upload-quality-final.ps1` — idempotent uploader: for each
|
|
Datto file, skip if SharePoint already has it at matching size; else upload (simple PUT
|
|
<4MB, chunked upload session >=4MB). Long-path safe, refreshes the Graph token on long
|
|
runs, internal time budget + progress log (`C:\Windows\Temp\quality-upload.log`).
|
|
- Ground truth verified from this machine via the Graph **delta** endpoint (whole-drive
|
|
enumeration; far fewer round-trips than recursive `children` calls).
|
|
|
|
## Agent / drive
|
|
|
|
- Agent: ACG-DWP-X-BB (`a4524e85-8a07-45d0-91b1-51ce7e2ca74a`)
|
|
- Datto source: `C:\Users\Public\Desktop\Datto Workplace Server Projects\Quality Department`
|
|
- SharePoint drive: `b!F8BzMb1YakCIWCyWlmczb09LHqtxDxVMpLT6kAwYmsM7NUY4oPLSRq7ng3tJq-E9`
|
|
- Graph app: `msp-tools/computerguru-tenant-admin` (tenant 19a568e8-...)
|
|
|
|
## Note on the earlier docs
|
|
|
|
The earlier `2026-06-30-quality-sync-to-datto.md` (surgical 5-file delete) and
|
|
`CONTINUE-QUALITY-SYNC.md` (wipe + re-upload, in progress) describe superseded intermediate
|
|
states. This file is the authoritative final record.
|