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

sql: in cockroach demo, disk spilling produces confusing error message #42926

Closed
solongordon opened this issue Dec 3, 2019 · 2 comments
Closed
Labels

Comments

@solongordon
Copy link
Contributor

If a query in cockroach demo attempts to spill to disk, it throws a confusing already using disk error, presumably because we try to spill but there is zero budget for it.

Repro:

$ cockroach demo <<EOF
create table t (x int, y text, index (x, y));
create table t2 (x int);
insert into t select 1, repeat('a', 1024) from generate_series(1, 200000);
insert into t2 values (1);
select distinct y from t2 inner lookup join t on t.x = t2.x;
EOF

Result:

Error: pq: already using disk
Failed running "demo"

It seems fine for demo not to support spilling, but we should make this clearer in the error message.

@knz
Copy link
Contributor

knz commented Apr 24, 2020

I think disk spilling has been enabled for cockroach demo. I get the following message:

ERROR: this query requires additional disk space: in-mem temp storage: disk budget exceeded: 1048576 bytes requested, 104857600 currently allocated, 104857600 bytes in budget

@rohany can you confirm and close the issue?

@asubiotto
Copy link
Contributor

This has been fixed. The issue was that an in-memory temp store would return an OutOfMemory error when the disk budget hit a limit, instead of an OutOfDisk, which would cause us to try to spill to disk again and return "already using disk".

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

No branches or pull requests

3 participants