Services and logs
Access to services or logs is an advanced task that requires having root access on the gateway.
Services
Services are accessible through CLI commands:
Services on TAO Server
5 services are started on TAO server:
Role | Service |
---|---|
Base station LRR | lrr |
LoRaWAN network server | lrc |
ThingPark All-in One administration server | tao |
node-RED | node-red |
MQTT broker | mqtt |
Services on TAO remote gateway
2 services are started on TAO remote gateway:
Role | Service |
---|---|
Base station LRR | lrr |
ThingPark All-in One administration server | tao |
caution
It is not allowed to modify any configuration files located under /home/actility/usr/etc... (except for temporary tests). All these modifications will be lost after an upgrade.
Logs
All logs are stored in a tmpfs in-memory space:
Model | Log storage root path | tmpfs space |
---|---|---|
ufispace | /var/volatile/log | 100 MB |
tektelic | /var/volatile/log | 64 MB |
gemtek | /dev/shm/log | 500 MB |
kerlink | /var/run | 114 MB |
For each service, a dedicated folder is created:
Service | Path |
---|---|
LRR | <log storage root path>/_LRRLOG |
LRC | <log storage root path>/_LRCLOG |
tao | <log storage root path>/_TAOLOG |
node-red | <log storage root path>/_NODEREDLOG |
mqtt | <log storage root path>/_MQTTLOG |
This is achieved through links (Ufispace example):
am335x-evm:/# ls -l /home/actility/var/log/
lrwxrwxrwx 1 root root 25 Jan 5 11:36 lrc -> /var/volatile/log/_LRCLOG
lrwxrwxrwx 1 root root 25 Jan 5 11:36 lrr -> /var/volatile/log/_LRRLOG
lrwxrwxrwx 1 root root 29 Jan 5 11:36 node-red -> /var/volatile/log/_NODEREDLOG
lrwxrwxrwx 1 root root 25 Jan 5 11:36 tao -> /var/volatile/log/_TAOLOG
Log levels are kept very low, and not provided for MQTT:
Service | Configuration file | Configuration |
---|---|---|
LRR | $ROOTACT/usr/etc/lrr/lrr.ini | level=0, debug=0, size=10000000 (10MB) |
LRC | $ROOTACT/usr/etc/lrr/lrc.ini | level=0, debug=0, size=10000000 (10MB) |
TAO | $ROOTACT/usr/etc/tao/configs/tao_server_config.yaml | level: WARN, maxSize=10 (10 MB) |
Node-RED | $ROOTACT/usr/etc/node-red/settings.js | level : 'error', size=10000000 (10 MB) |
MQTT | $ROOTACT/usr/etc/mqtt/mosquitto.conf | log_dest none, must change it to log_dest file /var/log/mosquitto.log for log activation |
Log level modification
- For LRR, TAO, Node-RED and MQTT, you must connect on the base station, and modify the configuration files and then, restart the corresponding service.
- For LRC, you can do the same or dynamically through a telnet admin session (telnet 0 2009).
- For Node-RED:
- level: "trace" (in 2 places)
- Add section:
uplinkDownlink: { log: (s)=>{(module.exports.logging.customLogger.handler())({timestamp: s.slice(0,s.indexOf(" ")), msg:s.slice(s.indexOf(" ")+1)}) } },
- For MQTT, configure log_dest to log_dest file /var/log/mosquitto.log, and set log_type.
note
All logs (not for the MQTT broker) are stored in memory, they are copied on disk every day in $ROOTACT/traces.