Can't bring Geocoding to work

I’m testing a new LibreNMS installation since a couple of days which works pretty well.
But one point really drives me a bit crazy - I can not bring the Geocoding to work.
I tried different Mapping Engines and Location Strings - no success.
But i stumbled over a Error Massage in the Discovery Debug output:


Bing geocode engine

Error discovering os module for 192.168.0.2. Argument 2 passed to App\ApiClients\BingApi::checkResponse() must be of the type array, null given, called in /opt/librenms/app/ApiClients/GeocodingHelper.php on line 57


Somebody maybe has an idea where my mistake is or what possible is wrong here?

Also having trouble with this. Even using a Google API that has geocoding enabled. Next thing i am going to try is changing the server to install ssl. I suspect these requests might be blocked because its coming from an unsecure source.

Could you solve this?
I checked the communication between my LibreNMS Server and Bing / Openstreetmaps …
These communication took place but, in both cases without an LAT/Lon Result…

Will try Google Maps next .

Our server isn’t publicly accessible and ran into some errors while trying to assigned a self signed cert. Have not had time to continue with it yet but will give it a shot this afternoon (next 5 hours) or tomorrow.

I have been failing miserably in my endeavors. I think during the install process I may have removed all the repo lists or possibly it was a step in libreNMS setup. I have tried methods of restoring them to be able to install a ssl but every time i break the server and have to roll back. So at this time i have had zero luck on getting the geocoding to work.

Mine has seemed to stop geocoding, which is strange. I’m getting the error of

{"response":{"error_message":"Invalid request. Missing the 'address', 'components', 'latlng' or 'place_id' parameter.","results":[],"status":"INVALID_REQUEST"}}

I’m trying to see where the error points to as I use the standard address formatting of 1000 Parkway Dr, Santa Clara, CA 95050. I’ll post back if I get anywhere.

1 Like

same here

Load disco module os

Geocoding failed. {“response”:{“error_message”:“Invalid request. Missing the ‘address’, ‘components’, ‘latlng’ or ‘place_id’ parameter.”,“results”:,“status”:“INVALID_REQUEST”}}
Location: 1000 Parkway Dr, Santa Clara, CA 95050
Hardware: C1121-8PLTEP

by command line it looks ok

curl “https://maps.googleapis.com/maps/api/geocode/json?address=1000+Parkway+Dr,+Santa+Clara,+CA+95050&key=********************”

{
“results” : [
{
“address_components” : [
{
“long_name” : “95050”,
“short_name” : “95050”,
“types” : [ “postal_code” ]
},
{
“long_name” : “Santa Clara”,
“short_name” : “Santa Clara”,
“types” : [ “locality”, “political” ]
},
{
“long_name” : “Santa Clara County”,
“short_name” : “Santa Clara County”,
“types” : [ “administrative_area_level_2”, “political” ]
},
{
“long_name” : “California”,
“short_name” : “CA”,
“types” : [ “administrative_area_level_1”, “political” ]
},
{
“long_name” : “United States”,
“short_name” : “US”,
“types” : [ “country”, “political” ]
}
],
“formatted_address” : “Santa Clara, CA 95050, USA”,
“geometry” : {
“bounds” : {
“northeast” : {
“lat” : 37.37448000000001,
“lng” : -121.9308761
},
“southwest” : {
“lat” : 37.32314,
“lng” : -121.9702899
}
},
“location” : {
“lat” : 37.3539663,
“lng” : -121.9529992
},
“location_type” : “APPROXIMATE”,
“viewport” : {
“northeast” : {
“lat” : 37.37448000000001,
“lng” : -121.9308761
},
“southwest” : {
“lat” : 37.32314,
“lng” : -121.9702899
}
}
},
“partial_match” : true,
“place_id” : “ChIJkyN3003Kj4ARP-4TcpEoJuA”,
“postcode_localities” : [ “Central San Jose”, “North San Jose”, “San Jose”, “Santa Clara” ],
“types” : [ “postal_code” ]
}
],
“status” : “OK”
}

I’m not sure if it stopped working after the last Librenms update

$ ./validate.php

Component Version
LibreNMS 22.2.0-1-gd8f96a46b
DB Schema 2021_12_02_113537_ports_stp_designated_cost_change_to_int (234)
PHP 7.4.27
Python 3.8.12
MySQL 5.7.33
RRDTool 1.7.2
SNMP 5.9
====================================

[OK] Composer Version: 2.2.6
[OK] Dependencies up-to-date.
[OK] Database connection successful
[OK] Database schema correct
[INFO] Detected Python Wrapper
[OK] Connection to memcached is ok

I reported the issue on Github #13814, lets see what happens.

$ ./validate.php
====================================
Component | Version
--------- | -------
LibreNMS  | 22.2.1-6-g703745d0e
DB Schema | 2022_02_03_164059_increase_auth_id_length (235)
PHP       | 8.0.15
Python    | 3.6.8
MySQL     | 10.3.28-MariaDB
RRDTool   | 1.7.0
SNMP      | 5.8
====================================

[OK]    Composer Version: 2.2.6
[OK]    Dependencies up-to-date.
[OK]    Database connection successful
[OK]    Database schema correct

1 Like

Logging onto our LibreNMS this morning, i see theres suddenly devices on the map :smiley:
I not sure if there was a patch during the evening but its working

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.