Running a Lightning Network Daemon (LND) Node - Part 2

Running a Lightning Network Daemon (LND) Node - Part 2

This article is a continuation of Part 1, so if you haven't read that, start there.

To quickly recap: my LND node was set up, I was able to open a few channels and able to send a successful test payment. But I could not receive payments and my node was not routing any transactions.

Before: My small node with few channels was having trouble routing payments

To solve this, I embarked on a journey of opening more, bigger, higher quality channels, and obtaining inbound liquidity. I also made some configuration improvements along the way.

I opened new channels like:

  • Kraken
  • Bitfinex
  • OKX
  • Paywall.link

I also closed some under-performing channels.

After: Successful test payment sent (initiated via lncli command line, routed via Kraken)

Following this, I was able to send a successful transaction from my LND node to another lightning wallet. The transaction was routed via Kraken.

At this point my node was still publicly identifiable only by its public key. Rather than leave it like this, I decided to name my node "xsat.org" after a domain name that I use as an lnbits wallet and lightning address.

Set the the alias= variable in your lnd.conf to set the public name for your node

After I was done configuring my new node name, it showed up in amboss, 1ML, etc. It also showed the 500% increase in capacity.

I opened 12 channels and committed 0.33 BTC to liquidity

At this point the node was largely unbalanced with an overwhelming majority of outbound vs inbound liquidity. There was, however, a small amount of inbound, enough to route our first successful transaction:

That fateful first transaction, routed for a fee of 1 satoshi

The fee of 1,049 mSats (milli-sats) is equivalent to about 1 satoshi (1.049 satoshi to be precise). The above transaction information is the equivalent to taping the dollar bill used by your first customer to the cash register. Our first earned satoshi!

Despite the excitement, the node was still in need of work.

To solve the liquidity imbalance, I purchased 20,000,000 sats of inbound liquidity for 50,000 sats from zero fee routing | CLN.

Real-world lesson in liquidity sinks: Here Bitfinex is draining my liquidity because of my low fees

The new inbound immediately exposed the under-pricing of my outbound to bitfinex: a flood of transactions (dozens per minute) draining my liquidity, and earning me only very small fees along the way.

This is how I learned about "liquidity sinks". Since most people send funds to an exchange in order to sell or exchange them, and only very rarely spend bitcoin lightning directly from an exchange back into the market, exchange nodes tend to "eat up" your outbound liquidity.

The solution to this is to set your outbound prices high enough to ensure you are compensated for the use of your funds. I adjusted outbound pricing to exchanges to prevent any future draining of funds.

As an additional method to gain both inbound and outbound liquidity, I participated in a few liquidity swaps on lightningnetwork.plus.

Following this, I basically left my node to run itself for a few weeks. It routes transactions on most days. Sometimes it goes for a few days without routing any transactions, and sometimes there is a sudden flurry of transactions. I'm still learning the ropes as an operator.

On August 8, I did have a very welcome surprise:

My all time highest fee for a single transaction (4702 satoshi or 4,702,127 millisatoshi fee)

My node earned 4,702 satoshi for a single transaction, by accepting 474,914 and forwarding 470,212 onward, from zero fee routing to bitfinex.

In USD terms, that is roughly a $1 fee earned for forwarding a roughly $100 payment. If you could do that all day, you might have a real business. Presumably this liquidity was valuable enough that the sender was willing to pay the 1% fee.

030f59c7ce0a35969c114f8818b7cd151e00e34ba3601f370e53d5a86dc6221c73
August monthly earnings as of the 13th are 13,323 satoshis (0.00013323 BTC) earned in exchange for routing 1,187 distinct payment events with transaction volume around 0.1 BTC

In August, as compared to July, my node began to receive more frequent transactions and fees. In the entire month of July, the node earned 1,227.66 sats in 91 events. In August, by the 13th the node had earned 13,323.92 sats in 1,187 events.

(In USD terms, the node earned $0.26 in July vs $2.85 so far in August.)

This represents a monthly payments growth rate of 985% by frequency and 1,204% by volume from July to August (so far).

If you are running a lightning node, please feel free to open a channel! The node public key and QR code are above.

To be continued...