DEV Community

Discussion on: Clean Sentry On-Premise Database

Collapse
 
makrand profile image
Makrand

Hello Ashraful,

For me I am stuck at this in worker container. I have close to 1.1 TB data here.

root@6868e8f50bf8:/# sentry cleanup --days 8
/usr/local/lib/python3.8/site-packages/sentry/runner/initializer.py:555: DeprecatedSettingWarning: The SENTRY_URL_PREFIX setting is deprecated. Please use SENTRY_OPTIONS['system.url-prefix'] instead.
warnings.warn(DeprecatedSettingWarning(old, "SENTRY_OPTIONS['%s']" % new))
/usr/local/lib/python3.8/site-packages/memcache.py:1303: SyntaxWarning: "is" with a literal. Did you mean "=="?
if key is '':
/usr/local/lib/python3.8/site-packages/memcache.py:1304: SyntaxWarning: "is" with a literal. Did you mean "=="?
if key_extra_len is 0:
06:03:37 [INFO] sentry.plugins.github: apps-not-configured
Removing expired values for LostPasswordHash
Removing expired values for OrganizationMember
Removing expired values for ApiGrant
Removing expired values for ApiToken
Removing expired files associated with ExportedData
Removing old NodeStore values

It is stuck here for about 15 mins now. Any idea what can be done now?

Also, here is how psql looks

postgres=# SELECT oid::regclass, reltoastrelid::regclass, pg_relation_size(reltoastrelid) AS toast_size FROM pg_class WHERE relkind = 'r' AND reltoastrelid <> 0 ORDER BY 3 DESC;
oid | reltoastrelid | toast_size

--------------------------------------------+-------------------------+--------------
nodestore_node | pg_toast.pg_toast_20250 | 561381097472
pg_rewrite | pg_toast.pg_toast_2618 | 385024