[GUIDE] Installing charge-lnd (in a docker) to automate your fee policies

Anyone having gRPC issues, please double check that you’re providing the correct LND IP address by going back to step 5. Let me know. This one is above my pay grade, but I’m still using charge-lnd flawlessly, so…?

What’s it mean if nothing happens? It was working earlier, now nothing. image

Never mind, disregard this. I had a syntax error in the config file. Once I fixed that it worked again.

I was nervous running this just once. Not sure about setting it to a cron job.
Given it’s a docker image, any update to it will be automatically run on your node.
What kind of damage could a malicious update do via GRPC to lnd?

edit: Changed latest to v0.2.4 so that I can decide when I run a new version of change-lnd

Hi - I seem to be stuck at step 6. Here is the output i see when running docker. Any guidance is greatly appreciated!

@The_Lorax Please see my above post above and let me know if you have any recommendations. Thank you!

Would you like to check the bottom line again?

-e GRPC_LOCATION=LND.10.21.21.9:10009

It seems that the IP contains an incorrect string. Why don’t you try setting it as follows?

-e GRPC_LOCATION=10.21.21.9:10009
1 Like

Thanks for the reply @takebit

Tried what you recommended and it appears I have the same error:

In step 6, do I simply type:

cd ~

Or do I need to do something differently?

The error in the last line suggests that the charge.config file doesn’t exist, so we’ll use
I think you need to make sure that “/app/charge.config” is created correctly.

Fantastic guide. Only thing I would amend to the guide, is this thing of adding “sudo” if you don’t have permission. As I had to scroll through the comments to find out :slight_smile:

I believe cd ~ is all you need to type. That is what I did. It is just a safety check that you’re not in the wrong directory, it shouldn’t really do much at all.

I want to document a few things here in case it helps someone facing a similar problem.

You can add -v to the end of the command used in the cron job to have the command be more verbose. You can save that output to a file by adding >> /var/log/chargelnd.log to the end of the command.
ie:
accumulator/charge-lnd:latest -v >> /var/log/chargelnd.log

Also, I was getting a “Could not connect to gRPC endpoint” error when running the command with -v and it turns out that the problem was that the TLS certificate for lnd was using an old hostname. (I have umbrel set up on AWS EC2.) Updating the host name in lnd.conf, deleting the tls files in umbrel/tls folder, and then restarting everything did the trick.

Just in case it helps someone searching because I was pulling out my hair for a while on this one.

Amazing guide!! Thanks a lot for sharing it!!

Please note the sample config file in step 4. has been changed and the following link no longer works: https://github.com/accumulator/charge-lnd/blob/master/charge.config.example

New example files are here: https://github.com/accumulator/charge-lnd/tree/master/examples

Turns out all i had to do was a cold restart of my node :man_facepalming:

Has anyone installed this and seen traffic decrease significantly? I installed successfully a few days ago and since have only routed 10 transactions for the first 2 days and not a single one the past 2 days - I can’t think back to a day when I routed no transactions since I first started running my node.

Possibly something I messed up on the install? I do see my fees are being updated accordingly so I think it was successful - Wondering if others experiences significant changes in traffic?

It’s an amazing guide and I really appreciate the effort into putting it here.

I just want to raise a WARNING about this kind of scripts.

  1. These scripts to have a better management are good, but only in good hands, for users that are more advanced and know what they are doing with these scripts.
  2. These scripts have a lot of functionalities but some of them are bad for LN! For example the option that is automatically “disable” a channel, not being able anymore for routing payments in way or another or both.
    This is really dangerous behavior for THE ENTIRE LIGHTNING NETWORK! Doesn’t make any sense to disable a channel, is totally against what is LN - a web of connections always open. Disabling a channel is like closing a gate to free market.
    Ok I understand that some of you wants only gainz, but LN is not only about that. You can raise your fees as much as you want to have more gainz, it’s a free market, but disabling channels is CENSORSHIP and is like shooting themselves in own foot.
  3. LN is a living organism. If we do not feed him, will not grow. How is supposed to grow if you cut him lose the food (aka routing channels)?
  4. We are at just the beginning of this marvelous journey into LN, we should not start now with ripping off users with fees. We started LN exactly to scale the onchain problem, now we are just going back to fuck each others. This is a nonsense and we will not get anywhere with this.
  5. This script also is forcing to close channels, randomly or based on who knows what algorithm. Happen to me not once, but 3 times. I got 3 channels closed for no reason or human interaction.

FOR THE SAKE OF LN AND BITCOIN: PLEASE STOP USING THESE SCRIPTS THAT ARE DOING MORE HARM THAN GOOD!

BE AWARE!

5 Likes

Thanks for the information and warning - What’s the best way to remove this now without messing anything up?

In conclusion, should we use this script or not?

I’m doing routing node nowadays, but it’s not profitable. I’m looking for a script to help manage my traffic and make some profit with him.

Or we don’t need to make a profit with it.

Or we just support network is enough.

thank you

DEAD WRONG. You will NOT make any profit. That’s just pure bullshit promotion to make noobs believe they can earn money with running a LN node.
Let’s recap a bit and please pay attention:

  1. A LN node is not a “milk cow” to have “passive income”. Forget about this bullshit idea. Will need some good years until you can earn some significant amount of sats to be considered “income” or “profit”. Don’t be fooled that others will say “in x months I earned x sats with my node”, they say that just to make you lose more sats and profit from you, because you are noob that do not read and learn more about how LN works and you fall into a trap thinking that just by having few LN channels you will get rich.

  2. You run a LN node firstly FOR YOU, for your own payments to be done in a private and full custody by yourself. As I explained in Getting started with Umbrel node guide, before you start running your node, think about WHY you run a node and adapt it your needs.
    You do not “support the network”, that’s another fallacy. You support YOURSELF, you give to yourself the custody and the power of running a node. The network doesn’t give a shit about you and your “support the network”. By empowering yourself, you are making the network stronger, by each individual regaining his financial sovereignty.

  3. You manage your LN node according with your needs are a LN user:

  • have good peers - with at least 20-30 channels, low fees, high time online
  • have channels with those services you are using, paying them directly through those channels
  • expand your connections when is needed, depending on your spending habits and liquidity you have
  • do not put into your LN node more than 30% of your all BTC stash, if you are just a regular LN user.
  1. If you really want to be a big routing LN node, YOU NEED TO BE A REAL BANKSTER, YOU NEED TO PUT A BIG AMOUNT OF SATS. Yes, in that moment your liquidity can be rented to those in need and you can get sats in return, But this require a very good knowledge of how LN works, having well prepared node machines (not just a shity RaspPi) and have good knowledge of economics.
    Yes, we are talking about a business of running channels, a channels factory. But this can’t be achieved with your shity 20k sats you earned from a faucet and now you want to put them to generate “passive income” :slight_smile: :slight_smile: :slight_smile:
    Running a routing node is a serious work not a game and if you do not know how to do it, you are doing more harm than good to the network.

I hope many will read and understand these aspects.

4 Likes