RE: Need support on tuning at the time of index creation

From: Sandip Pradhan <sandip(dot)pradhan(at)ericsson(dot)com>
To: "Peter J(dot) Holzer" <hjp-pgsql(at)hjp(dot)at>, "pgsql-general(at)lists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: RE: Need support on tuning at the time of index creation
Date: 2020-01-31 10:13:20
Message-ID: VI1PR07MB49122CB6E927CC4E1B3ED1DAE6070@VI1PR07MB4912.eurprd07.prod.outlook.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi Peter,

Thanks for your time.

Out Postgresql version: 9.5.9.14.

We are using COPY command to insert rows into the tables. While running COPY command, all indexes dropped.

After successfully inserting all the rows, we are trying to create all those indexes.

Example of index creation script:
CREATE INDEX cwt_sr_assocact_entityref
ON cwt_sr_associationact
USING btree
(entityapplicationcontext COLLATE pg_catalog."default", entitytype COLLATE pg_catalog."default", entitydn COLLATE pg_catalog."default");

CREATE INDEX ix_sr_assoc_customerrelateddn
ON cwt_sr_associationact
USING btree
(customerrelateddn COLLATE pg_catalog."default");

Running indexes in parallel.

Please find the hardware detail of the server:
OS: Red Hat Enterprise Linux 7.4
RAM: 125 GB
CPU Core: 36

Set maintenance_work_mem to 25GB

Please let me know if you need any further information.

Regards,

 
Sandip Pradhan
Tech Lead
 
BDGS SD IN BSS EOC_ECM 1
Mobile: 9830880856
sandip(dot)pradhan(at)ericsson(dot)com
 
Ericsson
DLF IT Park - II, DLF SEZ Block 1A, Rajarhat
700156, Kolkata, West Bengal
India
ericsson.com

-----Original Message-----
From: Peter J. Holzer <hjp-pgsql(at)hjp(dot)at>
Sent: Tuesday, January 28, 2020 4:16 AM
To: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: Need support on tuning at the time of index creation

On 2020-01-27 11:10:36 +0000, Sandip Pradhan wrote:
> One of our ericsson product used backend db as postgresql 9. We are
> facing following performance issues where we need some support from your side.
> We are having 10 tables and we are inserting around 150 million to 250
> million records on each of those tables. After that we need to create
> 29 indexes includung primary key index and other types of indexes.
> Currently it is taking almost 3.5 to 4 hrs.

It is hard to give advice on what you could do differently if you don't tell us what you do.

How are you inserting those rows?
How are you creating the indexes?

Especially: Are you doing things serially or in parallel?

Also performance depends a lot on hardware, so faster CPUs (or more
cores) and faster disks/ssds might help, too.

hp

--
_ | Peter J. Holzer | Story must make more sense than reality.
|_|_) | |
| | | hjp(at)hjp(dot)at | -- Charles Stross, "Creative writing
__/ | https://protect2.fireeye.com/v1/url?k=228fefe0-7e0635f0-228faf7b-0cc47ad93e2a-0af0cf5ca8f30246&q=1&e=467afc4c-b87f-4d98-9a57-bf0596fd612a&u=http%3A%2F%2Fwww.hjp.at%2F | challenge!"

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Sandip Pradhan 2020-01-31 10:14:12 RE: Need support on tuning at the time of index creation
Previous Message Nicola Contu 2020-01-31 10:05:34 Re: ERROR: too many dynamic shared memory segments