Re: temporary data after diskspace error

2020-01-28 Thread Willy-Bas Loos
I did the restart and it took seconds. This was on a SSD. BTW on ubuntu and debian i never use pg_ctl directly, postgresql-common has a very nice CLI for this. For the restart i used: sudo pg_ctlcluster --force 9.4 main restart Thanks for all the good advice! On Mon, Jan 27, 2020 at 10:15 PM Tom

Re: temporary data after diskspace error

2020-01-27 Thread Tom Lane
Willy-Bas Loos writes: > Will there be a lot of downtime to delete those 90GB of temp files? > Will postgres just delete those files without processing them or should I > brace for some downtime? It's just a directory scan and an unlink() for each file that has the right filename pattern to be a

Re: temporary data after diskspace error

2020-01-27 Thread Willy-Bas Loos
Ok, thanks everyone! Will there be a lot of downtime to delete those 90GB of temp files? Will postgres just delete those files without processing them or should I brace for some downtime? Op ma 27 jan. 2020 17:15 schreef Tom Lane : > Willy-Bas Loos writes: > > And also: How can i make postgres

Re: temporary data after diskspace error

2020-01-27 Thread Michael Lewis
In terms of preventing this happening again, you might consider setting some reasonable temp_file_limit as default. Alternatively or additionally, you can set up another volume and direct temp files to use that to avoid the server crashing if excessive temp files are used in a moment's time. Then o

Re: temporary data after diskspace error

2020-01-27 Thread Tom Lane
Willy-Bas Loos writes: > And also: How can i make postgres clean up the files? > Can it be done without restarting the cluster? > Will restarting it help? A restart will clean out temp files. I don't think there's any terribly safe way to do it without that. You could manually remove such files

Re: temporary data after diskspace error

2020-01-27 Thread Ron
On 1/27/20 10:05 AM, Willy-Bas Loos wrote: Hi, We have a server with postgresql 9.4.12 on ubuntu. There has been a sudden rise in the amount of disk space used by postgresql, causing a diskspace error: 2020-01-22 17:24:37 CET db: ip: us: PANIC:  could not write to file "pg_xlog/xlogtemp.2334

temporary data after diskspace error

2020-01-27 Thread Willy-Bas Loos
Hi, We have a server with postgresql 9.4.12 on ubuntu. There has been a sudden rise in the amount of disk space used by postgresql, causing a diskspace error: 2020-01-22 17:24:37 CET db: ip: us: PANIC: could not write to file "pg_xlog/xlogtemp.23346": No space left on device 2020-01-22 17:24:37