Re: Inserts and bad performance

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Inserts and bad performance
Дата
Msg-id 185058.1637782313@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Inserts and bad performance  ("Godfrin, Philippe E" <Philippe.Godfrin@nov.com>)
Ответы RE: [EXTERNAL] Re: Inserts and bad performance
Список pgsql-general
"Godfrin, Philippe E" <Philippe.Godfrin@nov.com> writes:
> I am inserting a large number of rows, 5,10, 15 million. The python code commits every 5000 inserts. The table has
partitionedchildren. 
> At first, when there were a low number of rows inserted, the inserts would run at a good clip - 30 - 50K inserts per
second.Now, after inserting oh say 1.5 Billion rows, the insert rate has dropped to around 5000 inserts per second. I
droppedthe unique index , rebuilt the other indexes and no change. The instance is 16 vcpu and 64GB ram. 

Can you drop the indexes and not rebuild them till after the bulk load is
done?  Once the indexes exceed available RAM, insert performance is going
to fall off a cliff, except maybe for indexes that are receiving purely
sequential inserts (so that only the right end of the index gets touched).

Also see

https://www.postgresql.org/docs/current/populate.html

            regards, tom lane



В списке pgsql-general по дате отправления:

Предыдущее
От: "Godfrin, Philippe E"
Дата:
Сообщение: RE: [EXTERNAL] Re: Inserts and bad performance
Следующее
От: Gavin Roy
Дата:
Сообщение: Re: Inserts and bad performance