Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dropping measurements from a database yields Error: database not open but command succeeds #4615

Closed
erdii opened this issue Oct 29, 2015 · 6 comments

Comments

@erdii
Copy link

erdii commented Oct 29, 2015

as in title. the response is an error even though the command succeds and drops the specified measurements

I tried it with the internal AdminInterface, influxql and node-influx.

@erdii
Copy link
Author

erdii commented Oct 29, 2015

while investigating this issue this one appeared right now (yielded by dropMeasurements too)
[Error: open /usr/local/var/influxdb/wal/test_db/testrp/15/01.000003.wal: no such file or directory]
which totally confuses me since i dont have a db named "test_db" and i never had.

ls /usr/local/var/influxdb/wal returns _internal rsmq_monitor those are the only 2 databases on my Influxdb instance

@beckettsean
Copy link
Contributor

@erdii what version of InfluxDB are you running?

Can you paste in a CLI session showing the results of SHOW DATABASES and DROP MEASUREMENT foo, where foo is the measurement that yields the error?

From the behavior you describe my best guess is that somehow test_db was created by someone else and then removed.

Does the error persist through a restart of the influxd process? The metastore that maintains the database list is kept in RAM and reloaded on restart. If there is a ghost test_db somehow in the metastore, a restart should purge it.

@otoolep
Copy link
Contributor

otoolep commented Oct 29, 2015

Another strange issue that might be relevant, which is not actually an issue in tsm1.

#4303

@erdii
Copy link
Author

erdii commented Nov 2, 2015

I'm running InfluxDB 0.9.4.2 on OS X 10.11.1 installed via Brew

Strange.. I can't reproduce it anymore... I haven't changed anything in my Installation ( I guess I have^^ )...

EDIT: @beckettsean i guess the test_db issue was a one time event

@erdii
Copy link
Author

erdii commented Nov 2, 2015

> SHOW DATABASES
name: databases
---------------
name
_internal
rsmq_monitor

> USE rsmq_monitor
Using database rsmq_monitor
> SHOW MEASUREMENTS
name: measurements
------------------
name
probe

> SELECT * FROM probe
name: probe
-----------
time                attr    count   key qname   recv    sent
2015-10-29T14:44:21.535Z    1234
2015-10-29T14:46:38Z            150 queue1  q1  119850  120000
2015-10-29T14:46:43Z            100 queue1  q1  119900  120000
2015-10-29T14:46:48Z            50  queue1  q1  119950  120000
2015-10-29T14:46:53Z            0   queue1  q1  120000  120000
2015-10-29T14:46:53Z            2   queue2  q2  10  12
2015-10-29T14:49:34Z            150 queue1  q1  119850  120000
2015-10-29T14:49:39Z            100 queue1  q1  119900  120000
2015-10-29T14:49:44Z            50  queue1  q1  119950  120000
2015-10-29T14:49:49Z            2   queue2  q2  10  12
2015-10-29T14:49:49Z            0   queue1  q1  120000  120000

> DROP MEASUREMENT probe
ERR: database not open
> SELECT * FROM probe
>

The error is now persistent again

@beckettsean
Copy link
Contributor

Without the test_db issue this is a duplicate of #3551

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants