Installation

Following section describes how to install the Neuron software package on a Linux system device.

Download

Neuron software package is available in EMQ website https://www.emqx.com/en.

Package Name Architecture System
neuron-x.y.z-linux-x86_64.tar.gz x86 64-bit
neuron-x.y.z-linix-armv7l.tar.gz ARM hardware floating
neuron-x.y.z-linix-aarch64.tar.gz ARM 64-bit

For the version number x.y.z, x is major version number which may change if the entire system structure enhancement, y is minor version number which may change if there will be some additional features. z is the patch number for bug fix in the Neuron software.

Pre-requisites

The following Linux distros or devices have been tested for Neuron.

Linux distros or devices Neuron package required
Debian package system for x86_64
Ubuntu 20.xx
Ubuntu 18.xx Desktop
Ubuntu 16.xx Desktop (install openssl1.1)
Ubuntu 14.xx Desktop (install openssl1.1)
neuron-x.y.z-linux-x86_64.tar.gz
Redhat package system for x86_64
Centos 8
Centos 7.x (install openssl1.1)
neuron-x.y.z-linux-x86_64.tar.gz
Raspberry Pi 2
Pi 4b+
Pi 3b+
Pi 2b+ (install openssl1.1)
neuron-x.y.z-linux-armv7l.tar.gz
armv7l Ubuntu Linux System neuron-x.y.z-linux-armv7l.tar.gz
aarch64 Ubuntu Linux System neuron-x.y.z-linux-aarch64.tar.gz

Note: Some Linux distros require openssl1.1 installation. For Debian package, wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.0g-2ubuntu4_amd64.deb
For Redhat package, https://linuxscriptshub.com/update-openssl-1-1-0-centos-6-9-7-0

Ensure that openssl is upgraded to version 1.1.If rpm -ivh neuron-1.3.0-linux-amd64.rpm prompts a missing dependency, run rpm -ivh neuron-1.3.0-linux-amd64.rpm —nodeps —force

New Installation

New Neuron software can be installed in a home directory of any user account. In case a user account is needed, we recommand "neuron" for installation.

  1. Extracting the software package to any directory, (i.e. /home/neuron ):

    1. ~$ tar -zxvf neuron-x.y.z-linux-x86_64.tar.gz
  2. Run Neuron for the first time to buildup Neuron data directories dat:

    1. ~$ {PATH}/neuron start
    2. Directory {PATH}/dat created
    3. Directory {PATH}/dat/0 created
    4. Directory {PATH}/dat/0/adm created
    5. Directory {PATH}/dat/0/adm/usr created
    6. Directory {PATH}/dat/0/alm created
    7. Directory {PATH}/dat/0/cfg created
    8. Directory {PATH}/dat/0/log created
    9. Directory {PATH}/dat/0/scp created
    10. Directory {PATH}/dat/0/scp/subr created
    11. Directory {PATH}/dat/0/obj created
    12. Directory {PATH}/dat/0/trd created
    13. Neuron instance 0 is now running with PID:6312 Port:7000

Starting the Neuron System

To start Neuron system by the command:

  1. ~$ {PATH}/neuron start
  2. Neuron instance 0 is now running with PID:6037 Port:7000

Stopping the Neuron System

To stop the running of Neuron System by the command:

  1. ~$ {PATH}/neuron stop
  2. Neuron instance 0 is stopping ...
  3. Stopped !

Starting the specific Neuron System

To start specific Neuron instance by the command:

  1. ~$ {PATH}/neuron start -i7
  2. Neuron instance 7 is now running with PID:8097 Port:7007

Stopping the specific Neuron System

To stop the running of specific Neuron by the command:

  1. ~$ {PATH}/neuron stop -i7
  2. Neuron instance 7 is stopping ...
  3. Stopped !

Starting multiple Neuron Systems

To start multiple Neuron system instances by the command

  1. ~$ {PATH}/neuron start -a5
  2. Neuron instance 0 is now running with PID:6066 Port:7000
  3. Neuron instance 1 is now running with PID:6069 Port:7001
  4. Neuron instance 2 is now running with PID:6076 Port:7002
  5. Neuron instance 3 is now running with PID:6087 Port:7003
  6. Neuron instance 4 is now running with PID:6090 Port:7004

Stopping multiple Neuron Systems

To stop the running of multiple Neuron systems by the command:

  1. ~$ {PATH}/neuron stop -a5
  2. Neuron instance 0 is stopping ...
  3. Stopped !
  4. Neuron instance 1 is stopping ...
  5. Stopped !
  6. Neuron instance 2 is stopping ...
  7. Stopped !
  8. Neuron instance 3 is stopping ...
  9. Stopped !
  10. Neuron instance 4 is stopping ...
  11. Stopped !

Checking the Neuron System

To checkup the status of Neuron systems:

  1. ~$ {PATH}/neuron status
  2. Neuron instance 0 is running with PID:6118 Port:7000
  3. Neuron instance 1 is running with PID:6121 Port:7001
  4. Neuron instance 2 is running with PID:6132 Port:7002
  5. Neuron instance 3 is running with PID:6139 Port:7003
  6. Neuron instance 4 is running with PID:6144 Port:7004

Optional Switches

Some more useful switches for "neuron" is available.

Usage: neuron [start|stop|status] [options]

options: description:
-a or —allinstance <number> no. of instances <2-10>
-i or —instance <instanceno> instance no <0-9>
-u or —uuid <uuid> universal unique id <max 36 chars>

where [-a|-i] are exclusive options.

Running in Docker

To get the docker image from https://hub.docker.com

  1. ~$ docker pull emqx/neuron:1.0.0

To start docker container

  1. ~$ docker run -d --name neuron -p 7000:7000 emqx/neuron:1.0.0