[GENERAL] Loading a database, why do I need superuser? - Mailing list pgsql-general

From Evan Howarth
Subject [GENERAL] Loading a database, why do I need superuser?
Date
Msg-id D33A553681746AD1@dal.intellicall.com
Whole thread Raw
List pgsql-general
======== Original Message ========
I'm in the process of loading a database on a virtual server.
Because I do not have root privileges (technically it is a shared machine),
I am encountering all sorts of hiccups.  Trying the copy command to
load the database with comma delimited data, I encounter this complaint:

    ERROR:  You must have Postgres superuser privilege to do a COPY
    directly to or from a file.  Anyone can COPY to stdout or from stdin

There is NO mention of this in the man page or documentation that I have
perused.  Perhaps I have a privilege problem?

Charles Gilley
======== Fwd by: Evan Howarth  ========
Correct. You lack the 'super' privilege -- one of four privileges listed in
the 'pg_user' table. Unfortunately, your system administrator may not wish
to grant you that privilege because it also gives you the right to change
passwords and view/modify other user's tables. So the problem boils down to
a lack of granularity in user privileges.

One workaround might be asking your system administrator to create an
account for COPY to/from files. Your admin can give you the password before
each COPY session. Then after 15 minutes or so, he could change the
password. If he's worried about your access, he could monitor the activity
during that time. (This suggestion assumes you do not need COPY very
frequently.)

Evan Howarth

pgsql-general by date:

Previous
From: Jeroen Schaap
Date:
Subject: Re: [GENERAL] Re: Large Objects
Next
From: Oleg Broytmann
Date:
Subject: Date/time problem