Influxdb - connection refused


#1

I can’t connect my App Server to Influxdb. I received the following message back:

appserver_1 | time=“2018-08-23T17:37:34Z” level=error msg=“handler *influxdbhandler.Handler error: sending measurements error: http request error: Post http://localhost:8086/write?db=LoraAppGPS&precision=ms&rp=un_an: dial tcp 127.0.0.1:8086: connect: connection refused”

Also, the port 8086 is open (I can connect using telnet). Could anyone help me with this ? Thanks.


#2

Hi Charles!
Did you solve it?

I’m facing this problem:

Dec 18 09:01:57 ip-172-31-24-224 lora-app-server[739]: time=“2018-12-18T09:01:57Z” level=error msg=“handler *influxdbhandler.Handler error: sending measurements error: expected 2xx response, got: 404 (404 page not found\n)”

I have installed the influxdb in other instance. I created a database called “test” and this is how I do the integration:


Furthermore, I can curl from the same instance where I have the lora-server-app:

curl -i “http://xxx:8086/query?db=test&pretty=true” --data-urlencode “q=SHOW
SERIES” HTTP/1.1 200 OK
Content-Type: application/json
Request-Id: 51f1cd2f-02a4-11e9-8024-06cfe2463d24
X-Influxdb-Build: OSS
X-Influxdb-Version: 1.7.2
X-Request-Id: 51f1cd2f-02a4-11e9-8024-06cfe2463d24
Date: Tue, 18 Dec 2018 09:07:18 GMT
Transfer-Encoding: chunked

{
“results”: [
{
“statement_id”: 0,
“series”: [
{
“columns”: [
“key”
],
“values”: [
[
“test_pablo,host=server01,region=us-west”
]
]
}
]
}
]
}

Any help? @brocaar
Thanks!


#3

Solved! I just didn’t put WRITE in the end point after the port… Sorry!