How to remove all measures on Gnocchi?

asked 2017-10-26 02:59:34 -0500

michelgokan3 gravatar image

Hi,

When I run gnocchi status I get the following, which I think is showing that something is wrong:

+-----------------------------------------------------+--------+
| Field                                               | Value  |
+-----------------------------------------------------+--------+
| storage/number of metric having measures to process | 137    |
| storage/total number of measures to process         | 169672 |
+-----------------------------------------------------+--------+

Now I want to know how can I reset this database because its continiously growing and I have thousands lines of errors in my gnocchi.log, such as:

...
2017-10-26 09:46:22.162 7032 DEBUG gnocchi.cli [-] 32 metrics scheduled for processing. _run_job /usr/lib/python2.7/dist-packages/gnocchi/cli.py:244
2017-10-26 09:46:22.191 7041 DEBUG gnocchi.cli [-] Metrics marked for deletion removed from backend _run_job /usr/lib/python2.7/dist-packages/gnocchi/cli.py:267
2017-10-26 09:46:22.196 7032 DEBUG futurist.periodics [-] Submitting periodic function 'gnocchi.cli.run_watchers' _process_scheduled /usr/lib/python2.7/dist-packages/futurist/periodics.py:611
2017-10-26 09:46:22.203 7036 DEBUG gnocchi.storage [-] Processing new measures process_background_tasks /usr/lib/python2.7/dist-packages/gnocchi/storage/__init__.py:171
2017-10-26 09:46:22.203 7034 DEBUG gnocchi.storage [-] Processing new measures process_background_tasks /usr/lib/python2.7/dist-packages/gnocchi/storage/__init__.py:171
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage [-] Unexpected error during measures processing
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage Traceback (most recent call last):
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage   File "/usr/lib/python2.7/dist-packages/gnocchi/storage/__init__.py", line 173, in process_background_tasks
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage     self.process_new_measures(index, metrics, sync)
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage   File "/usr/lib/python2.7/dist-packages/gnocchi/storage/_carbonara.py", line 461, in process_new_measures
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage     if not lock.acquire(blocking=sync):
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage   File "/usr/lib/python2.7/dist-packages/tooz/drivers/file.py", line 139, in acquire
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage     timeout=watch.leftover(return_none=True))
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage   File "/usr/lib/python2.7/dist-packages/fasteners/process_lock.py", line 147, in acquire
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage     self._do_open()
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage   File "/usr/lib/python2.7/dist-packages/fasteners/process_lock.py", line 119, in _do_open
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage     self.lockfile = open(self.path, 'a')
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage IOError: [Errno 13] Permission denied: u'/var/lib/gnocchi/locks/gnocchi-0929c52f-d5be-4db4-8cc1-e539f99b31ba'
2017-10-26 09:46:22.209 7034 ERROR gnocchi.storage 
2017-10-26 09:46:22.209 7036 ERROR gnocchi.storage [-] Unexpected error during measures processing
2017-10-26 09:46:22.209 7036 ERROR gnocchi.storage Traceback (most recent call last):
2017-10-26 09:46:22.209 7036 ERROR gnocchi.storage   File "/usr/lib/python2.7/dist-packages/gnocchi/storage/__init__.py", line 173, in process_background_tasks
2017-10-26 09:46:22.209 7036 ERROR gnocchi.storage     self.process_new_measures(index, metrics, sync)
2017-10-26 09:46:22.209 7036 ERROR gnocchi.storage ...
(more)
edit retag flag offensive close merge delete

Comments

1

did a chmod -R 777 /var/lib/gnocchi/locks fixed the error. But the number of "total number of measures to process" is not decreasing and still a little bit increasing

michelgokan3 gravatar imagemichelgokan3 ( 2017-10-26 06:28:01 -0500 )edit