<p>I believe if you c-lightning implementation does not tell you the <code>out_channel</code> it means that onion was sent to you. The local failure can be explained by you not knowing the payment hash. Most likely people send out onions with random payment hashes so that they can probe other peoples channels. You can set log level debug and check your logfile to confirm if it was missing preimages.</p>
<p>In general you cannot expect to successfully settle every forwarding. Even if you have been able to forward it there might be remote errors. In order to increase your reliability as a routing node you can do two thinks.</p>
<ol>
<li>make sure that your channels have enough balance on either side so that they can support incoming or outgoing payments</li>
<li>activate JIT routing. In case your node cannot forward a payment along a channel it will not send an error back but try to rebalance your channels to provide yourself liquidity on the requested channel</li>
</ol>
<p>Both options will probably cost you money to begin with and remember: even if - with these measures - you have been able to forward the payment it does not mean that you get paid because the next hops could yield local errors</p>

CC BY-SA 4.0
2020-12-11T16:52:03.573Z
2020-12-11T16:52:03.573Z
Rene Pickhardt
<p>I am running a c-lightning node (v0.8.2). I am routing a payment every few days. However, I realized that dozens of payments every day fail, many of them fail locally (I see the status 'local_failed' on RTL). Apparently, this is due to insufficient funds in the channel that was tried to route <strong>out.</strong> I tried to figure out how I can become a better hub and accommodate more of those of those payments.</p>
<p>My investigations where not really prosperous, as I could not determine the next channel that caused the payment to fail. I tried to inspect the logs with <code>lightning-cli listforwards</code>. But it does not list the <code>out_channel</code>.</p>
<p>Any ideas or recommendations how I can improve my job as a router, i.e. finding out which channels to improve / balance?</p>
<p>Kind regards</p>

<lightning-network><core-lightning><lightning-routing>
How can I determine the reason for a failed routing on c-lightning
TKone7
# How can I determine the reason for a failed routing on c-lightning

(Asked by: username_0 on 2020-12-11)

I am running a c-lightning node (v0.8.2). I am routing a payment every few days. However, I realized that dozens of payments every day fail, many of them fail locally (I see the status 'local\_failed' on RTL). Apparently, this is due to insufficient funds in the channel that was tried to route **out.** I tried to figure out how I can become a better hub and accommodate more of those of those payments.

My investigations where not really prosperous, as I could not determine the next channel that caused the payment to fail. I tried to inspect the logs with `lightning-cli listforwards`. But it does not list the `out_channel`.

Any ideas or recommendations how I can improve my job as a router, i.e. finding out which channels to improve / balance?

Kind regards

**Tags:** lightning-network, core-lightning, lightning-routing


---

## 1 answers

### Answer by username_1 on 2020-12-11. Score: 1

I believe if you c-lightning implementation does not tell you the `out_channel` it means that onion was sent to you. The local failure can be explained by you not knowing the payment hash. Most likely people send out onions with random payment hashes so that they can probe other peoples channels. You can set log level debug and check your logfile to confirm if it was missing preimages.

In general you cannot expect to successfully settle every forwarding. Even if you have been able to forward it there might be remote errors. In order to increase your reliability as a routing node you can do two thinks.

1. make sure that your channels have enough balance on either side so that they can support incoming or outgoing payments
2. activate JIT routing. In case your node cannot forward a payment along a channel it will not send an error back but try to rebalance your channels to provide yourself liquidity on the requested channel

Both options will probably cost you money to begin with and remember: even if - with these measures - you have been able to forward the payment it does not mean that you get paid because the next hops could yield local errors


---

