ipfs/kubo · error
deprecated configuration detected. Manually migrate 'Provide
Error message
deprecated configuration detected. Manually migrate 'Provider' fields to 'Provide' and remove 'Provider' from your config. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#provide
What it means
validateDaemonConfig detects the removed Provider.* config section (Enabled, Strategy, WorkerCount) after Kubo's automatic migration should have replaced it with Provide.*. It refuses to start so stale keys silently overriding behavior are surfaced, typically caused by external tooling re-injecting old keys.
Source
Thrown at cmd/ipfs/kubo/daemon.go:970
return manet.IP4Loopback.Encapsulate(rest)
case first.Equal(&manet.IP6Unspecified[0]):
return manet.IP6Loopback.Encapsulate(rest)
default:
return maddr // not ip
}
}
func validateDaemonConfig(cfg *config.Config, routingOption string, privateNetwork bool) error {
if privateNetwork && (routingOption == routingOptionAutoKwd || routingOption == routingOptionAutoClientKwd) {
return errors.New("private network does not work with Routing.Type=auto. Update your config to Routing.Type=dht (or none, and do manual peering)")
}
// Check for deprecated Provider/Reprovider configuration after migration.
// This should never happen for regular users, but is useful error for people who have Docker orchestration
// that blindly sets config keys (overriding automatic Kubo migration).
//nolint:staticcheck // intentionally checking deprecated fields
if cfg.Provider.Enabled != config.Default || !cfg.Provider.Strategy.IsDefault() || !cfg.Provider.WorkerCount.IsDefault() {
return errors.New("deprecated configuration detected. Manually migrate 'Provider' fields to 'Provide' and remove 'Provider' from your config. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#provide")
}
//nolint:staticcheck // intentionally checking deprecated fields
if !cfg.Reprovider.Interval.IsDefault() || !cfg.Reprovider.Strategy.IsDefault() {
return errors.New("deprecated configuration detected. Manually migrate 'Reprovider' fields to 'Provide': Reprovider.Strategy -> Provide.Strategy, Reprovider.Interval -> Provide.DHT.Interval. Remove 'Reprovider' from your config. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#provide")
}
if cfg.Provide.Strategy.WithDefault("") == "flat" {
return errors.New("Provide.Strategy='flat' is no longer supported. Use 'all' instead. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#providestrategy")
}
if cfg.Experimental.StrategicProviding {
return errors.New("Experimental.StrategicProviding was removed. Remove it from your config. Documentation: https://github.com/ipfs/kubo/blob/master/docs/experimental-features.md#strategic-providing")
}
if cfg.Provide.DHT.SweepEnabled.WithDefault(config.DefaultProvideDHTSweepEnabled) &&
cfg.Provide.DHT.MaxWorkers.WithDefault(config.DefaultProvideDHTMaxWorkers) == 0 {
return errors.New("invalid configuration: Provide.DHT.MaxWorkers cannot be 0 when Provide.DHT.SweepEnabled=true. Set Provide.DHT.MaxWorkers to a positive value (e.g., 16) to control resource usage. Documentation: https://github.com/ipfs/kubo/blob/master/docs/config.md#providedhtmaxworkers")
}
if routingOption == routingOptionDelegatedKwd && cfg.Provide.Enabled.WithDefault(config.DefaultProvideEnabled) {
return errors.New("Routing.Type=delegated does not support content providing. Set Provide.Enabled=false in your config")
}View on GitHub (pinned to 329838acdf)
Solutions
- Migrate values: Provider.Enabled -> Provide.Enabled, Provider.Strategy -> Provide.Strategy, Provider.WorkerCount -> Provide.DHT.MaxWorkers
- Remove the Provider section: `ipfs config --json Provider '{}'` or edit $IPFS_PATH/config and delete Provider.*
- Update deployment tooling (compose files, env writers, config templates) to only emit Provide.* keys
- Consult docs/config.md#provide for the new option names
Example fix
// before (config.json)
"Provider": { "Enabled": true, "Strategy": "flat" }
// after
"Provide": { "Enabled": true, "Strategy": "all", "DHT": { "MaxWorkers": 16 } }
// and delete the "Provider" section entirely Defensive patterns
Strategy: validation
Validate before calling
// fail fast if legacy Provider keys present cfg="$IPFS_PATH/config" jq -e '.Provider.Enabled != null or .Provider.Strategy != null or .Provider.WorkerCount != null' "$cfg" \ && echo "legacy Provider.* keys present: migrate to Provide.* and delete Provider"
Try / catch
if err := daemonFunc(...); err != nil {
if strings.Contains(err.Error(), "deprecated configuration detected") {
log.Fatalf("migrate Provider->Provide: %v", err)
}
} Prevention
- Use only Provide.* keys in config templates and IaC
- Run `ipfs config show | jq '.Provider'` as a post-upgrade check
- Keep one canonical config source across nodes of all versions
- Read docs/config.md#provide when porting old configs
When it happens
Trigger: `ipfs daemon` when the repo config still contains Provider.Enabled (non-default), Provider.Strategy, or Provider.WorkerCount — e.g. Docker orchestration or scripts that write Provider.* keys, defeating the automatic migration that runs at init/upgrade.
Common situations: Upgrading from an older Kubo while IaC/Docker compose/env-based provisioning keeps writing deprecated Provider fields; configs shared between nodes of mixed versions.
Related errors
- deprecated configuration detected. Manually migrate 'Reprovi
- Provide.Strategy='flat' is no longer supported. Use 'all' in
- Experimental.StrategicProviding was removed. Remove it from
- Provide.DHT.Interval=0 no longer disables the provide system
- The Swarm.ResourceMgr.Limits configuration has been removed
AI-assisted analysis of ipfs/kubo@329838acdf (2026-09-03).
Data as JSON: /api/errors/ab68dc2e1542235f.
Report an issue: GitHub.