<img width="730" height="410" src="http://i1.wp.com/globallife365.com/wp-content/uploads/2016/08/lisk_bg2-e1471918613469.jpg?resize=730%2C410" alt="Lisk" >
<h2>Setup Lisk Node</h2>In this post I will review how to setup a Lisk node and a Delegate. I will be using Digital Ocean VPS running Ubuntu 16.04.1.
Lisk is currently supported on the following operating systems:
<ul>
<li>Linux (x86_64)</li>
<li>Linux (i686)</li>
<li>Linux (armv6l)</li>
<li>Linux (armv7l)</li>
<li>Darwin (x86_64)</li>
<li>FreeBSD (amd64)</li>
</ul>
If your architecture is not supported yet, you can try building your own packages using the <a href="https://github.com/LiskHQ/lisk-build">lisk-build</a> automated package building tool.
To check your operating system run the following command:
<pre><code>uname -sm</code></pre>
<h3>Install curl, wget, tar, sudo, unzip, zip</h3>
Run the following code block:
<pre><code>if [[ -f "/etc/redhat-release" ]]; then
yum update
yum install curl wget tar sudo unzip zip
elif [[ -f "/etc/debian_version" ]]; then
apt-get update
apt-get install curl wget tar sudo unzip zip
fi</code></pre>
<h3>Create a lisk user and set a password</h3>
<pre><code>useradd -d /home/lisk -m lisk
usermod -a -G sudo lisk
passwd lisk</code></pre>
<h3>Setup the sudoers file</h3>
<pre><code>visudo</code></pre>
Paste the following at the bottom of the file:
<pre><code>%sudo ALL=(ALL:ALL) ALL</code></pre>
Hit: Ctrl+ X Then: Y to exit and save
<h3>Update the systems Locale</h3>
<pre><code>if [[ -f "/etc/redhat-release" ]]; then
localedef -v -c -i en_US -f UTF-8 en_US.UTF-8
localectl set-locale LANG=en_US.UTF-8
elif [[ -f "/etc/debian_version" ]]; then
locale-gen en_US.UTF-8
update-locale LANG=en_US.UTF-8
fi</code></pre>
<pre><code>reboot</code></pre>
After the restart su to lisk user created earlier:
<pre><code>su - lisk</code></pre>
<h3>Download and Install Lisk</h3>
<pre><code>wget https://downloads.lisk.io/scripts/installLisk.sh
bash installLisk.sh install -r main
cd lisk-main
source env.sh
echo "source $(pwd)/env.sh" >> ~/.bash_profile
</code></pre>
<h3>Create new account</h3>
To access the Lisk web client open a browser and go to:
<pre><code>http://[ipaddress or domain]:8000/</code></pre>
Click on "NEW ACCOUNT" button and follow the steps.
<h3>Save the passphrase at multiple secure locations!</h3>
After confirming the passphrase by entering it again you will be logged in into your account.
<h3>Register as a Delegate</h3>
Click on "DELEGATE REGISTRATION" at the top right corner. Choose a delegate name. There is a fee of 25 LSK. Only the top 101 delegates will get rewards for forging. All fees are shared equally between the top 101 delegates. In the future delegates that are outside of the top 101 can secure side chains for different applications on the platform.
<h3>Enable Forging</h3>
Stop the running Lisk node and edit the config file:
<pre><code>bash lisk.sh stop
nano config.json</code></pre>
Find the following section and enter your passphrase:
<pre><code>"forging": {
"secret" : ["YourDelegatePassphrase"]
}</code></pre>
Start Lisk:
<pre><code>bash lisk.sh start</code></pre>
Some helpful commands:
<pre><code>bash lisk.sh stop
bash lisk.sh start
bash lisk.sh restart
bash lisk.sh reload
bash lisk.sh status
bash lisk.sh logs
bash lisk.sh rebuild
</code></pre>