[Deprecated] LIPI for DNA Spaces Installation Guide
Please see https://mazemap.atlassian.net/wiki/spaces/MCSH/pages/2388721665. This guide you are currently looking at should not be used for new installations, unless it is to refer to some detailed information that may still be lacking in the newer documentation for the Proxy-LIPI. Proxy-LIPI should always be used for a Spaces installation.
We now have a simplified way of installing the LIPI indoor positioning software using our new CLI Tool. This is a comprehensive document and is divided into 4 parts as shown below.
Please note that you will still need to involve someone who has access to the LIPI server, has experience with SSH and Linux, and has access to DNA Spaces. Let us make sure that our system is ready for our positioning system by checking these prerequisites beforehand and complying with them.
Note: If you are planning to install a LIPI that does not have internet connection, please refer to https://mazemap.atlassian.net/l/c/1eY8xdGE
Note: To install LIPI for CMX please refer to https://mazemap.atlassian.net/wiki/spaces/MCSH/pages/716668971
PREREQUISITES for the LIPI Installation
Requirements for the LIPI server
Can be virtual or physical, does not matter.
No OVA currently available, one of the supported OSes needs to be installed.
Supported Operating systems: Newest stable Ubuntu or Debian.
Server/Virtual Machine(VM) specs: Tested to work with single Core VM with 3.5 GB Ram and 7 GB HDD.
Before you install LIPI, you need to install Java Headless, the command is
sudo apt-get install openjdk-8-jre-headless
Requirements for the network
Open port 443 from LIPI server to DNA Spaces (https for API).
Open port 443 from all wireless clients to LIPI (https for position requests).
Open port 443 from all wireless clients to MazeMap server.
Traffic from Wireless Clients to LIPI must not pass through NAT.
Information the customer has to send to MazeMap
Private IP-address of the LIPI server (The one WiFi clients will connect to the LIPI with; in IPv4 or IPv6 formats). Used to set up DNS Record showing domain name *.mazepos.com
Public IP address/es range/s for all WIFI-clients (the NAT-devices' IP-address if in use). Used for network configuration setup
Now we are ready to Install the LIPI
I. Installing the LIPI CLI Tool
Download the CLI Tool
wget -O lipi https://storage.mazemap.com/lipi/latest/lipi
Make the file executable (root privilege required)
chmod +x lipi
Add lipi command to your path. (root privilege required)
Complete the installation (one time setup of API key and installation folder).
Note: All lipi
commands here on after should be run from the directory within which the lipi --setup
command was run. This will be the directory that contains the params.txt
file
Putting in your API key:
a. Go to Map Editor and navigate to the Indoor Positioning menu. (If this menu is not visible to you, please send a mail to support@mazemap.com and ask for access.)
b. Click the LIPI Configuration
c. Expand the LIPI configuration and click on “Generate”. You can copy this key and paste it on your SSH
When you have already pasted the API key as shown above, you will get a new question regarding the name of your new folder in the field as shown below. (E.g, “lipi-install” or any intuitive name).
Once you have successfully installed the tool we use to install and set up the LIPI correctly, you will get the following message.
II. Usage commands
Download and install latest LIPI
(requires MazeMap API key and internet access)
Note: If this is the first installation, the tool will also download the configuration
file from MazeMap.
You will get the following questions. On ready to activate input y
You should get the message:
Run status check
You should get the message:
Run status check, and report to MazeMap
(requires MazeMap API key and internet access)
List available LIPI versions
(requires MazeMap API key and internet access)
Download and install specific version of LIPI
(requires MazeMap API key and internet access)
Install from local source
Install from MazeMap, using custom configuration file
Update config of running LIPI
(requires MazeMap API key and internet access)
Update config of running LIPI, using custom configuration file
(requires mazemap API key and internet access)
List installed LIPI versions and see which one is active
Activate a previous installation
Reconfigure running LIPI
Reinitialize the current configuration with new variables.
III. What happens during install and updating?
If the MazeMap API key is set, the tool can download new versions of lipi and
the configuration file from MazeMap servers.After running initial
--setup
, the tool will install a cron task which regularly
runs the commandlipi --status report
. This will send lipi health data to MazeMap
on a regular basis so that we can provide a better level of service to you. This is
only installed if the MazeMap API Key is set during setup. If this is not installed
we can not help debugging an installation, and we will not be able to help users
if they have trouble accessing the LIPI service. See Run status check, and report to MazeMap
to see what is reported to MazeMap.When installing a new version of LIPI, the update tool will prefer to use the
configuration files of the currently running LIPI version. This can be overridden
using the--config-path
flag or by running--update-config
before running--install
.Every
--install
and--update-config
creates a new installation version. This
is done to allow switching between new and previous installations or configurations
at will. If something goes wrong, a previous version can be activated using--activate
. The installation or update process will activate the previous version
if the new version can't be started or seem unresponsive (if--status
does not
show a fully healthy installation).
Manual fixing:
--setup
stored values in a fileparams.txt
. Running--setup
again will overwrite it.A LIPI service has a
config.json
in its installation folder, which can be copied,
edited and used using--config-path
, if needed.The folders under LIPI installation path are self contained and can be deleted at will.
Just make sure to not delete the running version. Use--list
or--status
to see which
version is running.LIPI is started using systemctl. Status and control of that service is available.
systemctl [status|start|stop|restart] lipi.service
.
IV. Summary of the Common CLI Commands
This summary contains commands that are useful when setting up the LIPI server.
The config file that is used is under the /srv folder use command cd to open folder and ls to read what is in the folder.
Action | Command | Comment |
---|---|---|
Start LIPI server | sudo systemctl start lipi | |
Stop LIPI server | sudo systemctl stop lipi | |
Restart LIPI server | sudo systemctl restart lipi | |
Status of LIPI server | sudo systemctl status lipi | |
Check the lipi log | journalctl -u lipi -n 200 -f | |
Update lipi | Download the new lipi Make sure that the file is executable by typing: | |
open and update the config file | sudo nano config.json | |
view the config file | cat config.json | |
Move a file from one location to another | mv <start location> <end location> | In the example the config file is located in /home/cygate and we are moving it to /srv/. We are replacing the old file with the new file. |
LIPI + DNA Spaces Architecture