flnd
flnd is the engine that powers the Flokicoin Lightning Network. It is a full-featured daemon that acts as both a Flokicoin wallet and a Lightning Network node.
If you are a developer, a node operator, or a power user who prefers automation and a powerful command-line interface, flnd is your choice.
flncli tool or a robust gRPC/REST API.Quick Installation
flnd is distributed as a pair of binaries: flnd (the daemon) and flncli (the controller).
- Download: Go to the flnd Releases page and grab the version for your system.
- Extract: Unpack the archives and move the binaries to your path (e.g.,
/usr/local/binorC:\Windows). - Verify:
flnd --versionflncli --version
The Onboarding Lifecycle
Operating flnd follows a standard lifecycle: Start Daemon → Create/Unlock Wallet → Sync → Operate.
2. Starting the Daemon
Before you can interact with your wallet, the flnd daemon must be running. By default, it will use DNS seeds to find peers and connect to the network using Neutrino.
Simply run:
flnd
What to look for in the logs:
[INF] LTND: Waiting for wallet encryption password.
Use flncli create to create a wallet or flncli unlock to unlock an existing wallet.
2. Creating Your Wallet
Open a second terminal window and run the initialization command:
flncli create
You will be guided through several critical security steps:
- Wallet Password: Enter a password (min 8 characters). This password encrypts your local
wallet.dbfile. You will need it every time you start the daemon. - Cipher Seed: You will be asked if you have an existing seed to import. For a new wallet, choose No (
n). - Seed Passphrase (Optional): You can add an extra "25th word" for additional security. If you don't want one, simply press Enter.
- The 24-Word Seed: The terminal will display your unique 24-word recovery phrase.
- Write it down: Use physical paper.
- Offline only: Never take a screenshot, photo, or store it in a digital file.
- Ultimate Backup: This seed (and your optional passphrase) is the only way to recover your on-chain funds.
3. Static Channel Backup (SCB)
While the 24-word seed restores your Flokicoin balance, it does not automatically restore your Lightning channels.
- File:
channel.backup - Location: Inside your data directory (e.g.,
chain/flokicoin/mainnet/). - Action: Every time you open or close a channel, this file updates. You should back this file up to a separate device or cloud storage to ensure you can recover Lightning funds.
4. Unlocking the Wallet
Every time you restart the flnd daemon, you must provide your wallet password to decrypt the local keys:
flncli unlock
Pro Tip: Auto-Unlocking
To allow the daemon to start and unlock automatically (useful for servers), you can use a password file:
- Create a file containing only your wallet password (e.g.,
~/.flnd/pwd.txt). - Start the daemon with the flag:
--wallet-unlock-password-file=/path/to/pwd.txt.
Network & Connectivity
To be a healthy part of the network, your node needs to talk to others.
Port Forwarding
If you are running flnd behind a home router, you should forward these ports to your node's local IP to allow external connectivity:
- 5521 (TCP): The standard port for Lightning Network peer-to-peer communication.
- 10005 (TCP): The gRPC port used by
flncliand external dashboards like Lokihub. - 5050 (TCP): The REST API port for web-based integrations.
Data Directory
By default, all data (logs, database, macaroons) is stored in:
- Linux:
~/.flnd/ - macOS:
~/Library/Application Support/Flnd/ - Windows:
%LOCALAPPDATA%\Flnd\
You can move this to an external drive using the --lnddir=/path/to/data flag.
Basic Operations
Once unlocked, the daemon will begin syncing with the Flokicoin network. Use these commands to manage your funds:
Check Sync Status:
flncli getinfo
Generate a SegWit Address:
flncli newaddress p2wkh
Check Balances:
flncli walletbalance # On-chain Flokicoin
flncli channelbalance # Lightning Network liquidity
Send Flokicoin:
flncli sendcoins --addr=[ADDRESS] --amt=[AMOUNT_IN_LOKI]