rebalance-lnd
rebalance-lnd copied to clipboard
Try with lower amounts on failure
If rebalancing did not work for amount 2N, try again (twice?) with amount N (recursively?).
I'm doing something similar now, using very simple bash scripts. For each channel of interest, I just double the --percentage
parameter on success until the channel is balanced or the command failed.
40
is used for --ratio
:
for chan in `./unbalanced_chans.sh 40`; do ./incremental_rebalance.sh $chan; done
unbalanced_chans.sh
:
#!/bin/bash
./rebalance.py -l -r $1 | grep "Channel ID"|cut -f 2 -d ":" | cut -f 3 -d " "
incremental_rebalance.sh
:
#!/bin/bash
./rebalance.py -t $1 -p 1 && \
./rebalance.py -t $1 -p 2 && \
./rebalance.py -t $1 -p 4 && \
./rebalance.py -t $1 -p 8 && \
./rebalance.py -t $1 -p 16 && \
./rebalance.py -t $1 -p 32 && \
./rebalance.py -t $1 -p 64 && \
./rebalance.py -t $1
This is how I do it: https://github.com/C-Otto/rebalance-lnd/issues/184
It starts at 100% and then decreases it by a certain factor every cycle ...