Pages:
Author

Topic: The Lightning Network FAQ - page 78. (Read 32058 times)

legendary
Activity: 1876
Merit: 3131
June 29, 2019, 12:38:49 PM
#14
How Is Milisatoshi In A Channel Is Shared When The Channel Closed?

The amount is rounded down when the channel is closed. 1 msat = 1/1000 sat. For example, if you have 900 msat then you will get 0 satoshi on channel closure.

And Who Pay For The Channel Closing Transaction Fee? Is It Shared Equally Between 2 Party? And What If One Party Has No Balance?

The person who opened the channel covers the closing fee. Note that it's not possible to use up all funds that are locked up in the channel.
newbie
Activity: 53
Merit: 0
June 29, 2019, 11:36:20 AM
#13
Great thread,happy to see that lightning network is here to solve micro transactions  Smiley
sr. member
Activity: 270
Merit: 309
Shinji bgt gwh
June 29, 2019, 08:40:36 AM
#12
How Is Milisatoshi In A Channel Is Shared When The Channel Closed?
And Who Pay For The Channel Closing Transaction Fee? Is It Shared Equally Between 2 Party? And What If One Party Has No Balance?

Example:
A Has 150000.5 Satoshi In X Channel
B Has 49999.5 Satoshi In X Channel
B Decided To Close X Channel, The Channel Closing Transaction Fee Is 20000 Satoshi.
How Much Did A & B Get In This Case?

Sorry If It Hard To Understand
member
Activity: 200
Merit: 73
Flag Day ☺
June 28, 2019, 01:33:49 PM
#11
-snip

That's an overkill for a simple Lightning Network node. By default, one have 24 hours to bring back one's node online before forced channel closure (old channel state might be broadcast to the network).

Overkill is the point for a No DownTime Setup.

But even the simple setup need to be prepared for

Power Failures  , (Hurricanes or Ice Storms can have power off for weeks.)
ISP Failures    

All of which can still take you offline even if your PC is working perfectly.

I imagine at some point the watchtowers will handle all of the fail-over concerns.

Do you happen to know what specs & infrastructure the watch towers will be using?
TIA.



That would be a nice build Smiley go with a perc6 raid controller Smiley  slap on FOG snapshots to be extra
bit excessive for how beta LN is, surly opennode and eclair are using build like this though.


I always liked the PERC RAID Controllers.  Smiley
hero member
Activity: 1423
Merit: 504
June 28, 2019, 01:09:45 PM
#10
That would be a nice build Smiley go with a perc6 raid controller Smiley  slap on FOG snapshots to be extra
bit excessive for how beta LN is, surly opennode and eclair are using build like this though.

I know blockstream could be a viable option in the future on network/bandwidth redundancy, 1 way handshakes though even if LND got implemented. Unless we somehow get blockstream TRIA compatable (2 way LNB) blockstream would be something different entirely in that case if we could somehow get that to happen via BTC network fee's or something that would be sweet.

legendary
Activity: 1876
Merit: 3131
June 28, 2019, 01:07:58 PM
#9
-snip

That's an overkill for a simple Lightning Network node. By default, one have 24 hours to bring back one's node online before forced channel closure (old channel state might be broadcast to the network).
member
Activity: 200
Merit: 73
Flag Day ☺
June 28, 2019, 12:54:04 PM
#8
I would however recommend running Raid 0 and 2 new drives, with APC.

Wouldn't RAID 1 be better in such case? On-chain funds can be easily recovered using a seed but it won't restore the file which keeps channel state. Once you lose it, you have to depend on the other party. They might attempt to cheat. Using an old backup will be treated as a cheat attempt.
Yes Raid one would be better, I got them mixxed up. But yes "Mirroring" is the best way,

*considering its page 1 I felt it critical to edit that mistake xD

I also wanted to add if your caught doing that you do get penalized as there are measures in place, I do not know the complexities behind the penalties though.


FYI:
Mirroring Increases Read Speeds, but decreases Write Speeds verses a single drive.
This can always be compensated for by using a high end RAID controller, that has Ram installed on it specially for Caching Reads & Writes.

If you want a professional designed system to stay up ,
you need to design a Server with Redundant Power Supplies running RAID 5 with hot swap able drives.
That way if 1 drive fails, you just hot-swap the new one and it automatically recovers the data, No Down Time.  Smiley
Also have a UPS ,that is connected to an alternative power source so if the normal power cuts off, your system stays up.
In addition, have two separate ISPs, with an automatic rollover if 1 ISP fails.

* I have seen companies do the above and even have redundant servers , if the motherboards failed for mission critical applications.*

hero member
Activity: 1423
Merit: 504
June 28, 2019, 12:33:30 PM
#7
I would however recommend running Raid 0 and 2 new drives, with APC.

