Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OTLP HTTP/1.0 receiver not found in otel collector service #833

Closed
rinshadka opened this issue Mar 8, 2022 · 17 comments
Closed

OTLP HTTP/1.0 receiver not found in otel collector service #833

rinshadka opened this issue Mar 8, 2022 · 17 comments
Assignees

Comments

@rinshadka
Copy link

Hi, I lost the OTLP HTTP/1.0 receiver, after upgrading otel collector service to latest signoz/otelcontribcol:0.43.0 version.

Now I could only use OTLP GRPC receiver port at 4317.

Earlier I was using OTLP HTTP/1.0 receiver at 55681.

Found different in the docker-compose port expose for otel-collector service:

Earlier:-

    ports:
      - "1777:1777"   # pprof extension
      - "8887:8888"   # Prometheus metrics exposed by the agent
      - "14268:14268"       # Jaeger receiver
      - "55678"       # OpenCensus receiver
      - "55680:55680"       # OTLP HTTP/2.0 legacy port
      - "55681:55681"       # OTLP HTTP/1.0 receiver
      - "4317:4317"       # OTLP GRPC receiver
      - "55679:55679" # zpages extension
      - "13133"       # health_check
      - "8889:8889"   # prometheus exporter

Now:-

    ports:
      - "4317:4317"       # OTLP GRPC receiver

Please help,
Thanks.

@pranay01
Copy link
Collaborator

pranay01 commented Mar 8, 2022

yeah @rinshadka We have deprecated OTLP HTTP/1.0 receiver at 55681

Are you not able to use port 4317 for sending your application data to SigNoz?

@ankitnayan
Copy link
Collaborator

@rinshadka were you instrumenting nodeJs application? OpenTelemetry has deprecated the use of port 55681 and we have upgrade otel-collector to latest versions. We recommend you to upgrade to the latest version of SigNoz v0.7.1 and make minor changes to your nodeJs apps.

@pranay01 would be great to refer some nodeJs docs and examples that use 4317 for communication

@ankitnayan ankitnayan self-assigned this Mar 8, 2022
@pranay01
Copy link
Collaborator

pranay01 commented Mar 8, 2022

@rinshadka Here's the updated docs for instrumenting you Nodejs app - https://signoz.io/docs/instrumentation/nodejs/

@rinshadka
Copy link
Author

Thanks for the support @pranay01 @ankitnayan. I am running the latest SigNoz v0.7.1 now and 4317 is working fine from a python application. I will share these information with our developer.

@pranay01
Copy link
Collaborator

pranay01 commented Mar 8, 2022

cool @rinshadka 🎉 Closing the issue, feel free to reopen if needed

@pranay01 pranay01 closed this as completed Mar 8, 2022
@dittybijil
Copy link

@ankitnayan @pranay01 as @rinshadka mentioned its working fine with python and node application. But we are facing issue when we use it for web. As per tickets 2825 and 2806 they are not providing support for this feature now. Can you support us for solving this issue.

Thanks for your support

@ankitnayan
Copy link
Collaborator

ankitnayan commented Mar 10, 2022

@dittybijil for web you can continue sending data to via http at 4318 port. Opentelemetry collector already listens at http and just additional port 4318 needs to be exposed at https://github.com/SigNoz/signoz/blob/develop/deploy/docker/clickhouse-setup/docker-compose.yaml#L61. The default http port has changed from 55681 to 4318.

@rinshadka
Copy link
Author

@ankitnayan we are using signoz/otelcontribcol:0.43.0 as collector service and from the logs I can see that ports 4317, 55681 and 4318 are all starting from the log below:-

otlpreceiver/otlp.go:69 Starting GRPC server on endpoint 0.0.0.0:4317   {"kind": "receiver", "name": "otlp"}
otlpreceiver/otlp.go:87 Starting HTTP server on endpoint 0.0.0.0:4318   {"kind": "receiver", "name": "otlp"}
otlpreceiver/otlp.go:147        Setting up a second HTTP listener on legacy endpoint 0.0.0.0:55681      {"kind": "receiver", "name": "otlp"}
otlpreceiver/otlp.go:87 Starting HTTP server on endpoint 0.0.0.0:55681  {"kind": "receiver", "name": "otlp"}

Then I have added 55681 and 4318 ports along with 4317 for exposing in docker-compose as below:-

      - "4317:4317"       # OTLP GRPC receiver
      - "55681:55681"      # OTLP HTTP/1.0 receiver
      - "4318:4318"       # OTLP HTTP/1.0 receiver

But both the HTTP ports are not working as expected. In earlier version of otel-collector, we were getting a response like below when we just access the port - 55681 in browser,

