I recently inherited a GitLab Omnibus instance in a Docker container.
Its getting tight with space on there. So tight that I cant even create backups.
ncdu tells me that /var/opt/gitlab/prometheus/data/wal/ has about 15Gig of Prometheus data on there.
the cleanup docks doesnt mention Prometheus at all. Can I get rid of it in a gentle way?
Thanks for taking the time to help here, it really matters!
Actualy I would like to have 'web.enable-admin-api'in that block too - but the reconfigure passes me an = into when i use an empty qoute, wich gets the instance into trouble.
these settings give you an /opt/gitlab/service/prometheus/runlike this
note:
when I would be able to pass the web.enable-admin-api flag I would run
curl -X POST -g 'http://localhost:9090/api/v1/admin/tsdb/delete_series?match[]={_name__=~".+"}'
curl -X POST -g 'http://localhost:9090/api/v1/admin/tsdb/clean_tombstones'
to get rid of all of the series
Now I have to get this only into an docker-compose.yaml enviroment…
After editing the gitlab.rb file you need to run “sudo gitlab-ctl reconfigure” to free up space. A simple gitlab restart won’t do. Btw I only made use of this change and the /var/opt/gitlab/prometheus directory went down from 8.3GB to 11MB.