Wouldn't RAID 1 be better in such case? On-chain funds can be easily recovered using a seed but it won't restore the file which keeps channel state. Once you lose it, you have to depend on the other party. They might attempt to cheat. Using an old backup will be treated as a cheat attempt.
Yes Raid one would be better, I got them mixxed up. But yes "Mirroring" is the best way,

*considering its page 1 I felt it critical to edit that mistake xD

I also wanted to add if your caught doing that you do get penalized as there are measures in place, I do not know the complexities behind the penalties though.
legendary
Activity: 1876
Merit: 3131
June 28, 2019, 12:26:29 PM
#6
I would however recommend running Raid 0 and 2 new drives, with APC.

Wouldn't RAID 1 be better in such case? On-chain funds can be easily recovered using a seed but it won't restore the file which keeps channel state. Once you lose it, you have to depend on the other party. They might attempt to cheat. Using an old backup will be treated as a cheat attempt.
hero member
Activity: 1423
Merit: 504
June 28, 2019, 12:00:32 PM
#5
Basic question. What kind of hardware specs, and bandwidth are recommended to maintain a routing node that has 100+ channels?
Bandwith,Ram,Processor dont really hold any weight on hardware decisions,
 I would however recommend running Raid 1 and 2 new drives, with APC. *Edit Raid 1 (not 0)
You want to focus on stability over time to prevent the node from crashing.
Hope this helps.
If your just wanting to play with it google compute is offering $300 trials and have been stable for my projects.

legendary
Activity: 1876
Merit: 3131
June 27, 2019, 05:55:49 AM
#4
Basic question. What kind of hardware specs, and bandwidth are recommended to maintain a routing node that has 100+ channels?

Running a Lightning Network node is not demanding. LNchat's node has 16 active channels and it uses less than 1% of available RAM (~300 MB out of 32 GB) and barely any CPU processing power. I don't monitor how much data is being used by the server since I also use it for a few different things.

Xian01 had been running a Lightning Network node (~200 channels) and posted some information which might be useful to you.
legendary
Activity: 2898
Merit: 1823
June 27, 2019, 04:13:44 AM
#3
Basic question. What kind of hardware specs, and bandwidth are recommended to maintain a routing node that has 100+ channels?
legendary
Activity: 1876
Merit: 3131
June 26, 2019, 05:06:26 PM
#2
I decided to re-post this thread without making many changes. I will focus on answering questions from the previous thread and keeping this one clean.

This thread is now self-moderated. Old thread got derailed. Please, don't discuss here whether or not the Lightning Network is a good scaling solution.

But I'm not sure if that's possible, until now the channel doesn't allow me to send my full balance. It varies a bit, so I'm not sure what the minimum reserve is.

Every channel has to maintain a reserve. It should be equal to 1% of the initial channel balance. Some wallets do not inform the user that such thing exists.

How do I choose which node to open a channel to?

I guess that you have already figured it out. The easiest way is to look for a well-connected node on 1ml.com and then copy its public key. Alternatively, users who run LND can take advantage of built-in autopilot which works quite well.

And: I expected payments to use both channels when possible, but until now that hasn't happened.

It's called payment slicing. Unfortunately, this feature is not available yet.
legendary
Activity: 1876
Merit: 3131
June 26, 2019, 05:06:04 PM
#1
This thread is now self-moderated. The previous one got derailed. Please, don't discuss here whether or not the Lightning Network is a good scaling solution.

If you don't know anything about the Lightning Network, consider reading "Basics of The Lightning Network" first.

Table of contents

      1. Lightning basics
      2. Wallets
      3. Running a node
      4. Concerns
      5. Other questions

Lightning basics

How are coins on the Lightning Network different from the on-chain ones?

They are exactly the same coins. They are stored in a multi-signature address and transactions are settled between two parties without broadcasting anything to the blockchain (except when opening and closing the channel). Every time a payment is settled, a new commitment transaction is signed. Such a transaction reflects the current state of the channel and can be broadcast if one of the participant disappears.


How many times can a payment channel be used?

Payment channels can be used as long as both parties continue to cooperate with each other. Channels do not have any use or time limit.


How large is the Lightning Network?

The total number of nodes, channels and network capacity has been constantly increasing for quite some time now. You can use 1ml.com to see up-to-date statistics. Keep in mind that some channels are private; they are not advertised across the network so they are not included in those stats.


How fast are Lightning Network payments?

They are usually instantaneous. Although, some payments might take a few seconds if a wallet needs to try multiple different paths.


How often do payments fail?

A payment fails if there is no route to the destination or if there is no enough liquidity in the channels in the selected routing path. The latter problem can be mitigated by splitting the payment into few small chunks and sending them through different paths.


How high are transaction fees?

Most channels charge a base fee and a fee proportional to the amount sent, so the larger the payment, the more you are going to pay. You should pay less than 3 satoshi for transactions <= $10 for most of the time.


Are Lightning Network payments more anonymous than on-chain transactions?

