lnd v0.15.3-beta

The documentation for lnrpc.RoutingPolicy shows a boolean field called disabled, but it provides no definition of what that means. Each channel has 2 peers, and each peer in a channel has its own routing policy. Some of the channels have disabled set to true for one peer and false for the other.

Here is an example:

$ lncli getchaninfo 697113461880782849
    "channel_id": "697113461880782849",
    "chan_point": "094c1a9d6cd5294847f560758e8b8d8cdb4ef386ca746112536564742a92184b:1",
    "last_update": 1667018957,
    "node1_pub": "02572c2e1b43a78bb060e7d322b033443efc0d8d60fc2b111dd8bb999aa940d1f5",
    "node2_pub": "02a45def9ae014fdd2603dd7033d157faa3a55a72b06a63ae22ef46d9fafdc6e8d",
    "capacity": "5281151",
    "node1_policy": {
        "time_lock_delta": 40,
        "min_htlc": "1000",
        "fee_base_msat": "1000",
        "fee_rate_milli_msat": "10",
        "disabled": false,
        "max_htlc_msat": "5228340000",
        "last_update": 1665821197
    "node2_policy": {
        "time_lock_delta": 24,
        "min_htlc": "1000",
        "fee_base_msat": "0",
        "fee_rate_milli_msat": "501",
        "disabled": true,
        "max_htlc_msat": "5228340000",
        "last_update": 1667018957

Is it true that a channel is only active if the routing policy for both peers shows disabled = false?

Or is setting a routing policy to disabled the equivalent of setting it to null? Some channels have peers with null routing policies as in this example:

$ lncli getchaninfo 555817421567164416
    "channel_id": "555817421567164416",
    "chan_point": "43a329e374f19ac11cb8377d8d791505d27e60c221a3cfe99a2d758318803e0f:0",
    "last_update": 0,
    "node1_pub": "0207481a19a3f51a48f134e95afa67cfeffdb38a99b5ad3494a320c4918aaaf579",
    "node2_pub": "02ef61a252f9504a42fc264a28476f44cea0711a44b2da0bd729ad52aaee9d86b7",
    "capacity": "10000",
    "node1_policy": null,
    "node2_policy": null

Is the above channel active? If so, does it use default routing policy values?

Is disabled = true the same as a null routing policy? Or does it disable the whole channel if one node disables its routing policy?

1 Answer 1


The disabled field is a reference to an edge instead of the whole channel, but the api in lnd doesn't surface edges, so it must be inferred by the direction of fund movements.

Very quickly, what is an edge? In bidirected graphs (which the lightning network currently can be viewed as) what we consider a channel is actually comprised of two entities with direction, called edges.

For example:

┌────────┐               ┌────────┐
│        ├────edge 1────►│        │
│ alice  │               │  bob   │
│        │◄───edge 2─────┤        │
└────────┘               └────────┘

Okay, channels are really 2 edges. Why is that important? Well sometimes it's important to allow fund movement in a certain direction, without allowing movement in another. For example, a popular merchant node wants to allow people to send into their channel so they can collect money in a specific channel, without allowing people to forward through their node and move funds out of another channel. The merchant may want to do this if the specific outgoing channel is used for returns. People forward through that channel may up end the liquidity balance making it impossible to process returns to customers. But, crucially, they want to allow people to be able to send them funds in all directions (they are a merchant after all!)

Such precision is not given with our channels which are bidirectional, so we must look at tweaking the edges. Since we don't want to 'turn off' any channels completely, we cannot set any channel to inactive - this will not allow movement in any direction.

So to reiterate

All channels active and none disabled
┌────────┐               ┌──────────┐               ┌────────┐
│        ├────edge 1────►│          ├────edge 3────►│        │
│ alice  │               │ merchant │               │ carol  │
│        │◄───edge 2─────┤          │◄───edge 4─────┤        │
└────────┘               └──────────┘               └────────┘
            [active]                     [active]

All channels active and edge 4 disabled
┌────────┐               ┌──────────┐               ┌────────┐
│        ├────edge 1────►│          ├────edge 3────►│        │
│ alice  │               │ merchant │               │ carol  │
│        │◄───edge 2─────┤          │◄──X─edge 4──X─┤        │
└────────┘               └──────────┘               └────────┘
            [active]                     [active]

alice to merchant inactive and and edge 4 disabled
┌────────┐               ┌──────────┐               ┌────────┐
│        ├──X─edge 1─X──►│          ├────edge 3────►│        │
│ alice  │               │ merchant │               │ carol  │
│        │◄─X─edge 2─X───┤          │◄──X─edge 4──X─┤        │
└────────┘               └──────────┘               └────────┘
            [inactive]                   [active]

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.