ERROR: permission denied for storage location

Moderator: NorbertKrupa

seanarcher7
Newbie
Newbie
Posts: 7
Joined: Thu Apr 04, 2013 8:43 pm

Re: ERROR: permission denied for storage location

Post by seanarcher7 » Fri Apr 12, 2013 1:34 pm

Hi All,

We have resolved this. In Vertica, only a super user (or sudo) can copy the data. See the following from manual:
Only a superuser can use the COPY statement to bulk load data. The COPY exceptions to requiring a superuser to bulk load data files are to run copy to load from a stream on the host (such as STDIN) rather than a file (see Streaming Data via JDBC), or to use the COPY statement with its
FROM LOCAL option. A non-superuser can also perform a standard batch insert using a prepared statement, which invokes COPY as a background task to load data.
So, we need to add the word 'local' to the copy command. The below modification will work.

Code: Select all

copy wdrake.copy_test from local '/home/wdrake/my.txt' direct no escape null as '\N';

User avatar
JimKnicely
Site Admin
Site Admin
Posts: 1825
Joined: Sat Jan 21, 2012 4:58 am
Contact:

Re: ERROR: permission denied for storage location

Post by JimKnicely » Fri Apr 12, 2013 1:53 pm

Thanks for the update! I'm sure it'll help others!

Here's a link to an older post on the same subject:

viewtopic.php?f=5&t=515
Jim Knicely

Image

Note: I work for Vertica. My views, opinions, and thoughts expressed here do not represent those of my employer.

Post Reply

Return to “Vertica Error Codes”