Yes, Lightning Network payments are more anonymous. They use onion routing. In short, when a payment is being routed, an intermediary node knows only the previous and the next node in the path. It is impossible to tell who initiated the payment and what the final destination is.


Wallets

Which wallet would be the best for me?

There are quite a few interesting options for different kinds of users.

No-coiners: Strike

Bitcoin newbies: BlueWallet

Regular users: Phoenix Wallet, Breez Wallet, Blixt Wallet

Advanced users: run your own node Smiley

Electrum also has a built-in support for the Lightning Network. Make sure to read Electrum Lightning Network walkthrough if you decide to give it a try.


Should I run my own node instead of using some wallet?

You could benefit from running your own node in a few ways. Assuming that you would run your node 24/7, you would be able to receive payments at all times. Nodes can also help the network by forwarding payments. You would also be able to take advantage of advanced features like: opening multiple channels in a single transaction, dual-funding and keysend payments.


Do I have to generate an invoice every time I want to receive coins over the Lightning Network?

No, invoiceless (keysend/spontaneous) payments are supported by LND and c-lightning. Most wallets do not support this feature, though.


Why can't I receive coins?

First of all, the timelock is decided before the channel is established. By default, most nodes force the other peer to wait 144 blocks (~1 day). The maximum acceptable value by default is 2016 blocks (~2 weeks). I configured my node to create channels with their_to_self_delay = 432 blocks (~3 days), so if someone decides to close the channel opened to my node uncooperatively, they will have to wait 432 blocks (after the commitment transaction has been included in a block) before they can spend the output belonging to them. Those timelocks are relative which means that you do not have to sign a new commitment transaction whenever a new block is mined. New commitment transactions are signed periodically because their fees need to match the current state of the mempool. There is no point in paying 60 sat/vbyte when 1 sat/vbyte transactions are getting confirmed in just a few minutes. It also applies the other way around.

The first transaction is the commitment transaction. Let's say there's node A(lice) and node B(ob), and node A broadcasts the commitment transaction. That commitment transaction includes two outputs:

- output #0: 3 BTC (spendable by node B's private key) - reflecting node B balance
- output #1: 6 BTC (RSMC) - reflecting node A balance

There is one more important detail before we go any further. Whenever a new commitment transaction is signed, both parties exchange revocation keys for the previous commitment transaction so that they can both be sure that the other party is very unlikely to broadcast an old state of the channel.

RSMC is short for Revocable Sequence Maturing Contract. Such an output contains a relative timelock. This means that you can't spend this output until a certain amount of blocks have been mined since the transaction which includes that output was mined.

Let's say node B didn't change the default value of 144 blocks and the commitment transaction has been confirmed. There are two possible scenarios.

1) Node A attempts to cheat and broadcast an old commitment transaction. Node B has 144 blocks to spend the RSMC output using his and node A's revocation key which he got while they were working on a new commitment transaction.

2) Node A broadcasts the latest commitment transaction. In such a case, node B never got node A's revocation key for that commitment transaction, so he cannot spend that RSMC. Node A can broadcast another transaction spending that output after 144 blocks have been mined.


Concerns

Is the Lightning Network centralized?

The common argument is that users are more likely to open channels to large nodes rather than small/medium ones. While that's true, as the networks continues to grow, we can expect hundreds or even thousands of nodes to concentrate end users. This post speculates on possible types of nodes; you should read it if you are still concerned.


Can it have a negative impact on the first layer?

If many channels are closed at once, the transaction fees could immediately spike and remain high for an extended period of time.


Does the Lightning Network solve Bitcoin's scalability problem?

Not completely. The Lightning Network was designed mostly for micro-transactions which would not be cost-effective on the first layer. Large payments are also feasible thanks to multi-path payments. Opening a channel involves an on-chain transaction so if we expect every user to open at least one channel, the blockchain would quickly become congested for a long time. Thus, other scaling solutions are needed. Alternatively, more layers can be built on top of the Lightning Network.


What would happen if some nodes went temporarily offline?

Should many large nodes go offline at the same time, payment failures might become more common. If you have only one channel and your peer goes offline then you obviously won't be able to send and receive any payments.


Other questions


What shops accept Lightning Network payments?

Here you can find a list of merchants who accept LN payments.


Do any exchanges support the Lightning Network?

Yes, the biggest exchange which supports Lightning deposits and withdrawals is Bitfinex. Here you can find an up-to-date list of exchanges which support the LN.


What are the upcoming features?

Dual funded channels - both parties will be able to fund a channel. This feature is available in c-lightning (experimentally).

Splicing-In & Out - it will be possible to add and remove funds from existing Lightning Network channels without having to close them.

Channel factories - existing Lightning Network channels could be used for creating new channels without broadcasting anything to the Bitcoin network. Normally, a channel is opened to only one person. In channel factories, there is a group of people. Group members maintain channels between themselves. More involved users = more savings. If one of the participants is uncooperative, existing channels are not affected - new channels can't be created, though.
Pages:
Jump to: