user2371220
user2371220

Reputation: 63

SQLite3 database or disk is full

I am working on a linux server. When I submit the query like this one below,

create table test1 as select id, sum(amount) from sales group by id;

I got the error that "database or disk is full". I have contacted with the server administrator and he is sure that I have enough space for this query and he can generate this table without any problem.

Then I tried another query

create table test2 as select * from sales limit 100000000;

This time everything is good. My administrator believes that this is caused by permission problem. But I was wondering that if it is a permission problem, I could not generate table test2 at all. Do you have any ideas? Thanks a lot!

Upvotes: 4

Views: 7986

Answers (1)

Dragon Dave
Dragon Dave

Reputation: 667

Ensure that your temporary directory is not full / is large enough: I've just hit this problem and it was caused by /tmp being completely full of junk. Wiping that out made it work fine.

Specifically in my instance:

select 1 from table group by x

was working, but

select 1 from table group by x, y

was not.

"Vacuum" command is failing with "SQL Error: Database or Disk is full"

Upvotes: 3

Related Questions