Study & contribute to bitcoin and lightning open source
Interactive AI chat to learn about bitcoin technology and its history
Technical bitcoin search engine
Daily summary of key bitcoin tech development discussions and updates
Engaging bitcoin dev intro for coders using technical texts and code challenges
Review technical bitcoin transcripts and earn sats
Slides: https://keybase.pub/oms/Potzblitz9-RaspiBlitz-slides.pdf
RaspiBlitz GitHub: https://github.com/rootzoll/raspiblitz
Rootzoll presenting at London Bitcoin Devs in July 2019: https://www.youtube.com/watch?v=R_ggGj7Hk1w
Welcome to a new episode of Potzblitz. It is episode number 9. Today we are going to talk about the RaspiBlitz a Bitcoin and Lightning Network full node built on a Raspberry Pi. We have Christian Rotzoll and openoms, two of the developers of the RaspiBlitz here tonight. They are going to talk about the project, present what it is for those of you who don’t know it at all and also give an outlook on what is coming up in version 1.6. We are doing this stream via Jitsi. We are a little bit delayed today because we just had to switch servers. Jitsi is an open source video conferencing software which usually works quite well. It doesn’t collect your data which is a pretty good selling point. If you have any questions there is the Mattermost channel where you can join the channel #potzblitz or using the hashtag potzblitz on Twitter and naturally in the comments on YouTube itself. openoms and rootzoll will be monitoring the questions and I will be asking them during the presentation. Feel free to drop any questions at any time. Some of you might be here for the Spacebox. There was a tweet announcing that it would happen today. It is very good you are here today because the Spacebox is built on top of the RaspiBlitz. We are going to touch on it but the Spacebox talk will happen next Sunday. Tune in next Sunday. Here they are Rootzoll and Openoms, very glad to have you guys.
We are talking Bitcoin full nodes today. RaspiBlitz is one of them but I want to start with the market overview. If you are interested in running a Bitcoin full node and a Lightning node there are multiple options you have out there. One of the first was the Casa node. It is discontinued as far as I know. There is another one called the Nodl which is a very good box, a little more expensive on the price spectrum but delivers on performance. This is also a good choice. It was announced that there should be BitBox Base coming from Shift Crypto but this project seems to be on pause. It was a great project by Stadicus but we will see if it is still going. Another option that is still on the market is myNode. This is about 420 dollars round about. But the project we want to talk about today is the RaspiBlitz. If you want to buy it on the market, all the hardware together in this beautiful box that you see here that will cost you around 380 euros. You can go to shop.fulmo.org. To buy it on the market is not for everybody.
That is where the idea of RaspiBlitz started, a build it yourself node. It started at our Fulmo Lightning Hack Days where we came together to understand the Lightning Network better. It is best to try it out with hands on activities. We were seeing the need here to buy a node ourselves. We started with the tutorial from Stadicus. This was the RaspiBolt project. This was a longer step by step tutorial how to set up a Bitcoin full node and a Lightning node on a Raspberry Pi. We were seeing that it took too long to do this over a weekend so we started to strip things putting all the little manual steps into scripts. This is where the RaspiBlitz project started and developed from there into an easier to set up project. You can find everything on the GitHub. It seems quite popular already. We are almost getting to 1000 stars there. We have 70 contributors so far and of course it is all open source under the MIT license. It can be freely used, modified and forked for your own project. From its base it is Bitcoin Core running and lnd is the Lightning implementation that RaspiBlitz is using. From there you can extend it, we will see it shortly. From the hardware side at the moment it is based on a Raspberry Pi 4, 4GB, you can choose 8GB now if you want but 4GB is the basic we settled for. It can even run with older Raspberry Pis like the Raspberry Pi 3 and also with 1GB you can run the basics. Of course keep in mind if you want to install all the extra apps you can find you might want to go with a more powerful Raspberry Pi. The Raspberry Pi 4 with 4GB is the one we now say should be the standard to use. What else do you need? You need a good power supply so that the hard drive, the SSD, gets enough power. Always make sure you have a good strong power supply. We now also have settled on a 1TB SSD. That is maybe getting the costs up. You can also use an older HDD hard drive with half a TB. Keep in mind we want to use the power the Raspberry Pi is providing you over the USB 3.0. You are getting it much faster with a SSD here and it is worth it to get this 1TB SSD if you want to be future proof. Also make sure to pick the right SSD case for your hard drive. We were seeing some problems with some casing not supporting UASP protocol. Keep that mind. If you pick the one we have on our shopping list you should be good. The UGREEN is working quite well in our testing. You also need a MicroSD card which you put the image on. At the moment make sure you get a good MicroSD card, a higher quality one. A Samsung PRO Endurance for example does a good job. Working on a SD card with many write cycles, even if you try to minimize, it should be a good quality SD card. If you just want to start and try it out you can use an older one if you have one lying around. One special thing about RaspiBlitz maybe compared to other full node projects out there is the screen. You can see it here. This helps a lot people to get started with the project because it tells you simple information on the setup. For example what is the IP address of the device. From there on it tries to give you always good status information. What is the node doing? Is it online? How many satoshis on there? This is a touch screen and what we try to utilize in the future. One often asked question is how do you keep it cool because the Raspberry Pi 4 can get quite hot when it is under a lot of load? We recently decided to go with the Heatsink case, this does passive cooling. We tried a fan in the past but when you have moving parts in your RaspiBlitz it can stop and cause other problems. There is now the Heatsink case for the Raspberry 4 and we recommend this. It might get hot but the Raspberry Pi can live through this. Under normal work it keeps in a range that is ok. Maybe if you are in a hotter country there could be some feedback which would be interesting. For normal use cases you should be good. If you count all your parts together and buy them from Amazon you should be around 235 euros including VAT.
So what do you get when you have all this hardware and you put it together like you can see on GitHub? You set it up over SSH. This is the Terminal, maybe some people aren’t familiar with it. It is what you see in all the hacker movies, people typing like crazy on it. Don’t get scared. It is normally quite easy to get it started. We have some information there. Once you have the Terminal open you can follow what the RaspiBlitz is saying on the display. Type in this command and then it kicks up a GUI kind of thing where you can pick the menu items and do the rest of the configuration you need to do. Once it is set up, you have been through the setup process. The longest will be getting the blockchain. The Raspberry Pi 4 is capable of completely validating and syncing the blockchain by itself. This is something we can utilize. It is powerful and really fast if you use a SSD. Then you can get it done in about a week, have it completely synced and ready to go. Once you have done this you get all these actions you see here to try out your Lightning node. In the beginning, you fund, you put some satoshis on there. You transfer it for example from your hardware wallet. Then you connect to other peers on the Lightning Network. This is not the channel thing, you are just connecting to other Lightning Network peers. It tells you then on the gossip network what is the network looking like? Then you can build up channels. This is the point where you put some satoshis from your onchain wallet into those Lightning channels. Once those channels are established you can start transferring your satoshis on the Lightning Network with Send and Receive. This is already your basic setup. Then we have a lot of extra services. I will show you some detail here. This is what the SSD information looks like without the touch screen. It is from an older version. We will have to see how it develops as we go into the touch screen and graphical user interface in the future.
Working through a SSH connection and all the Terminal is maybe not for everybody for the set up. It should work for everybody but maybe if you want to manage your Lightning node with more comfort through a web browser there are additional apps you can switch on. Here is the RTL (“Ride the Lightning”) app that since the last version is there. You switch it on, let it install and once it is there you get an address you can call on your web browser. Then you can manage your Lightning node with more comfort and with all those extra nice features with a great UI. Even now with the upcoming version 1.6 there is an alternative to RTL if you want to try it out. openoms will show us in more detail, the ThunderHub web UI. It is another project that tries to achieve a similar goal to RTL. Maybe not with 1.6 but we work towards it is that parallel to setup with SSH we try to make it more possible from the beginning to configure on setup and manage your RaspiBlitz over a web UI which you can use over a Tor web browser. This is a step by step iterative process. Keep that in mind, this is something we are working on for the future.
Once you have set up all those things the RaspiBlitz offers you in the latest version, since we have the Raspberry Pi 4 it has a lot of power to run additional apps, you can see the list of apps and special services you can install. I will give you a quick overview of what we have. You can install Tor here and run it as a hidden service. This gives you more privacy. We will maybe in the future go with Tor by default. At the moment you still have to switch it on but in the future this may be default. Then we have Electrs which is an Electrum server that you can run on your RaspiBlitz. The Electrum wallet, it is a popular Bitcoin wallet, this normally picks a random server that is available on the internet. Now you can connect directly to your own Electrum server if you want to and run a RaspiBlitz. There is BTCPay Server if you are interested in processing your own invoices for an online shop or something. Then there is BTC-RPC-Explorer. This is a blockchain explorer where you go on the internet and you want to see if a transaction went through. This is also a web UI so this shows up in your browser. It feels like you are on a professional block explorer website but it is running on your RaspiBlitz. Then there is LNbits. LNbits is also a web UI that helps to manage multiple accounts on your RaspiBlitz. Usually you just have your one account with Lightning. But maybe you want to create smaller accounts for people in your community. We will see the power in that later on. There is SpecterDesktop. This is also a web UI that helps you do things like manage hardware wallets with Bitcoin Core. You can do multisig for example with multiple hardware wallets, Trezor, Ledger, Coldcard or the Specter do it yourself wallet. It has a nice UI which you can run on your hardware. Then there is LNDmanage. This is a CLI, something that you do on the Terminal. It helps you do advanced channel management. It gives you more information that maybe is not available at first glance on the other web UIs. In the same direction but a little different focus is Faraday. Faraday helps you to analyze the channels you have open and recommends which channels are working good and which other channels may be interesting to open. Then there is Loop. Loop is a submarine swaps service. If you are a merchant this could be very interesting. For example you have a channel open, you pay the opening fees, now you can receive Lightning payments. Once the liquidity is filled up on your side normally you would need now to close the channel and open up new channels where you have incoming liquidity. Maybe you don’t want to do this, you have a good established channel so you can use a service like Loop to Loop Out your liquidity to a hardware wallet. I have received Lightning payments as a merchant and maybe once a month I take that amount and with one transaction put it into my hardware wallet. Now I have the channel free to receive payments again. This is interesting for merchant setups with the RaspiBlitz. We will take a look into ThunderHub and Balance of Satoshis, this is what openoms will show you. At this point I will handover to openoms to give you more details on those upcoming new services in the 1.6 release. This is probably be by the end of the month.
I would like to speak about a couple of things I have been working on and I am enthusiastic about. This Lightning management software for lnd which is called ThunderHub. I first came across it in the Lightning Hack Spring, not the last one but the one previous. It was demonstrated and it has a very impressive user interface which you can see some screenshots here. It has a channel overview with balances and fee structures and all kind of things. Even an experimental chat over Lightning application. You can visit the GitHub where the install process is described for other services as well. Now we have the one click installation from the services menu on the Raspiblitz and we have an update option in the update menu. The changes are coming so fast that it is hard to keep up and to redo SD card images for it. One thing which was recently implemented is connected to this Balance of Satoshis feature which we have as well. ThunderHub has implemented Balance of Satoshis itself and gave it a graphical interface. You can see the different settings you can have here to rebalance the channels in advance. A lot of parameters can be set. You can build up the route to go through and specify how much you want to pay for it and the maximum fees and fee rate and what amount to target. Press the button and it tries to execute this and probes its way through. Related to that there is this invoice payment where it is showing a small donation to ThunderHub. The interesting thing on it is that this hasn’t been sent yet. It is showing how many hops and how many sats it will take to send this payment. What happens here is that when you pay through ThunderHub it probes and enquires the route before you push send. You would know the path and the fee of the payment beforehand. In the upper right corner there are statistics window which is very similar to Faraday which has been developed by Lightning Labs. This has a graphical interface and shows some statistics on your node in terms of uptime, routing volume - how much traffic you get on it and the fee settings. Not only your own node but your peers as well. Every channel and every peer has a score that is compared to each others, to an overall average and also has some pre-settings. It is very nice to spot some outliers which have a high fee or very low uptime and maybe contact them and make the wallet work more efficiently. I could speak a lot about this but if you go to the ThunderHub Twitter account there is a very nice video presentation on YouTube linked there. This was at the last Lightning Hack Sprint, the developer goes through the features there.
The next thing is the Balance of Satoshis. This is the work of Alex Bosworth who manages the Y’alls website and the connected node. He has extensive experience of managing nodes and the tools for it. This is a feature rich command line tool written in NodeJS. It has a wealth of options as you can see. This is just the help menu and the first branch of this tree where you can find out about every command as you go deeper by typing bos <command> help
. It has a lot of things which overlap with ThunderHub. One could be surprised at how much could be conveyed in a text format. It is very interesting to see how it acts to find a route for a payment. It is probing it beforehand. Trying the optimal route and then going with the lowest fee. The Lightning Loop service is implemented into Balance of Satoshis. You don’t even need to have the Lightning Loop installed when you have Balance of Satoshis. You can just call the commands from here and things like increase inbound liquidity or increase outbound liquidity is the equivalent of Looping in and out. It also supports the multipath feature of lnd 0.10. Batching transactions, you can choose the priority and the fees so it is very efficient today to create liquidity or to get your Lightning funds off to a hardware wallet or even use this privacy feature where you can pay onchain from a completely disconnected node by Looping out from your channel. Also it has a rebalancing tool where you can see which channel should be paying and which channel should be receiving the balance. It is intelligent in terms of probing the route and always shows you the fees before engaging in the rebalancing. You can specify the limits it can do. In terms of the amount it is aiming for a 4 million rebalance if you don’t give it any specifics. If that doesn’t go through or if there is not enough capacity it halves it. If that goes through it goes back up to again to 3 million. It tries to get it within a couple of ten thousand sats to an optimal result which can be taken by the peers. Also it has accounting features if you are running a node in production, a merchant for example or a service. You can export a .csv file which you can get into Excel or another more sophisticated accounting software. The unique thing is you can connect to a Telegram bot which you are calling yourself in your Telegram account. It is a very useful and unique feature. It has some privacy implications since the Telegram bot is being called through the clearnet. It is encrypted through SSL but Telegram has the keys so they are able to decrypt these messages, that is how the bot works. And also be able to tie it to other activity on Telegram on your IP address. In any case it allows you to have payments and notifications, be notified about any forwarding event or general activity on your node. This includes when someone opens or closes a channel. It doesn’t matter if it is you or the other peer. Also as a security feature it offers some Lightning security. Every time there is a channel open or closed the static channel backup is written to your Telegram inbox. That is another way to have these backups stored and kept updated. It is being developed.
https://github.com/openoms/joininbox
This is related to the base layer. We need to fund the Lightning channel somehow. Integrating a Coinjoin service was a priority for me because I feel that it is important to use one. I use it myself. It became very obvious that we have a good implementation of Samourai’s Whirlpool such as RoninDojo for example. But Joinmarket has been neglected in terms of the user interface. Already on the previous version of the RaspiBlitz 1.5 we had an install script which has been modified for the Raspbian environment. This could install Joinmarket in one click. Now we have got a menu. There is an extensive guide using the Joinmarket developers’ notes. Now you won’t need to look up any commands anymore to use this command line. Some words on Joinmarket. We have two more popular Coinjoin implementations, Samourai Whirlpool and the Wasabi wallet. Joinmarket is the longest standing, most flexible and completely decentralized Coinjoin implementation. It doesn’t have a central coordinator and the peers are communicating through various IRC servers though Tor. It can do a lot of things. I try to expose most of it through this menu. This menu works similar to the original RaspiBlitz menu. I have been building on a lot of solutions which you had there already. On the upper right side there is a submenu going into the wallet management options where you can generate a Joinmarket wallet which will be connected straight to the Bitcoin RPC. It uses your Bitcoin Core full node which is running on the RaspiBlitz. That is what lnd is connected to as well. You can generate wallets from seed, you can import wallets from another computer, you can recover from seed. You can see the history from past transactions. Going back to the main menu here in the middle you can exercise coin controls. You can freeze and unfreeze individual coins, UTXOs. That is done from the menu as well. You can sweep an account without creating change outputs. With Joinmarket you can Coinjoin on demand and send it to an external address with your chosen amount. But also with this coin control feature you can choose the individual coins you are wanting to spend. In that case you wouldn’t create any change outputs which can be a footgun in terms of Coinjoin privacy and can cause your coins to be tied together later on. Also if you are running a Coinjoin server which is called a maker or a yield generator you can do it from the menu. When you go into the menu you choose your wallet, give the password, it will safely delete it completely and then the generator will be kept running in the background with the Linux system. You have options to look at the logs and the service outputs. Also you can take your nickname which will show up in the decentralized offer book running on your own RaspiBlitz and monitor it locally. An important feature is PayJoin which again has three implementations on the same principle. You can only do it between Joinmarket wallets. This menu helps you to do it. You need to communicate more data than just your receiving address and it will be exposed. A bigger thing that has been a surprise is that you can open the existing Joinmarket QT graphical interface which you might have seen on screenshots or videos on Twitter. It is a traditional graphical interface which you can run straight from your RaspiBlitz without having to install anything on your desktop. You can do this with all major operating systems. This interface will be developed continuously, it can also be updated from the menu itself. If you use Joinmarket I hope you will find it useful and check it out.
Jeff Gallas: Right now Joinmarket is running as a separate service on the RaspiBlitz and it is not really connected to your Lightning node, is that correct?
Openoms: Both are using bitcoind, the Bitcoin Core software but they are using two separate wallets. You would need to fund your lnd wallet separately so you can open channels. You also need to fund or use your Joinmarket wallet which will be a separate one but obviously you can send Bitcoin between both.
Jeff Gallas: There is no automated mixing or channel opening through Coinjoins or something like that?
Openoms: No I don’t know how this would be possible yet unless there are modifications in the Bitcoin protocol. You can Coinjoin and send an amount straight to your lnd wallet with Joinmarket. Then you will be able to channel.
Jeff Gallas: Strange was asking whether there is a presentation on how the Coinjoin GUI works within the RaspiBlitz?
Openoms: That was a demonstration but it has been very much a work in progress so far. Now it is ready to be tested more extensively. You can go onto the GitHub where you can set it up on an existing RaspiBlitz or as a standalone and then connect it to a Bitcoin node remotely even through Tor or LAN. It is self explanatory, you build this interactive guide. It shows what it does and if not there is a helper tutorial which is linked to.
https://github.com/rootzoll/raspiblitz/tree/master/alternative.platforms
Rootzoll: This was a deep dive into what is available or will be available with 1.6. Openoms tell us a bit more about the other hardware you can run the Raspberry Pi software on. You experimented with that and I think you are the best one to tell us. Even though it is called RaspiBlitz it doesn’t mean it is limited to a Raspberry Pi.
Openoms: We are not using the brand we just named it after it. That is how I came to the RaspiBlitz project originally. I had been running this Raspberry Pi 3 and it crashed on me once corrupting my channel database. I even lost a couple of sats because we had no static channel backups then. If the channel state was gone that was it. I got very annoyed with that and looked around for other options. I settled with this Odroid in the lower right corner and has been running for more than a year now. It has a SATA connector built inside of it. The disk is inside and there are no USB connections hanging out. It is the same board as the one on the top. These are Odroid boards. There are plenty of alternatives. The most popular after the Raspberry Pi is mainly ones from Pine64, the ROCKPro64 which is another format. These hardkernel ones are made and designed in South Korea. They have been proved to be quite reliable. We have this red board on the top, this is their newest ARM model which is called the Odroid C4. It has 4 GB of RAM and a couple of advantages over the Raspberry Pi 4. It has four USB 3.0 ports, it also faster 6 core CPU and a very stable power supply, 12V. It would possibly be able to power more than one disk. It is faster, it has better connections, a better power supply. This is important, it is more open source. There is no such thing as 100 percent open source hardware. The most promising project RISC-V isn’t there with affordability and performance. Certainly these Odroids are more open source than the Raspberry Pi designs. That is an advantage for sure. That is something I am playing with. It is actually running, the RaspiBlitz 1.5, there is the screen which has the resolution of the Raspberry Pi 3. It is a touch screen as well and needs some experimentation to get the same functionality out of it. Also there have been plenty of other boards that people have been building on. We have seen that we can run these services with a 1 GB of RAM machine. I would rather have 2 GB which is sufficient but 4 GB is even more future proof. We also have the 8 GB version of the Raspberry Pi 4. I am sure there will be other boards offering this. As we go up in price we can scale up wherever. At some point there could be error correction come into the picture when we are thinking of putting significant funds on these things. What we could have and is desirable is a speedy connection to the disk. A USB 3.0, SATA or PCIE connector, smaller SSDs. To use a SSD is important we found out. The sync time is not compatible with a spinning disk. It is also less prone to corruption from physical shocks. I would really recommend to use a SSD. I would go with a 1 TB one, that is what is recommend on the shopping list. 500 GB is still usable for a couple of months but then afterwards if you want to have multiple services like a Electrum server on top of your Bitcoin blocks it would be filling up and stop working. Rootzoll has been building this experimental feature using a better BTRFS RAID where we are mirroring the valuable data like the Lightning database and other data that is not the blockchain on a small thumb drive. We could actually use another SSD for that as well. Practically you need to have a case. It is nice to have a screen though I was very happy using my Odroid without a screen because it is being tucked away in the corner. It is working but otherwise you are from monitoring from the Terminal or one of these web applications we are running. If you feel like it and want to try another board it is certainly possible. I get this question a lot, if you can do it. There is no question that we can do it but it might need a bit of debugging and customization for various things. I have been working mostly with the Armbian image repository. It is a Linux distribution. It is the unbranded version of the Raspbian, both originating from the Debian Linux which is one of the most popular Linux distributions. Working on the ARM processors obviously. It has a wealth of resources in terms of how many boards are able to run on Debian. We have figured out most of the compatibility, same with Ubuntu which is again based on Debian. Lots of providers like HardKernel or Pine64 are supplying Ubuntu as the factory image which is most recommended and most supported with their boards. RaspiBlitz works on that as well. If you want to start you just go into the README or search the FAQ. There is a link for alternative platforms and there is a small README there how to do this. You need to set up the default image and then choose the most compatible one and run the manual SD card build script which is the same script we run when we are building a SD card image for you which you can download. From any point from the open, freely available source code you can build a SD card for yourself. The nice thing is when you do it for yourself you can put another base image, not just the Raspbian. Armbian is very compatible with our scripts and package management and so on. I am always excited to have multiple options.
Jeff Gallas: Strange is what asking what problems may arise with the platform ROCK64, is there any support?
Openoms: ROCK64 came out between the Raspberry Pi 3 and 4. This is not the same as the ROCK PRO64 which is a powerful and newer board. The ROCK64 had in my experience a lot of Linux kernel level issues with drivers and freezing. It made calculation errors probably because of faulty memory chips. I have one and I could watch a video on it or open the desktop but it couldn’t sync the blockchain. I stopped working with the ROCK64 because you probably need to choose it very carefully and you might need to buy 3 boards to have 1 working properly. I don’t have a good experience with those. If you have a good one then this manual SD card building process will work and it will be compatible. The good thing is the non-Raspberry Pi distributions are 64 bit and we do have compatibility with 64 bit in the scripts and in the installation scripts. It shouldn’t stop you trying but I would recommend another model.
Jeff Gallas: One question is today you can use BTRFS, will a 32GB flash USB be enough for the whole time? Also BTRFS recommended RAID feature or is there any experimental experience with recovery?
Openoms: Rootzoll implemented this function but I do test it. I have a test node which is Raspberry Pi 4 running with a BTRFS disk. It is maybe the fourth iteration now, I am testing. It is reliably recovering. I would be very careful using flash drives because the flash drives are even worse than a good quality SD card in terms of what write cycles they can take. If we are putting the lnd database there which possibly has thousands of write events it can die in a couple of months if it is a busy node. The last thing you want to have is a dying disk. If you look on the GitHub I have written up some recommendations of what flash drives to look for that are better quality. There are even USB SSDs that are available, slightly more expensive, 30-40 dollars. Those could take this kind of activity but they might need more power. That is something that we need more experience with. Using some external power or a more reliable power source like with the Odroid boards, I would think a second disk would suffice. There is not much point mirroring the blockchain because you can run another node and if you need to you can copy it over. It is always available for download. But for the lnd database and other valuable information like BTCPay invoices, Joinmarket wallets, every application that has unique settings, it would be in this application data folder which is mirrored. We are far lower than even 1GB, it is certainly enough. The smallest SSD which you can hook up to one of these custom setups would be sufficient. There is more research needed on this but it is very exciting to look at.
Jeff Gallas: Are NVME disk with USB adapters supported?
Openoms: Supported in terms of hardware? It depends. If it works with the Raspberry Pi 4. It has some issues with a lot of USB adaptors, I think you need to find the right adaptor. Then you would be able to power it. It is just that there is this standard called the UASB I think. It is the depth of the USB 3.0 standard which allows quicker transfers but it is not implemented properly in many of the adaptors. That could cause issues with the Raspberry Pi 4. You’d need to try. The disk would be, it is the adaptor that would be the problem.
I want to get back into the user experience, what you can do with your RaspiBlitz and what the problems are still to be solved from the user experience side. What you normally want to do is you have your RaspiBlitz running at home but you want to use it while you are on the street. You are in a shop and you want to pay from a mobile wallet. What can you do, there are mobile wallets around, very pretty ones like the Zap wallet here or Zeus here. You install them on your mobile phone and then you connect it, pair it to your RaspiBlitz at home using the lnd REST API or gRPC API. We will get into the problems a little bit later.
Another thing you can connect to your RaspiBlitz is other hardware. This is one example why it was so important besides software projects, you can try out on a Hacksprint or a Hack Day. We use this Point of Sale the M5StackSats from BTCSocialist at Room77. It is very nice that it is working in the background with a RaspiBlitz. Or there are do it yourself Coin ATMs you can connect to your RaspiBlitz. It is a base for your hacking projects.
I want to give an overview of what RaspiBlitz can do for you personally. Why should I run a full node? Why should I build something like that? First of all it is a great learning experience. But what services do I gain? The first thing most people understand and is very common now is you want to validate all your transactions yourself because you know “Not your keys, not your Bitcoin.” I like to say “Not your node, not your rules.” If you don’t run your own full node you are using a full node from somebody else. You connect to it in a lighter way and you accept that this node is checking the rules. If it comes to a fork situation, somebody wants to another Bitcoin with different rules like we saw with Bitcoin Cash, if you don’t run a full node you don’t decide, you let the other services decide which way to go there. This is the most important quality, you check the rules on the network. You run a full stack from your home. This is definitely one big takeaway here. With this setup you also gain privacy. If you use other services, if you have a hardware wallet like a Trezor and you want to use it you normally go to trezor.io and click on the wallet. Your private keys are kept in your hardware wallet so they cannot send your coins somewhere but you tell them about your public keys so they can show you your balances. This is where you leak privacy information. If you do it all on your own node you keep it in your own area so you are not leaking to the outside privacy information. If you look into Joinmarket services that you can run yourself you can gain privacy in other kinds of ways. Then a lot of people ask if I can route payments on the Lightning Network. Because it is always on you can be part of this active routing network. Maybe you can earn some fees as a routing node. Don’t expect too much here. There is a lot of work and a lot of liquidity you need to put in the right place to get somewhere, not even get rich. The RaspiBlitz can help you be part of that routing network and maybe if you are really good at it earn some satoshis from fees. It is getting very trendy to run a full node. I like this because it teaches people a lot. But I don’t think everyone needs to run a full node at home. It should be possible for everybody to run a full node if needed. If a fork situation comes up it should be possible to set a full node up in a week and run it yourself and decide for yourself. Stadicus, who wrote the RaspiBolt tutorial, wrote an article on why we need Bitcoin full nodes, economic ones. What should be kept in mind is you have voting power on the rules if you have some economic value produced from your node. A lot of small nodes with economic activity can together have a huge say with consensus rules overall. If you are interested in that perspective check out the article from Stadicus. This is what the RaspiBlitz can do for you from this perspective.
There is another area of use for your RaspiBlitz, your RaspiBlitz for your friends and family where you can be the tech savvy person. You can help them to be part of this ecosystem. You run this one heavy full node here and your friends and family can use lighter software, lighter wallet setups. You improve their privacy on payments. You can provide the Electrum server they can use for their hardware wallets for example. Or even for being connected to the Lightning Network, you be the hub they always use when they do a payment. You are their shield for path analysis. You can have this attack scenario where you have Lightning nodes trying to monitor metadata of payments out there. If you are the first hop for your friends and family on this path they can trust you and you shield them. You can even provide good connection to the Lightning Network. To have a good connection to the Lightning Network you have to build up multiple channels so that you have a good connection to every area of the Lightning Network. To route around big nodes if you want to be more on the edge. You have to build up multiple channels for this. Your friends and family probably just need this one channel to your node and then they can use your good connectivity to the rest of the network .This makes it easier for friends and family to be part of it in a more relaxed way. You will not attack those channels so they don’t have to run a watchtower on these channels. It is a friends and family situation. Never trust too much, it is money, but you can relax a bit on the attack scenarios. If people are losing their channel database you will be friendly on recovery and close deleted channels for them even if they have lost all their channel data. You can be helpful to your friends and family if you run a RaspiBlitz and let them use your services.
Let’s look at what this means from a technical perspective. You are running this node in your home. This is a classic setup. You have a router there and your RaspiBlitz is running behind your router. There is always the question of how friends and family make an easy connection to your node. This is something we want to look into. I think we have finally found a practical solution for this. Let me show you in detail.
This is a standard situation. Here you have your RaspiBlitz running in your local area network and then you want to connect your mobile wallet to it. To have a remote control on your smartphone. This works when you are in your local network. If your smartphone is connected through wifi you need to make sure it is on the same router connected to the LAN cable that is here on your RaspiBlitz. Normally this is the default. This works ok. You can pair now your mobile wallet with your RaspiBlitz. But in this scenario it just works in your local network. If you move out of here onto the public internet there is a router here and you have a NAT. You are shielded from the outside. Your mobile wallet will not be able to connect anymore. Even if you switch your smartphone onto a mobile data plan and not to wifi you lose this connection. This is not a very good user experience because you want to use your mobile on the go. The first thing to do is if you are more technically experienced and you have access to your router, you know how to login, you have the admin passwords and can do port forwarding. Your route has a public IP. You can reach this IP with your mobile wallet and then say everything that comes on this port here should be forwarded to my RaspiBlitz. You can see this is already a manual setup and not everybody feels comfortable with it. Then you need to keep in mind that your public IP may be changed every 24 hours because you are not guaranteed a fixed IP from your internet service provider. You have to also think about a dynamic DNS to configure and set up. All this is possible with the RaspiBlitz, it allows you to set up a dynamic DNS server for example but again from a user experience it is a very technical experience. You have to have access to the router. If you are using wifi from your neighbors you will not be able to set something up like this. Technically possible but also not the best user experience. What else could we do here? A lot of people said why not use Tor here? Tor has this very nice thing if you run a RaspiBlitz behind Tor, it is able to tunnel through your router. It connects to the Tor network and you have this onion address that is a hidden service address, where lnd for example is running. You can use on your mobile phone an adaptor like the Proxy app you install or software that you are using, the wallet for example, has to be able to support Tor. Then it can handle those Tor addresses because they are not usual for normal internet services. You need special software playing together with your mobile wallet. This is not easy for configure for everybody. I have had some problems setting up those proxies right on mobile phones. Sometimes something is not working and it is fiddly. You are maybe limited in your wallet choice if they have to support Tor. All those things make the user experience not that good. There are devices out there, if you think about those hacker projects, like ESP32 POS, where there are no Tor libraries that you can run. This device would not be able to reach your RaspiBlitz. It is a step forward but your options are limited and the Proxy app is also not perfect. What we came up with in the last Hack Sprint and we have integrated this into the RaspiBlitz for the upcoming version 1.6 is the idea of a IP2TOR bridge server. I think Frankie for putting time into this. You still run your RaspiBlitz behind Tor, it is a hidden service, but there is another server out there you can configure for yourself that is running Tor so it can connect, you can make this connection. Then this server has a public IP and it can translate from a normal public IP and a port. It directs or forwards all traffic and makes this tunnel possible. This is working. All your wallets know how to speak with the IP address format, also those little devices, they can do this. In this scenario not everybody has a server out there to set up with Tor. This is super nerdy to do. Frankie has been working on building a shop system on top of it. People running those servers can rent them out for people who want an easy solution for this. What the RaspiBlitz now has here is a subscription model you can choose. With Lightning microtransactions you can connect to a IP2TOR shop server and say “Show me all the bridges you have available.” You pick one and you rent a port address on a public IP and pay it every 24 hours. First of all this is perfect for Lightning microtransactions because we already have a Lightning node, it is funded, it can pay services. Two other good things that come together here is that if you pay this service over here the person you pay with Lightning doesn’t know your identity. You can pay anonymously for this service. Also on the other side because you are running Tor you pay without giving a personal ID or IP, you tell the service “Forward to this hidden service address” which you can create completely anonymously shielded through the Tor network. You can use this service with very little risk of giving any personal data. You just pay it and then you try it out. If it works for you that is perfect. It is better than using a VPN. You can have similar bridging services with a VPN but with a VPN you always have to give your public IP. This service is running behind Tor so it is very well shielded on a privacy level. This IP2TOR shop server is completely open source. Everybody is free to set up their own shop. On the RaspiBlitz when you say “I want to make a subscription” you choose the shop address. At the moment we plan to have a Fulmo shop for these IP2TOR services, that is the default. But you can exchange it for a different shop you trust or is better to use. This is a completely open source solution that you are free to point to your own service.
Because this is a big feature that will be in v1.6 I want to give you a view, it is not finalized. There is a release candidate out but this is for the most technical people. You can find it in the RaspiBlitz branch if you are interested. What is new in this version? A subscription menu. In your main SSH menu you can have “Show me subscriptions.” In the beginning there are no subscriptions but you can start a new one. There is the IP2TOR subscription you can start. Maybe later on there can be other kinds of subscriptions like for watchtowers or domain services. Keep in mind you can use this model for other kinds of services. You go to the shop URL that you can change. You choose different options there, there are a lot of different services there. They can have different prices, maybe one is Sweden, one is Germany and it says in the description. You make your choice and say “I want to subscribe.” You see this information here. You will get a IP, it will be forwarded to your service over here. These are the costs for the first 24 hours, 40 sats, and with every renewal it will cost you a different price. Those are the terms of service. You agree and then this service is connected. This is when you set it up for arbitrary kinds of things. If you want to connect a mobile wallet it will ask you “Do you want to connect it manually with port forwarding or something else? Or do you want to use this IP2TOR subscription?” You say “Yes”, you pick your service, you agree and then it shows you the pairing code. The pairing code is the public IP, the IP2TOR server IP, you pair it with your phone and you should be connected. This is the user experience we are aiming for with the new release. We hope this makes it easier for a lot of people to connect their mobile devices. Later on there could be other things.
In the beginning we concentrate on the lnd REST API and gRPC API, these are the ones that are mostly used by the mobile wallets or other devices you want to connect. There is also this Let’s Encrypt service in the new version. Let me show you what you can do with this one.
There is the gRPC and the REST API there, they are protected normally if you connect to your RaspiBlitz with the TLS certificate that is created by lnd. You give this certificate to the mobile wallet with a QR code while you pair. Even if this connection goes through the public internet it is already encrypted when you talk to your RaspiBlitz. However if you now want to make other services available like BTCPay Server or LNBits you have this last mile between the IP2TOR and the web browser that people use that maybe goes unencrypted. You want to use HTTPS here. This is something to keep in mind because we really want to have this secure connection so this IP2TOR server can’t look into the traffic and just forwards to your RaspiBlitz. It should be a dumb translation server and tunneling server. This is what is next. Maybe not in 1.6 but it is something we maybe aim for in 1.7. To give you the idea of how you can put your LNBits or your BTCPay service out to to the public to use with normal web browsers and normal smartphones, we want to have HTTPS here. You could use a self signed certificate but then those web browsers will say “Do you trust this insecure thing?” It is not good for people. There is also the danger that the IP2TOR server could be a man in the middle and attack this connection. This is something we don’t want. What is possible to use in the future is use Let’s Encrypt here. The idea is you can get a valid subscription, a valid certificate from Let’s Encrypt that you hand out between Let’s Encrypt and the RaspiBlitz. Then the users can just call it like any other web service. It gets served securely behind Tor. You don’t expose any personal information here and people can use it securely through HTTPS through the browser. This is something we are aiming for in the future. This would enable stuff I will show shortly. But we have to figure out all the details. Keep in mind that the user IP can maybe be monitored by the IP2TOR server. Don’t get too crazy with what you do with this service. There may be leakage. Make sure you pick a trusted IP2TOR server so that this leakage of user IP is not too critical. You are safe behind Tor, you pay with Lightning, you are safe. But this is maybe a place where your users can be monitored.
A lot of people say they want to run a full node to support the network. That is a good course but you have to keep in mind that for example in Germany we have a lot of full nodes over here, just to keep it running in the background, it is maybe not that effective. It is effective for example in other countries like those in Africa, there are not many full nodes being run there. If you run a full node there it is definitely helping the network and spreading it locally. To really support the network it needs to have economic value or give technical options like using satellite, LoraWAN, Wifi-Mesh, to make it stronger and more robust, this infrastructure of full nodes out there. This SpaceBox project that is based on the RaspiBlitz, there is a talk on this next week. I am very glad to see that there is a project to spread full nodes in the Africa. There are ideas to put it behind solar panels. And in the future maybe it is possible to combine it with satellites or other wifi mesh networks, this would really help the technical infrastructure of the network.
Another way to make your RaspiBlitz more economically valuable is to open it up for your local community with onboarding and education. There are two concepts I want to quickly introduce to you. They are maybe not completely finished but they look like good approaches. One way to onboard and educate local users are Lightning vouchers. Maybe you remember in the beginning of Bitcoin giving people paper wallets. This was always a great way to onboard people and give people Bitcoin. The journey starts with the first Bitcoin or satoshis you own yourself. You get handed them and now you are responsible for them. This is a good first learning experience. We want to see how we can make this possible with the RaspiBlitz for your local community for Bitcoin over Lightning. The other thing is how we can get more merchants in your local community to accept Bitcoin. There is the concept, the name is not fixed, called “Cash in the Bag”. A paper POS card that could make it very easy for your local merchant to accept Bitcoin. You help them by running a RaspiBlitz. Let’s take a look here how this could work.
We tried this out at the Bitcoin Assembly, … Communication Congress. There is a prototype version using LNBits. LNBits is this extra app that you can activate on the RaspiBlitz. It gets developed more and more. We can already see where this could go. There is a plugin called LNURL. This can create a lot of these QR code vouchers which are LNURL vouchers or codes but also have a fallback mechanism such that where you scan them with a normal mobile wallet and you don’t have any Lightning wallet installed it opens a normal web page served from LNBits on your RaspiBlitz. It is more like an instant wallet in your web browser. If you build QR codes here where some satoshis as a voucher are granted to you, you can hand them out. If people scan it they get an instant wallet and from this wallet in their web browser they can maybe spend it directly somewhere or they can transfer it to a mobile wallet. This is very interesting, to make these vouchers possible. Once you have these QR codes you can print them out on stickers, you can design nice fliers in your local language or for your personal situation. You can even hand them out by hand or put them in the post. Then people can try it out at their local shop if they accept Bitcoin on Lightning or they can transfer it to their non-custodial wallet controlled by them. They now really own those sats. This is the idea of spreading Lightning vouchers in your local community. It is possible to run your RaspiBlitz, have LNBits on there, put some satoshis on there, create those vouchers and hand them out to your local community.
The Paper Point-of-Sale Card is another plugin in LNBits called TPOS. You can create small accounts. You have this one Lightning channel and you can chop into little custodial accounts which you control on your RaspiBlitz. What you can do is for one of those accounts is create a paper point of sale card. You get a QR code and in this QR code is a web HTTPS URL that everyone can call on your RaspiBlitz. When you scan this and open it up on your smartphone it looks like a simple point of sale. At the point of sale people type in a number like 1 euro, you see how many sats it is and then you create an invoice. People can pay to this and this will be then credited to your LNBits account which is running on your RaspiBlitz Lightning node. This is a very easy way to give out a QR code and people scan it on their phone and they have a PoS on their hands.
How does this work? You choose a local store that you trust, there is some social trust involved in this model but it is a local community so you will find people there. Let’s say you have your cash register. What you do is take this bag, there is already some cash in there but it is still in a bag, there is a card in there also. You put it all in the bag and you have it lying around in your register waiting for somebody to come in who wants to pay with Bitcoin over Lightning because they saw a sticker on the window. What the merchant will do is take this bag out, take out the QR code and there are some instructions on the card. You follow the instructions. The merchant will scan the QR code with a smartphone, opens up the temporary point of sale and punches in how much the person needs to pay for this stuff. He creates an invoice, shows it to the person. That invoice gets paid and there is payment confirmation. The merchant takes out the cash that the customer just paid and puts it from the bag into the normal register and treats everything else as if the customer paid with cash. There is nothing to be modified in the bookkeeping process, it is very easy for the merchant to do. All this is technically running in the background on your RaspiBlitz. You just gave the merchant this card here and this bag with some fiat in there, 20 euros or 20 dollars. This is enough in the beginning to pay these voucher amounts. You gave out vouchers that are valid for bubblegum. Now people come into this store to buy bubblegum with Bitcoin. 20 euros is enough for that. You can build up this learning experience for your local community with your RaspiBlitz running.
This is an overview of what is coming up with 1.6. Hopefully by the end of the month we will have it available for you. There are a lot of updates from existing apps. There is some new stuff. This is mostly on the web server thing, these subscriptions, the IP2TOR bridge. There is the Balance of Satoshis that Openoms was showing. The JoininBox is on there. The ThunderHub, the Let’s Encrypt client for fiddling with HTTPS. There is a fix for the Dropbox static channel backup. If you have the 1.50 still running and you are using the Dropbox static channel backup maybe check out the already available 1.5.1 update that is available on the RaspiBlitz GitHub because it fixes a bug for this backup situation. It will be definitely be part of 1.6. We recommend the Raspberry Pi 4 with 4GB as a standard package. It will still run with your older hardware even on a Raspberry Pi 3. Don’t be concerned, you will be able to update.
https://github.com/rootzoll/raspiblitz
We have had 70 contributors. If you are running a RaspiBlitz and you have something to improve check out the Issues. Take a look at some folders here. Most scripts that are running on the RaspiBlitz are in raspiblitz/home.admin. The setup scripts are numbered so you can go through them. There is another folder called config.scripts. This is the collection of feature scripts where you can turn on or off features or configure your system. If you have some software you would like to add I would recommend you look at this config.scripts folder. You can see examples of other services, what is needed to integrate a new app into the RaspiBlitz. It is always great to try out stuff on your RaspiBlitz but if you want to have it so that every update of the RaspiBlitz, it is still there and still working, it is best to contribute back to the project and have it as a feature that can be turned on or off with config scripts. I invite you to take a look and if you want to contribute additional apps you would like to see on the RaspiBlitz head in this direction.
Jeff Gallas: There is a question on whether the Dropbox static channel backup on the new Dropbox API worked.
The fix worked. On the v1.5.0 there was a problem we found. It resulted in a zero byte file getting stored to your Dropbox. Then you have a recovery situation where you don’t have a valid channel backup there. This is fixed with 1.5.1 with an easy update.
Openoms: There has been a SCB bug in lnd itself which is being fixed with the next 0.10.2 version. This was overwriting the existing SCB with a zero byte in certain situations. That could have contributed to our problem.
Rootzoll: There was also one thing on our side that I found. Interesting that two projects found the same bug from different directions. At least on our side the transferring is fixed now.
Community-maintained archive to unlocking knowledge from technical bitcoin transcripts