cancel
Showing results for 
Search instead for 
Did you mean: 

EDB Loader need superuser permisson

Highlighted
Adventurer

EDB Loader need superuser permisson

Dear Team

 

Currently, we are having EB version 11 on the production environment and we need to bulk many data, from what I've heard we can use some tools called edbldr, but it came with great prospects for us, except you need to invoke it using superuser role, which in our environment it can't be done. We have been stuck in this case for days now. Can you help us to know if there is other tools that can do the same thing or why should edbldr use the superuser role?

 

Thank you and regards

Akbar Zaldi

 

6 REPLIES 6
EDB Team Member

Re: EDB Loader need superuser permisson

Hi Akbar,

Below links may help for your requirements :

COPY :
https://www.enterprisedb.com/docs/en/9.3/pg/sql-copy.html

https://www.postgresql.org/docs/10/sql-copy.html

 

EDB LOADER : (Must requires superuser privileges)
https://www.enterprisedb.com/edb-docs/d/edb-postgres-advanced-server/user-guides/database-compatibil...

Could you please try with this approach and let us know in case of any concerns/issues.

Regards,
Aamir Shaikh

Adventurer

Re: EDB Loader need superuser permisson

Hello Aamir

 

Regarding your options we have an issue about copy, can we know-how many data we process and how many data being rejected by the system? And about the edbldr can we have some default profile (but not superuser) to run it?

 

Regards,

Akbar Zaldi

EDB Team Member

Re: EDB Loader need superuser permisson

Hi Akbar,

Regarding copy statement,

Copy statement can work only if data is valid in the file. No record will be inserted if any record is invalid in the source file.

 

Regarding edbldr, you can get .bad file for rejected data and the rest of the records get loaded.

edbldr must run with superuser or superuser privileged user.

 

Ex: you can grant superuser privilege to normal user and run edbldr, you can revoke superuser privilege back. Ex: Below

edb=# alter user normal_user superuser;
ALTER ROLE
edb=# \q
[enterprisedb@localhost:~]$/usr/edb/as11/bin/edbldr userid=normal_user/Edbldr control=/home/enterprisedb/control.ctl -d edb -p 5444
edb=# alter user normal_user nosuperuser;
ALTER ROLE
edb=# \q

 

Please let us know if you have any concerns.

Adventurer

Re: EDB Loader need superuser permisson

Hi Aamir

Out concern regarding copy statement is our application team want to insert some data event though some of it being rejected by system.

For edbldr, we can’t know for sure when application team will invoke the command manually.

I googled that pgloader or pg_bulkload can be used as an extension in postgresql community. Can it be used in enterprisedb as well?
EDB Team Member

Re: EDB Loader need superuser permisson

Hi @akbar_9090,

 

You can use those tools with the EDB postgres as well, however, the functionality of those tools is similar to EDB Loader. We recommend to use the EDB Loader with EDB postgres and also if you want to test other tools, please do that first in the test environment.

 

Regards,

Sudhir

Adventurer

Re: EDB Loader need superuser permisson