Link Search Menu Expand Document

Troubleshooting

Errors occur for many reasons. From environmental differences, to permissions, to differences in software versions and more. Here you will find some resources that could help you troubleshoot problems with Reconmap. If these notes still leave you facing a problem, reach out to us on Gitter where we will happily assist you.

Server logs

Server logs show all sort of warnings and errors and should be your first stop while troubleshooting problems with Reconmap. Its location is /var/log/nginx/error.log inside the backend API Docker container.

If you want to see the last lines of this file run the following Docker command:

$ docker exec reconmap-backend-api tail /var/log/nginx/error.log

Example output:

#0 /var/www/webapp/src/Services/ConfigLoader.php(12): json_decode()
#1 /var/www/webapp/public/index.php(26): Reconmap\Services\ConfigLoader->loadFromFile()
#2 {main}
  thrown in /var/www/webapp/src/Services/ConfigLoader.php on line 12" while reading response header from upstream, client: 172.19.0.1, server: localhost, request: "OPTIONS /users/login HTTP/1.1", upstream: "fastcgi://unix:/var/run/php/php7.4-fpm.sock:", host: "localhost:8080", referrer: "http://localhost:3001/login"
2020/10/29 19:40:11 [error] 25#25: *54 FastCGI sent in stderr: "PHP message: PHP Warning:  file_get_contents(/var/www/webapp/config.json): failed to open stream: No such file or directory in /var/www/webapp/src/Services/ConfigLoader.php on line 12PHP message: PHP Stack trace:PHP message: PHP   1. {main}() /var/www/webapp/public/index.php:0PHP message: PHP   2. Reconmap\Services\ConfigLoader->loadFromFile() /var/www/webapp/public/index.php:26PHP message: PHP   3. file_get_contents() /var/www/webapp/src/Services/ConfigLoader.php:12PHP message: PHP Fatal error:  Uncaught TypeError: json_decode() expects parameter 1 to be string, bool given in /var/www/webapp/src/Services/ConfigLoader.php:12
Stack trace:
#0 /var/www/webapp/src/Services/ConfigLoader.php(12): json_decode()
#1 /var/www/webapp/public/index.php(26): Reconmap\Services\ConfigLoader->loadFromFile()
#2 {main}
  thrown in /var/www/webapp/src/Services/ConfigLoader.php on line 12" while reading response header from upstream, client: 172.19.0.1, server: localhost, request: "OPTIONS /users/login HTTP/1.1", upstream: "fastcgi://unix:/var/run/php/php7.4-fpm.sock:", host: "localhost:8080", referrer: "http://localhost:3001/login"

Application logs

After the sever logs come the application logs. Its location is API_FOLDER/logs/application.log and similarly to the server logs, here you can see warnings and errors generated by the API or the backend jobs.

Example output:

[2020-10-29 12:26:01] cron.DEBUG: Running queue processor {"class":"Reconmap\\Tasks\\EmailTaskProcessor"} []
[2020-10-29 12:26:01] cron.DEBUG: Running queue processor {"class":"Reconmap\\Tasks\\TaskResultProcessor"} []
[2020-10-29 12:26:21] http.WARNING: Expired token [] []
[2020-10-29 12:26:21] http.WARNING: Expired token [] []
[2020-10-29 12:26:21] http.WARNING: Expired token [] []