{"record":{"id":"b1450eeae00fa274","repo":"juicedata/juicefs","slug":"list-quotas","errorCode":null,"errorMessage":"list quotas","messagePattern":"list quotas","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cmd/config.go","lineNumber":482,"sourceCode":"\t\t\t\tformat.Inodes > 0 && iused >= format.Inodes {\n\t\t\t\twarn(\"New quota is too small (used / quota): %d / %d bytes, %d / %d inodes.\",\n\t\t\t\t\tusedSpace, format.Capacity, iused, format.Inodes)\n\t\t\t\tif !yes && !userConfirmed() {\n\t\t\t\t\treturn fmt.Errorf(\"Aborted.\")\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif trash && format.TrashDays == 0 {\n\t\t\twarn(\"The current trash will be emptied and future removed files will purged immediately.\")\n\t\t\tif !yes && !userConfirmed() {\n\t\t\t\treturn fmt.Errorf(\"Aborted.\")\n\t\t\t}\n\t\t}\n\t\tif originDirStats && !format.DirStats {\n\t\t\tqs := make(map[string]*meta.Quota)\n\t\t\terr := m.HandleQuota(meta.Background(), meta.QuotaList, \"\", meta.DirQuotaType, qs, false, false, false)\n\t\t\tif err != nil {\n\t\t\t\treturn errors.Wrap(err, \"list quotas\")\n\t\t\t}\n\t\t\tif len(qs) != 0 {\n\t\t\t\tpaths := make([]string, 0, len(qs))\n\t\t\t\tfor path := range qs {\n\t\t\t\t\tpaths = append(paths, path)\n\t\t\t\t}\n\t\t\t\treturn fmt.Errorf(\"cannot disable dir stats when there are still %d dir quotas: %v\", len(qs), paths)\n\t\t\t}\n\t\t}\n\t\tif clientVer {\n\t\t\tconfirmClientVer := false\n\t\t\tif format.CheckVersion() != nil {\n\t\t\t\twarn(\"Clients below version %s will be rejected after modification.\", format.MinClientVersion)\n\t\t\t\tconfirmClientVer = true\n\t\t\t}\n\n\t\t\t// check all clients\n\t\t\tif sessions, err := m.ListSessions(); err == nil {","sourceCodeStart":464,"sourceCodeEnd":500,"githubUrl":"https://github.com/juicedata/juicefs/blob/c9a67b23e8e08ec23ec331aa6f1675e2319e921c/cmd/config.go#L464-L500","documentation":"Returned by `juicefs config` when listing directory quotas fails while dir-stats is being disabled (or quota-related reconfiguration). The wrapped meta.HandleQuota error aborts the config update because quota state could not be safely read or migrated.","triggerScenarios":"Thrown at cmd/config.go:482 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Check metadata engine connectivity, then retry the config command","Manually inspect quotas with `juicefs quota list` and clean up before disabling dir-stats"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"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"}