{"record":{"id":"5568fe8d760d6da9","repo":"ipfs/kubo","slug":"unable-to-initialize-libp2p-due-to-conflicting-re","errorCode":null,"errorMessage":"\nUnable to initialize libp2p due to conflicting resource manager limit configuration.\nresource manager System.Conns (%d) must be bigger than ConnMgr.HighWater (%d)\nSee: https://github.com/ipfs/kubo/blob/master/docs/libp2p-resource-management.md#how-does-the-resource-manager-resourcemgr-relate-to-the-connection-manager-connmgr\n","messagePattern":"\nUnable to initialize libp2p due to conflicting resource manager limit configuration\\.\nresource manager System\\.Conns \\((.+?)\\) must be bigger than ConnMgr\\.HighWater \\((.+?)\\)\nSee: https://github\\.com/ipfs/kubo/blob/master/docs/libp2p-resource-management\\.md#how-does-the-resource-manager-resourcemgr-relate-to-the-connection-manager-connmgr\n","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"core/node/libp2p/rcmgr.go","lineNumber":469,"sourceCode":"\treturn result\n}\n\nfunc ensureConnMgrMakeSenseVsResourceMgr(concreteLimits rcmgr.ConcreteLimitConfig, cfg config.SwarmConfig) error {\n\tif cfg.ConnMgr.Type.WithDefault(config.DefaultConnMgrType) == \"none\" || len(cfg.ResourceMgr.Allowlist) != 0 {\n\t\t// no connmgr OR\n\t\t// If an allowlist is set, a user may be enacting some form of DoS defense.\n\t\t// We don't want want to modify the System.ConnsInbound in that case for example\n\t\t// as it may make sense for it to be (and stay) as \"blockAll\"\n\t\t// so that only connections within the allowlist of multiaddrs get established.\n\t\treturn nil\n\t}\n\n\trcm := concreteLimits.ToPartialLimitConfig()\n\n\thighWater := cfg.ConnMgr.HighWater.WithDefault(config.DefaultConnMgrHighWater)\n\tif (rcm.System.Conns > rcmgr.DefaultLimit || rcm.System.Conns == rcmgr.BlockAllLimit) && int64(rcm.System.Conns) <= highWater {\n\t\t// nolint\n\t\treturn fmt.Errorf(`\nUnable to initialize libp2p due to conflicting resource manager limit configuration.\nresource manager System.Conns (%d) must be bigger than ConnMgr.HighWater (%d)\nSee: https://github.com/ipfs/kubo/blob/master/docs/libp2p-resource-management.md#how-does-the-resource-manager-resourcemgr-relate-to-the-connection-manager-connmgr\n`, rcm.System.Conns, highWater)\n\t}\n\tif (rcm.System.ConnsInbound > rcmgr.DefaultLimit || rcm.System.ConnsInbound == rcmgr.BlockAllLimit) && int64(rcm.System.ConnsInbound) <= highWater {\n\t\t// nolint\n\t\treturn fmt.Errorf(`\nUnable to initialize libp2p due to conflicting resource manager limit configuration.\nresource manager System.ConnsInbound (%d) must be bigger than ConnMgr.HighWater (%d)\nSee: https://github.com/ipfs/kubo/blob/master/docs/libp2p-resource-management.md#how-does-the-resource-manager-resourcemgr-relate-to-the-connection-manager-connmgr\n`, rcm.System.ConnsInbound, highWater)\n\t}\n\tif (rcm.System.Streams > rcmgr.DefaultLimit || rcm.System.Streams == rcmgr.BlockAllLimit) && int64(rcm.System.Streams) <= highWater {\n\t\t// nolint\n\t\treturn fmt.Errorf(`\nUnable to initialize libp2p due to conflicting resource manager limit configuration.\nresource manager System.Streams (%d) must be bigger than ConnMgr.HighWater (%d)","sourceCodeStart":451,"sourceCodeEnd":487,"githubUrl":"https://github.com/ipfs/kubo/blob/329838acdfafae224582930457efe80aa217afc0/core/node/libp2p/rcmgr.go#L451-L487","documentation":"Error \"\nUnable to initialize libp2p due to conflicting resource manager limit configuration.\nresource manager System.Conns (%d) must be bigger than ConnMgr.HighWater (%d)\nSee: https://github.com/ipfs/kubo/blob/master/docs/libp2p-resource-management.md#how-does-the-resource-manager-resourcemgr-relate-to-the-connection-manager-connmgr\n\" thrown in ipfs/kubo.","triggerScenarios":"Thrown at core/node/libp2p/rcmgr.go:469 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Raise Swarm.ResourceMgr.Limits.System.Conns above Swarm.ConnMgr.HighWater","Or lower Swarm.ConnMgr.HighWater below the System.Conns limit","Or set Swarm.ConnMgr.Type to 'none' if you do not want a connection manager","See docs/libp2p-resource-management.md#how-does-the-resource-manager-resourcemgr-relate-to-the-connection-manager-connmgr"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"329838acdfafae224582930457efe80aa217afc0","analyzedAt":"2026-09-03T18:30:52.135Z","contentChangedAt":"2026-09-03T18:30:52.135Z","schemaVersion":2},"datasetVersion":"2026-09-11T00:17:11.886Z"}