IoTGateway/AWS/Greengrass

From ESS-WIKI
Revision as of 11:14, 5 September 2017 by Daniel.hung (talk | contribs)
Jump to: navigation, search

This article is written based on AWS (Amazon Web Services) Greengrass 1.0.0, and the target device is Advantech RSB-4760 (Qualcomm APQ8016 platform).

Set Up Environment

This section is referred to the AWS Greengrass document and AWS CLI document.

Debian 9 (Stretch)

1. Add ggc_user and ggc_group using the following commands:

sudo useradd ggc_user
sudo groupadd ggc_group

2. Install missing dependencies using the following commands:

sudo apt-get update
sudo apt-get install sqlite3

3. Set up cgroups

wget https://raw.githubusercontent.com/tianon/cgroupfs-mount/master/cgroupfs-mount
chmod 777 cgroupfs-mount
sudo bash ./cgroupfs-mount

4. Install Pip

curl -O https://bootstrap.pypa.io/get-pip.py
python get-pip.py --user  

# Add an export command to your profile script, e.g. ~/.profile
export PATH=~/.local/bin:$PATH

# Load the profile into your current session
source ~/.profile

# Verify that pip is installed correctly
pip --version

5. Installing the AWS CLI with Pip

pip install awscli --upgrade --user

# Verify that the AWS CLI installed correctly
aws --version

Set Up AWS Greengrass

Download the AWS Greengrass Core Software

Sign in to the AWS Management Console and navigate to the AWS IoT console. Then, download the AWS Greengrass Core Software from Software page.

Use the following command to extract the tar file:

sudo tar -zxvf greengrass-platform-version.tar.gz -C /
Where platform is either:
  • linux-armv7l
  • linux-x86-64
  • linux-aarch64

Create an AWS Greengrass Group

Create an AWS Greengrass Core Device in the Cloud

Provisioning an AWS Greengrass Core

Get Connected to AWS