How to get a full view of the lightning network with c-lightning? As I understand lightning a node should in principle have a complete view of the lightning network graph (i.e., all nodes and channels). However, I also understand that for practical reasons the view will not actually be fully complete (some update may not have reached the node, I suppose).
For example I am currently using c-lightning. After running a node for some hours, if I do lightning-cli listnodes I get a list of ~5k nodes. But if I look at 1ml.com they currently report that there are ~14k nodes (~7k with active channels). So there seems to be rather a large gap between what I see and what 1ml sees.
For a particular use case I would like to have a &quot;as complete as possible&quot; view, though. My question then is if there is some way to configure the node to more actively explore and learn the full network?
lightning-cli listchannels is what you are looking for to also see the channels and not only the nodes.
In general the lightning nodes learn the network view from the gossip protocol where closed channels may be discarded and not forwarded anymore. If you look proprietary tools like the one you mentioned they might have stored older nodes and channels this is one source how the different numbers can arise.
BTW you get the gossip information from your peers so you could also peer with as many nodes as you learn from your initial peers and hope that you get a larger view of gossip.