{"record":{"id":"f9ab95a0c4131e80","repo":"juicedata/juicefs","slug":"1-all-objects-in-the-data-storage-s","errorCode":null,"errorMessage":"1. ALL objects in the data storage: %s","messagePattern":"1\\. ALL objects in the data storage: (.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"cmd/destroy.go","lineNumber":154,"sourceCode":"\t\t\tlogger.Fatalf(\"list sessions: %s\", err)\n\t\t}\n\t\tif num := len(sessions); num > 0 {\n\t\t\tss := make([][3]string, num)\n\t\t\tfor i, s := range sessions {\n\t\t\t\tss[i] = [3]string{strconv.FormatUint(s.Sid, 10), s.HostName, s.MountPoint}\n\t\t\t}\n\t\t\tlogger.Fatalf(\"%d sessions are active, please disconnect them first:\\n%s\", num, printSessions(ss))\n\t\t}\n\t\tvar totalSpace, availSpace, iused, iavail uint64\n\t\t_ = m.StatFS(meta.Background(), meta.RootInode, &totalSpace, &availSpace, &iused, &iavail)\n\n\t\tfmt.Printf(\" volume name: %s\\n\", format.Name)\n\t\tfmt.Printf(\" volume UUID: %s\\n\", format.UUID)\n\t\tfmt.Printf(\"data storage: %s\\n\", blob)\n\t\tfmt.Printf(\"  used bytes: %d\\n\", totalSpace-availSpace)\n\t\tfmt.Printf(\" used inodes: %d\\n\", iused)\n\t\twarn(\"The target volume will be permanently destroyed, including:\")\n\t\twarn(\"1. ALL objects in the data storage: %s\", blob)\n\t\twarn(\"2. ALL entries in the metadata engine: %s\", utils.RemovePassword(uri))\n\t\tif !ctx.Bool(\"yes\") && !userConfirmed() {\n\t\t\tlogger.Fatalln(\"Aborted.\")\n\t\t}\n\t}\n\n\tobjs, err := object.ListAll(ctx.Context, blob, \"\", \"\", true, false)\n\tif err != nil && strings.Contains(err.Error(), \"NoSuchBucket\") {\n\t\tif !ctx.Bool(\"force\") {\n\t\t\tlogger.Fatalf(\"data storage %s does not exist (error: %v); retry with \\\"--force\\\" to skip object deletion\", blob, err)\n\t\t}\n\t\tlogger.Warnf(\"data storage %s does not exist (error: %v); will skip object deletion\", blob, err)\n\t} else {\n\t\tif err != nil {\n\t\t\tlogger.Fatalf(\"list all objects: %s\", err)\n\t\t}\n\t\tprogress := utils.NewProgress(false)\n\t\tspin := progress.AddCountSpinner(\"Deleted objects\")","sourceCodeStart":136,"sourceCodeEnd":172,"githubUrl":"https://github.com/juicedata/juicefs/blob/c9a67b23e8e08ec23ec331aa6f1675e2319e921c/cmd/destroy.go#L136-L172","documentation":"First item of the 'juicefs destroy' destruction summary: it warns that ALL objects under the volume's data storage prefix (blob URL) will be deleted. This includes every file chunk, slice reference, and internal object written by the client.","triggerScenarios":"The confirmation output of 'juicefs destroy META UUID' listing the object storage bucket/prefix that will be wiped.","commonSituations":"Shared buckets holding multiple volumes — a careless destroy deletes objects of the destroyed volume only, but operators must confirm the listed blob path is the intended one (especially with shared buckets and prefixes).","solutions":["Check the printed blob URL matches the intended bucket/prefix before confirming","If other volumes share the bucket, verify prefix isolation is correct","Cancel (answer no) and re-verify with 'juicefs status' if the storage URL looks wrong"],"exampleFix":"// before (destroying without checking blob)\njuicefs destroy $META $UUID --yes\n// after (inspect storage first)\njuicefs status $META | grep -i storage && juicefs destroy $META $UUID","handlingStrategy":"validation","validationCode":"st, _ := juicefsStatus(metaURI)\nif st.Storage != expectedBlobURL { abort() } // verify storage target matches","typeGuard":null,"tryCatchPattern":"if strings.Contains(out, \"ALL objects in the data storage\") && !verifiedBlob { cancel() }","preventionTips":["Check the printed blob URL, especially with shared buckets and prefixes","Confirm bucket/prefix ownership before confirming destruction","Snapshot or inventory the bucket if unsure"],"tags":["cli","destructive","object-storage"],"backgroundTag":"destructive-operation-confirmation","analyzedSha":"c9a67b23e8e08ec23ec331aa6f1675e2319e921c","analyzedAt":"2026-09-06T17:55:48.476Z","contentChangedAt":"2026-09-06T17:55:48.476Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}