Comments (5)
The first log message:
"APM Server transport error: error fetching APM Server version: timeout (30000ms) fetching APM Server version"
is saying that the APM agent running in your app got a timeout talking to your configured APM Server URL.
The very first log message from the APM agent will include a dump of its configuration -- which will show what it things its serverUrl
value is.
For some reason, that serverUrl
is not responding to requests. It looks like it is connecting to that URL, otherwise the error would be ECONNREFUSED
.
Are you able to manually run a command from the same machine/VM/container where the APM agent is running? If so, this should be the equivalent of the first request the APM agent is attempting:
curl -v $serverUrl/
A possibility could be that your APM server is down, but I'm not positive. Are you able to look at your APM server logs?
from apm-agent-nodejs.
hi
If you run the curl command in docker by specifying the IP and port of the APM server, you can see the response.
However, I cannot retrieve server information using the command you sent.
Do I need to specify a serverUrl value?
thank you
from apm-agent-nodejs.
Do I need to specify a serverUrl value?
Yes, you need to fill that in with the URL for your APM server. For example, the APM server URL for a deployment of mine on cloud.elastic.co is https://trentm-deployment17.apm.us-west1.gcp.cloud.es.io
. For me, running that command gives a response like this:
% curl -i https://trentm-deployment17.apm.us-west1.gcp.cloud.es.io/
HTTP/2 200
date: Tue, 21 May 2024 21:28:53 GMT
x-cloud-request-id: TqX8ENw4QQeycOWecjqMwg
x-content-type-options: nosniff
x-found-handling-cluster: e1271517748b49929a101be02c2966c3
x-found-handling-instance: instance-0000000000
content-length: 0
from apm-agent-nodejs.
My apm server doesn't have a specific url.
I am also making requests via IP from apm/client in a different environment.
However, other environments are normal.
# curl -i http://10.10x.x0.x35:8200
HTTP/1.1 200 OK
Content-Type: application/json
X-Content-Type-Options: nosniff
Date: Wed, 22 May 2024 01:59:49 GMT
Content-Length: 150
{
"build_date": "2023-01-31T04:33:06Z",
"build_sha": "71a8b4c241eb5b4609862c8354d2aa2270f6c568",
"publish_ready": true,
"version": "7.17.9"
}
from apm-agent-nodejs.
If you run the curl command in docker by specifying the IP and port of the APM server, you can see the response.
Can you confirm that the IP and port that works for you is the same as the serverUrl
you are using for the Node.js APM agent config in that Docker container?
I'm not sure what else to say. The APM agent is configured with a URL to talk to the APM server (https://www.elastic.co/guide/en/apm/agent/nodejs/current/configuration.html#server-url). From within that container that is running your app, a simple HTTP GET request to that URL fails.
from apm-agent-nodejs.
Related Issues (20)
- Agent doesn't capture uncaught exceptions or unhandled rejections HOT 11
- Request body is logged even with `captureBody: off` HOT 17
- undici instrumentation can add duplicate trace-context headers, which can break Elasticsearch HOT 2
- release fails in make-distribution.sh step
- KafkaJS instrumentation throw exception on "tombstone message" HOT 2
- Agent not working with Yarn Pnp + NextJS HOT 5
- including parsed "cookie" HTTP request header in ingest can lead to mapping conflicts HOT 2
- Elastic APM Agent Node arbitrary code Injection due to improper sanitization of the timezone parameter HOT 2
- Lambda "nodejs20.x" is out, our published Lambda layers should say they support it HOT 2
- bitrot updates HOT 1
- [Question] Support bullmq HOT 7
- make docker image(s) multi-platform and include linux/arm64 HOT 4
- opentelemetry-bridge should use the ELASTIC_APM_API_KEY HOT 1
- Any plans to support hyper-express please? HOT 4
- Support for Azure OpenAI
- nightly test with Node.js v23 failing in `elasticsearch` module
- add support for synchronous gauge to OTel Bridge metrics support
- Is there any plan to add a way to customize trace.id ? HOT 2
- Nested labels are indexed as `[object Object]` HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from apm-agent-nodejs.