Comments (5)
vacuum full rewrite table and all indexes, but vacuum full uses exclusive lock - and this is primary reason to using pgcompacttable or pg_repack. But pgcompactable does not use vacuum full (and no reindex command too), instead it calls updates on table and rebuild indexes by creating new index (concurrently), rename new index to old one and then drop old index.
So reindex in pgcompacttable is another stuff and has few options to control behavior.
from pgcompacttable.
I understand about vacuum full and exclusive lock, and I also understand pgcompacttable is basically a vacuum full without the long locks. My question is why have REINDEX parameters for pgcompacttable since you are basically dropping indexes and creating new ones?
from pgcompacttable.
which parameters do you mean? beside creating and dropping indexes (which could be done concurrently without heavy locks) pgcompacttable also renaming newly created indexes to old name which requires short heavy lock which might not be available at a time and pgcompacttable will try to acquire it cycle with lock timeout and pause between iterations. so that's why reindex-retry-count, reindex-retry-pause, reindex-lock-timeout were introduced.
from pgcompacttable.
I'm sorry but I am still not understanding you completely. When you say REINDEX, you don't mean the actual PostgreSQL REINDEX command, you mean rename command, right?
from pgcompacttable.
Yes, we speaking not about reindex command (it uses heavy lock too). pgcompacttable uses word "reindex" for process create index concurrently + alter index rename + drop index concurrently.
from pgcompacttable.
Related Issues (20)
- Can't compact toast tables HOT 1
- Advisory lock never cleared, and connection not closed on interrupt leads to wedged locks
- Huge deadlocks count on the last phase operations ALTER INDEX RENAME TO HOT 6
- Can not process the big table. HOT 3
- Use of uninitialized value in subtraction HOT 1
- Try to install pgstattuple
- option "--routine-vacuum" HOT 2
- Latest changes broke several databases on different servers HOT 8
- Question: How many extra space do I need when I run this tool? HOT 5
- SQL Error while compacting HOT 4
- Multiple runs for big tables HOT 3
- Error "relation "public.pg_toast_5987783_index" does not exist" when running the utility HOT 3
- Question about --reindex-* parameters HOT 2
- Question about --routine-vacuum parameter HOT 2
- RDS support HOT 1
- Configurable `MAX_PAGES_PER_ROUND` HOT 1
- creating invalid index every run.
- This attempt has been initially expected to compact ~24% more space HOT 7
- Deleting comments HOT 1
- `session_replication_role` lost on reconnect
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pgcompacttable.