Snap setup

How to set up a Lisk Core node via Snap.

Pre-installation

Supported Platforms

  • Ubuntu 18.04 (LTS) x86_64

  • Ubuntu 20.04 (LTS) x86_64

Not officially supported but should still work
  • Any Linux system running systemd and AppArmor

Snap

Snap is a software package management system created by Canonical. Snaps are sandboxed, self-contained applications.

Create a new user

To run and manage a Lisk Core node in the future, please create a separate lisk user as described below:

  • Ubuntu

  • MacOS

The lisk user itself does not need any sudo rights to run the Lisk Core.

sudo adduser lisk (1)
1 Create a new user.

It is not necessarily required to set up a lisk user, especially when you are running a local instance for development purposes.

However, if it is required then it is recommended to create the user using the MacOS GUI.

Installation

Install Lisk Core as a snap:

snap install lisk-core

Start

After successful installation, start the node with the following command:

  • Mainnet

  • Testnet

lisk-core start --network mainnet

The default log levels for Mainnet are:

"logger": {
    "fileLogLevel": "error",
    "consoleLogLevel": "none"
},

So if you start the node, it won’t show any logs in the console. This is the recommended setting for reducing the number of logs for a running node. However, to verify that the node started correctly, update the log levels in the config to info or lower.

Alternatively, start the node with the following flag:

lisk-core start --network mainnet --console-log=info

See the Managing logs guide for more information about logging.

lisk-core start --network testnet