Intro

Blockchains are comprised of computers that people refer to as 'nodes'. Some blockchains have different sub-concepts inside of this for the types of nodes in their system. For example, Ethereum has 'full nodes' and 'light clients' which differ based on how much of the blockchain each computer stores.

We see that these different types of computers start to take on different roles like people do in an organization. Full nodes are generally for miners, block explorers, and original developers, while light clients are for more casual users who want to contribute something to the network but not get too involved.

Similarly, Lamden has to central roles that need to be filled: Masternodes and Delegates.

However, on Lamden, there is a specific purpose to both types of nodes. The system cannot behave without a consortium of both.

Transactions go from being submitted, to getting processed, to getting added to the blockchain. We seperate these duties into two parts and give one part to each type of node. The beginning and finalization of transactions happens with the Masternodes. The execution and outputs of the transactions occur with the Delegates.

Masternodes

Masternodes serve as the entry-point to the network and the storage units of the full blockchain history. They do not ever execute any transactions. They make sure that the integrity of the network is secure by providing copies and an open web API of the blockchain for the public to verify. They also

Delegates

Delegates are the work horses of the system. While they do not need a lot of disk storage, they do need fast processors and a lot of memory. The requirements of a Delegate, in terms of hardware, is therefore much more stable. Delegates get cryptographically verified transaction batches from all Masternodes, process them, and return the results.

Installing

You will need a fresh computer with Ubuntu 18.04 running on it. Other flavors of Debian should work but are not officially supported, so you must be comfortable with troubleshooting if you want to use another distro.

1. Update and Install Pip3 (Python Package Manager)
sudo apt-get update
sudo apt-get install python3-pip -y
2. Install MongoDB

Read the official installation guide here: https://docs.mongodb.com/manual/tutorial/install-mongodb-on-ubuntu/

If you're installing on the cloud, some cloud providers have a problem with their entropy pools 'drying' up. This has to do with random numbers and the cryptographic library (libsodium) Lamden uses. Libsodium uses the blocking /dev/random which can get clogged in cloud setups.

If you notice that when you are starting up your node that the software hangs for random intervals sometimes before starting up normally, this is probably the problem. We recommend simply installing a local entropy pool.

sudo apt-get install haveged -y
systemctl start haveged
systemctl enable haveged
4. Install Lamden
pip3 install lamden

How to use the CLI tools to start your node and connect to the network are explained in Node Management. First, you need to get elected into the quorum before you can join.

Becoming a Node

This is a step by step guide for users and current committee members (masternodes and delegates) for how to vote people in and out. You will only be accepted into the quorum when either the Masternodes or the Delegates add another sear to their committee.

All of the following steps are transactions performed on the Lamden blockchain, so use the GUI Wallet or tool of preference.

1. Approve the stake amount to the election contract of the node type you want to become.

To do this, send only one transaction to the network that has the appropriate set of parameters. * If you want to be a delegate, send the first transaction only. * If you want to be a masternode, send the second transaction only.

Contract Name Function Name Amount To Stamps
currency approve 100_000 elect_delegates 100_000
currency approve 100_000 elect_masternodes 100_000

2. Register yourself with that election contract.

This will withdraw your stake. Make sure that you are certain before continuing.

To do this, simply call the register function on the appropriate election contract. * If you approved elect_delegates, send the first transaction only. * If you approved elect_masternodes, send the second transaction only.

Contract Name Function Name Stamps
elect_delegates register 100_000
elect_masternodes register 100_000

3. Get people to vote for you!

Now that you are successfully registered, you need people to vote for you. Announce your intentions to become a node in our community, and share your verifying key so that people can vote for you. If you want to vote for other people, you first have to approve a small amount of tau for the rate-limiting vote fee (20,000 stamps).

To do this, follow step 1 again, but put a smaller number of tau:

Contract Name Function Name Amount To Stamps
currency approve 10 elect_delegates 100_000
currency approve 10 elect_masternodes 100_000

After that, simply vote for the person you want by sending a corresponding transaction:

Contract Name Function Name address Stamps
elect_delegates vote_candidate VK in Hex String format 100_000
elect_masternodes vote_candidate VK in Hex String format 100_000

Once you get elected, you will be expected to assume certain roles and responsibilities a member of the network. Read about them in the Node Management section.