As soon as Faraday is running, you will be able to make use of frcli. Depending on your installation, you will be able to run it simply by typing
frcli into your console or navigating to where the binaries are stored and executing with
The reports Faraday generates can sometimes appear intimidating, especially if your node has a large number of older channels which have already seen plenty of activity.
frcli insights gives us a list of all our channels with detailed information about each of them. LND tracks the uptime of each channel since your last restart. Thus, you will be able to see the
uptime_ratio calculated as part of the output. You can see the age of the channel measured in blocks (confirmations), the total fees earned through this channel, as well as various metrics that can help you compare the activity of your channels.
The command frcli revenue will give us more detail. For each channel we can get pair reports, which shows in detail where capital is coming from and going as it passes through our node.
For each channel, you can see how many milli-satoshi (msat) were routed to and from each peer. This can help you assess how capital is flowing through the network to and from your node with highest granularity.
Information like this can be vital to deciding which channels to keep, which to rebalance, and which to close. Based on the information provided in this output you may be able to identify bottlenecks, such as channels that would route a lot more payments if other channels were better balanced, or had higher capacity.
The output from frcli revenue is high in detail, but can also be overwhelming in range. You can further narrow the command down, for example by only looking at a specific channel (
--chan_points), or limiting the query to specific dates.
frcli --rpcserver=localhost:8443 revenue --chan_points=”b046a363855185962e0bd3b86beefa1480c6ac0d3f0c0b41f6eecf4acd6c0b1f:1” --start_time 1615680000 --end_time 1615766400
Faraday allows us to set thresholds for the metrics of our channels and generate recommendations for when these thresholds are not met by certain channels. You can use the output of the above commands to get an idea of how your channels are generally performing, then make decisions on what performance metrics you are willing to accept.
You can set any of the possible thresholds below for the command
--uptime value Ratio of uptime to time monitored, expressed in [0;1]. (default: 0)
--revenue value Threshold revenue (in msat) per confirmation beneath which channels will be identified for close. (default: 0)
--incoming value Threshold incoming volume (in msat) per confirmation beneath which channels will be identified for close (default: 0)
--outgoing value Threshold outgoing volume (in msat) per confirmation beneath which channels will be identified for close (default: 0)
--volume value Threshold total volume (in msat) per confirmation beneath which channels will be identified for close (default: 0)
--min_monitored value Amount of time in seconds a channel should be monitored for to be eligible for close (default: 2419200)
Alternatively we can also use Faraday to help us identify outliers, meaning channels that significantly underperform your average channel. We can choose what we consider as significant with the
--outlier_mult flag, followed by the number of inter quartile ranges a channel should be from quartiles to be considered an outlier. We recommend values between 1.5 for aggressive recommendations and 3 for conservative ones.
We will also need to decide what to base this recommendation on uptime, revenue or volume using the same flags and defaults as above.
frcli --rpcserver=localhost:8443 outliers --revenue --outlier_mult 2.5
We can use Faraday to get more information about closed channels. First, we will have to obtain the funding transaction IDs of our closed channels from lnd, which we can do with
Next, we will use this information to obtain a report on the channel from Faraday with the command
frcli closereport. This will require a connection to your Bitcoin node. We will be able to see how the channel was closed and which fees were paid to close it.
frcli closereport --funding_txid 4fc297d20fa41d62ccb2acecf2ed6cc0b1ce3c6f274c6cb661e0e97bb65a640f --output_index 1
frcli closereport 4fc297d20fa41d62ccb2acecf2ed6cc0b1ce3c6f274c6cb661e0e97bb65a640f 1
The command frcli audit can be used to generate a full report of all activity on your node. It can also be written to csv with the
--csv_path flag. It requires Faraday to be connected to your Bitcoin node.
There are multiple ways to narrow down such a comprehensive report, most conveniently the
--end_time flags, expressed in unix time. If you are using Loop or Pool, you can identify these transactions in the output once you include the flags
For more granular insights, we may also pass a json array to the command with the
frcli fiat can also help you convert the milli-satoshi values into USD, including for historical values. This feature is also integrated into the
frcli audit command when enabling it with the
frcli --rpcserver=localhost:8443 fiat --amt_msat 21000000