{
  "code": 12,
  "message": "Not Implemented",
  "details": [
  ]
} 

But in the new version no responses coming on bot HTTP ports, Please support.

Thanks.

@ankitnayan
Copy link
Collaborator

@rinshadka Is this solved now? I would suggest trying out some examples from opentelemetry on configuring and sending data to otel-collector. You might have to add cors at otel-collector config apart from exposing ports at docker-compose.yaml.
Like this https://github.com/open-telemetry/opentelemetry-js-contrib/blob/main/examples/connect/docker/collector-config.yaml#L6-L8
SigNoz's otel-collector config is at https://github.com/SigNoz/signoz/blob/develop/deploy/docker/clickhouse-setup/otel-collector-config.yaml#L9

@rinshadka
Copy link
Author

@ankitnayan I was not able to expose the port 4318 to host machine with the latest - otelcontribcol:0.43.0 version.
So I am using otelcontribcol:0.6.0 version now with exposed 55681 port. For CORs headers I am using Traefik reverse-proxy.

@ankitnayan
Copy link
Collaborator

got it

@rinshadka
Copy link
Author

rinshadka commented Mar 23, 2022

@ankitnayan , I have tried the latest Signoz v0.7.2 implementation using this docker-compose file. But port 4318 is not accessible. I have also enabled port - 55681, But this port also is not working.

So, I am still stuck with the otelcontribcol:0.6.0 version with exposed OTLP HTTP port - 55681 in production environment.

Also can I use latest - signoz/frontend:0.7.2 and signoz/query-service:0.7.2 along with older signoz/otelcontribcol:0.6.0 in production environment once this issue is sorted out.

Thanks.

@ankitnayan
Copy link
Collaborator

@rinshadka A good concrete way of solving this would be to help us with a sample Github repo that does not work and our team will try to make it work.

@rinshadka
Copy link
Author

@ankitnayan , Today I have worked on a fresh installation one of the test servers.

Fetch the repository:-
git clone -b main https://github.com/SigNoz/signoz.git && cd signoz/deploy/

Deployment:-
docker-compose -f docker/clickhouse-setup/docker-compose.yaml up -d

Accessed OTLP HTTP port in browser:-
http://local-ip:4318/ -> responds with a 404 page not found

Then enabled OTLP HTTP legacy receiver like below and re-deployed:-

otel-collector:
   image: signoz/otelcontribcol:0.43.0
   command: ["--config=/etc/otel-collector-config.yaml"]
   volumes:
     - ./otel-collector-config.yaml:/etc/otel-collector-config.yaml
   ports:
     - "4317:4317"     # OTLP gRPC receiver
     - "4318:4318"     # OTLP HTTP receiver
     # - "8889:8889"     # Prometheus metrics exposed by the agent
     # - "13133"         # health_check
     # - "14268:14268"   # Jaeger receiver
     # - "55678:55678"   # OpenCensus receiver
     # - "55679:55679"   # zpages extension
     # - "55680:55680"   # OTLP gRPC legacy port
     - "55681:55681"   # OTLP HTTP legacy receiver

Accessed that port in browser:-
http://10.10.10.171:55681 -> responds with a 404 page not found

In earlier version of otel-collector (otelcontribcol:0.6.0), we were getting a response like below when we just access the port - 55681 in browser,

{
  "code": 12,
  "message": "Not Implemented",
  "details": [
  ]
} 

But in the new version no responses coming on both HTTP ports.

Thanks.

@ankitnayan
Copy link
Collaborator

@rinshadka I need a frontend repo with configurations used to replicate and then investigate. This must have little to do with SigNoz but with how instrumentation is done on frontend.

The signoz's otel-collector has been upgraded from otel's v0.26.0 to v0.43.0, so there is something the instrumentation config is using which changed in receivers in v0.43.0 and hence would need a frontend repo with config to replicate this issue.

@ankitnayan
Copy link
Collaborator

Hey @rinshadka, I tested it out with an angular app. The config to define cors has changed from

        cors_allowed_origins:
        - http://*
        - https://*

to below in otel-collector version v0.43.0

        cors:
          allowed_origins:
          - http://*
          - https://*

After this, you need to restart otel-collector to apply the new config.

And, you need to use endpoint http://<IP of machine hosting signoz>:4318/v1/traces from your frontend app. Assuming you have already exposed port 4318 at signoz's machine. If not, signoz exposes port 4318 by default from v0.7.2

@ankitnayan
Copy link
Collaborator

Though I could not see the frontend app on application list page but was able to see the traces in traces page

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants