getsentry / self-hosted

Sentry, feature-complete and packaged up for low-volume deployments and proofs-of-concept
https://develop.sentry.dev/self-hosted/
Other
7.85k stars 1.77k forks source link

error in loading data #2989

Closed Harsh-Kesharwani closed 2 weeks ago

Harsh-Kesharwani commented 6 months ago

Self-Hosted Version

24.4.0

CPU Architecture

x86_64

Docker Version

24.0.5

Docker Compose Version

2.26.0

Steps to Reproduce

There was an error loading data. I am this error after login on path /organizations/sentry/issues/

Expected Result

Unable

Actual Result

Event ID

No response

aldy505 commented 6 months ago

Can we have more detailed information regarding your setup? Or something that you did previously to the self-hosted configuration before this happened? Or even better your web container logs (sudo docker compose logs --since 1h web)?

Harsh-Kesharwani commented 6 months ago

Can we have more detailed information regarding your setup? Or something that you did previously to the self-hosted configuration before this happened? Or even better your web container logs (sudo docker compose logs --since 1h web)?

my clickhouse service is down.

Screenshot 2024-04-23 at 1 29 48 PM
aldy505 commented 6 months ago

Have you tried running sudo docker compose down and then sudo ./install.sh again? If you have, you might want to try sudo docker compose down and sudo docker compose up -d --wait clickhouse just to make sure your ClickHouse should be alive and healthy. Then you can start the rest of the containers.

Harsh-Kesharwani commented 6 months ago

Thanks @aldy505 I have fixed that issue, but i am unable to access sentry self hosted from domain name can you help me . below is my apache2 config file.

I have update system.url-prefix: https://sentry.xyz.in and also update sentry.conf.py file and restarted docker-compose.

<VirtualHost *:80>
    ServerName sentry.xyz.in

    # Redirect HTTP to HTTPS
    RewriteEngine on
    RewriteCond %{HTTPS} off
    RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [L,R=301]

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>

<VirtualHost *:443>
    ServerName sentry.xyz.in

    # SSL configuration
    SSLEngine on
    SSLCertificateFile /etc/letsencrypt/live/sentry.xyz.in/cert.pem
    SSLCertificateKeyFile /etc/letsencrypt/live/sentry.xyz.in/privkey.pem
    SSLCertificateChainFile /etc/letsencrypt/live/sentry.xyz.in/fullchain.pem

    # Regular HTTPS traffic
    ProxyPass / http://localhost:9000
    ProxyPassReverse / http://localhost:9000

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
aldy505 commented 6 months ago

By "unable to access sentry self hosted from domain name ", what kind of error are you experiencing? It's just a blank screen or something?

Harsh-Kesharwani commented 6 months ago

@aldy505 I am getting connection timeout.

aldy505 commented 6 months ago

Connection timeout errors usually caused by either you have poor connection from your device to the Apache2 server, or.. Apache2 server can't reach the localhost:9000. You should check both cases.

Harsh-Kesharwani commented 5 months ago

@aldy505 can you please tell me how to disable session replay in sentry self hosted setup. as i do not want video recording data. also can you tell regarding mattermost integration using webhook.

aldy505 commented 5 months ago

can you please tell me how to disable session replay in sentry self hosted setup. as i do not want video recording data.

You only need to uncomment this line of code: https://github.com/getsentry/self-hosted/blob/9de4b70ece8b28d83d4b2e4a4b642ff14af52ae0/sentry/sentry.conf.example.py#L280

If you also want to lessen your Docker container, you might be able to remove these 2. I don't have 100% confidence that removing this two will not break your instance, but consider doing this at your own risk.

https://github.com/getsentry/self-hosted/blob/9de4b70ece8b28d83d4b2e4a4b642ff14af52ae0/docker-compose.yml#L275-L277

https://github.com/getsentry/self-hosted/blob/9de4b70ece8b28d83d4b2e4a4b642ff14af52ae0/docker-compose.yml#L375-L377

also can you tell regarding mattermost integration using webhook.

Sadly no, I have no idea about this.

Harsh-Kesharwani commented 4 months ago

@aldy505 can you tell me how can i test this below config for mail service

###############
# Mail Server #
###############

mail.backend: 'smtp'  # Use dummy if you want to disable email entirely
mail.host: 'email-smtp.us-east-1.amazonaws.com'
mail.port: 24xx
mail.username: 'AKIxxx'
mail.password: 'tCxx'
mail.use-tls:false
mail.use-ssl: true

# NOTE: The following 2 configs (mail.from and mail.list-namespace) are set
#       through SENTRY_MAIL_HOST in sentry.conf.py so remove those first if
#       you want your values in this file to be effective!

# The email address to send on behalf of
mail.from: 'info@x.com'

After running docker-compose logs worker i am getting invalid smtp credentials error but my credentials are correct After making these changes and installing again, i am unable to receive mails.

aldy505 commented 4 months ago

Should be

mail.use-tls: true
mail.use-ssl: false

Then the mail.list-namespace should be left commented (don't make it uncommented). Are you sure the mail port is 2465? Shouldn't that be 587 for AWS? I don't remember though, so I might be wrong.

Then do sudo ./install.sh again.

Harsh-Kesharwani commented 4 months ago

@aldy505 does ssl protocol not supported? i have updated host_mail in .env file now i am getting connection refused error.

azaslavsky commented 4 months ago

Can you copy the error here?

Harsh-Kesharwani commented 4 months ago

@azaslavsky

Here is below error i am getting: docker-compose logs worker

worker-1  | ConnectionRefusedError: [Errno 111] Connection refused
worker-1  | 06:21:03 [ERROR] celery.app.trace: Task sentry.tasks.email.send_email[17c8ae-e7ae-4b4f-b0b5-e9dd75648451] raised unexpected: ConnectionRefusedError(111, 'Connection refused') (data={'hostname': 'celery@17ce57ca5af0', 'id': '17c8a49e-e7ae-4b4f-b0b9dd75648451', 'name': 'sentry.tasks.email.send_email', 'exc': "ConnectionRefusedError(111, 'Connection refused')", 'traceback': 'Traceback (most recent call last):\n  File "/usr/local/lib/python3.11/site-packages/celery/app/trace.py", line 477, in trace_task\n    R = retval = fun(*args, **kwargs)\n                 ^^^^^^^^^^^^^^^^^^^^\n  File "/usr/local/lib/python3.11/site-packages/sentry_sdk/integrations/celery/__init__.py", line 332, in _inner\n    reraise(*exc_info)\n  File "/usr/local/lib/python3.11/site-packages/sentry_sdk/utils.py", line 1640, in reraise\n    raise value\n  File "/usr/local/lib/python3.11/site-packages/sentry_sdk/integrations/celery/__init__.py", line 327, in _inner\n    return 

i am using ssl. can you please help regarding this. As i am unable to send mails

azaslavsky commented 4 months ago

Hmm, it seems like your mail-server is not running - if you bring everything down and then up again, do all your servers say "Healthy"?

getsantry[bot] commented 3 weeks ago

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 🥀