← Problem log

Every upload failed with a 501, but the uploads worked

Last verified Nov 11
By the Bluhook team · Updated Nov 12, 2026

1What happened

Kai (video) hit it and fixed it.

Our video AI agent keeps its work files in cloud storage, so the computer it runs on doesn't fill up. It moved a folder of video work, about 24 GB, to Cloudflare R2 with rclone.

Every file failed with the same error: "Failed to copy: NotImplemented: Not Implemented, status code: 501". rclone retried each file and got the same 501 every time.

Why it happened

Kai turned on rclone's header dump (--dump headers) to see each request. The upload itself (the PUT) came back 200 OK. The file was in storage.

The 501 came from the next step. After each upload, rclone (v1.60.1) sends a HEAD request with a ?versionId= on the end, to read back the file it just wrote. R2 doesn't support that request and answers 501. rclone took that as a failed copy and tried again.

What we tried first

A small test upload had passed on its second try, so the setup looked fine. The first full run had retries turned on, and 58 files still failed in under a minute.

2What we did

  1. Add --s3-no-head to the rclone command. It skips the follow-up lookup.

  2. Check the copy afterward with rclone check --one-way, which compares every file in storage with the local copy.

  3. Only then clear local space, with rclone move --checksum --min-age 7d. It deletes a local file only after its checksum matches the copy in storage.

3How we checked

The rerun finished with 0 errors. rclone check found 0 differences across 18,716 files (23.85 GiB). The cleanup then removed 4,926 older local files, freed 3.84 GB, and hit 0 errors.

4Try it

When a tool says every upload failed, look at the raw requests before you blame the upload. Here the upload worked and only the follow-up check failed. And a test that only passes on its second try needs a closer look before you run the full job.

storagevideoAI agentsPublished Nov 12

Your free AI evaluation

Six free minutes with Sam. Your top 3 jobs for AI land in your inbox.

Show me my top 3 jobs

Keep reading

Robb Lejuwaan

Every practical lesson, the wins and the flops, goes into Robb on AI, a free email newsletter.

Robb Lejuwaan, writer of Robb on AI
Get Robb on AI, free

Every lesson, win and flop, by email. Opens Substack.

Robb on AI is our free newsletter, written by Robb Lejuwaan.

We'll add you to Robb on AI, our free newsletter on Substack. Unsubscribe anytime. Privacy policy