self-hosted
self-hosted copied to clipboard
Sentry does not accept any issues from application
Self-Hosted Version
24.2.0
CPU Architecture
x86_64
Docker Version
Docker version 24.0.7, build afdd53
Docker Compose Version
Docker Compose version v2.21.0
Steps to Reproduce
Sentry is installed using install.sh (no any arguments passed during setup)
After installation I have found that I have to change port 9000 to 9100, since 9000 is already takes buy other application
I've tried to replace all 9000 occurrences in settings to 9100. Sentry has started, I have set up node.js project (we use Strapi CMS) but no any events come to Sentry
If we change DSN entry for sentry.io all events go fine there. But if I change it to self-hosted - no any events, though I can see the same output in browser console either I sent errors to cloud or self-hosted
The only thing I see in composer logs is
entry-self-hosted-relay-1 | 2024-02-22T14:56:24.841620Z ERROR relay_server::services::upstream: authentication encountered error error=upstream request returned error 502 Bad Gateway error.sources=[no error details]
I suspect that there is something wrong in configuration but can't find what exactly. I even tried to stop other app (with 9000 port) and start Sentry with 9000 port but I got the same situation
If I create issues in Sentry (not send from application) it's shown correctly
So my questions
- what do I need to check and fix to remove the error above?
- Where (except docker instances) Sentry stores it's configuration? Even after I delete all containers, images and volumes and restart install.sh it does not ask me for Admin creation. After docker compose up I can enter username that I have created on the first install. Can I reinstall it from scratch (setting up an initial admin user)
Expected Result
Sentry should accept all issues/errors from application
Actual Result
No any results in Sentry from the application
Event ID
No response
I'm suggesting you to reinstall Sentry from scratch. But I'd advise to install it on a dedicated VM (or machine, server, whatever). If port 9000 is used by other application, you should modify two things:
- Change this one to anything other than 9000: https://github.com/getsentry/self-hosted/blob/8d2da229a2264e31790f736f31d2f6c3a31d0c50/.env#L5
- Uncomment this, and change it to your
hostname:port
combination. If your IP is192.168.1.2
and your port is9100
, then it'd behttp://192.168.1.2:9100
. https://github.com/getsentry/self-hosted/blob/8d2da229a2264e31790f736f31d2f6c3a31d0c50/sentry/config.example.yml#L82
If there are any other configuration that defines the port 9000
, don't change it.
I'm suggesting you to reinstall Sentry from scratch. But I'd advise to install it on a dedicated VM (or machine, server, whatever). If port 9000 is used by other application, you should modify two things:
- Change this one to anything other than 9000: https://github.com/getsentry/self-hosted/blob/8d2da229a2264e31790f736f31d2f6c3a31d0c50/.env#L5
- Uncomment this, and change it to your
hostname:port
combination. If your IP is192.168.1.2
and your port is9100
, then it'd behttp://192.168.1.2:9100
. https://github.com/getsentry/self-hosted/blob/8d2da229a2264e31790f736f31d2f6c3a31d0c50/sentry/config.example.yml#L82If there are any other configuration that defines the port
9000
, don't change it.
Ok, I've tried it. No luck with getting events but I was able to get rid of relay errors though At first I still had this error in the sentry-self-hosted-relay-1 container logs
2024-02-23T09:47:33.313531Z ERROR relay_server::services::upstream: authentication encountered error error=upstream request returned error 502 Bad Gateway error.sources=[no error details]
2024-02-23T09:48:33.577143Z ERROR relay_server::services::upstream: authentication encountered error error=upstream request returned error 502 Bad Gateway error.sources=[no error details]
2024-02-23T09:49:33.628837Z ERROR relay_server::services::upstream: authentication encountered error error=upstream request returned error 502 Bad Gateway error.sources=[no error details]
2024-02-23T09:50:33.694816Z ERROR relay_server::services::upstream: authentication encountered error error=upstream request returned error 502 Bad Gateway error.sources=[no error details]
What I did
- Performed a clean install with setting up new admin account
- Updated following settings with 9100 port https://github.com/getsentry/self-hosted/blob/8d2da229a2264e31790f736f31d2f6c3a31d0c50/.env#L5 https://github.com/getsentry/self-hosted/blob/8d2da229a2264e31790f736f31d2f6c3a31d0c50/sentry/config.example.yml#L82 and also I had to uncomment and update this line https://github.com/getsentry/self-hosted/blob/8d2da229a2264e31790f736f31d2f6c3a31d0c50/sentry/sentry.conf.example.py#L343 otherwise I received CSRF Verification Failed after entering id and password at login page
But after googling I've found this solution and it helped remove relay errors. But no luck with getting errors into Sentry
I sent this to Sentry
[2024-02-23 11:11:25.685] error: Some error
Error: Some error
at /opt/app/src/api/faq-category/middlewares/middleware.js:31:21
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async policiesMiddleware (/opt/node_modules/@strapi/strapi/dist/services/server/policy.js:15:5)
at async /opt/node_modules/@strapi/strapi/dist/services/server/compose-endpoint.js:27:12
at async serve (/opt/node_modules/koa-static/index.js:59:5)
at async returnBodyMiddleware (/opt/node_modules/@strapi/strapi/dist/services/server/compose-endpoint.js:42:18)
at async policiesMiddleware (/opt/node_modules/@strapi/strapi/dist/services/server/policy.js:15:5)
at async /opt/node_modules/@strapi/strapi/dist/services/server/compose-endpoint.js:27:12
at async /opt/node_modules/@strapi/plugin-sentry/dist/server/index.js:31:7
at async /opt/node_modules/@strapi/strapi/dist/middlewares/body.js:45:9
Are there any logs in your nginx container indicating that the envelope containing the error has been received? What about logs in your web container?
This issue has gone three weeks without activity. In another week, I will close it.
But! If you comment or otherwise update it, I will reset the clock, and if you remove the label Waiting for: Community
, I will leave it alone ... forever!
"A weed is but an unloved flower." ― Ella Wheeler Wilcox 🥀