Export To Parquet Default Directory Permission
I am using EXPORT TO PARQUET to export my table.
EXPORT TO PARQUET (directory = '/datalake/2018/201810/dim') AS SELECT * FROM dim;
I noticed that the permission for /datalake/2018/201810/dim is set to "drwx--S---" by default. Only dbadmin user can access the files inside the directory.
Is there a way to change the default permission to allow users from the same group to access the underlying parquet files?
Regards,
Victor
0
Comments
Hi,
You can create a "user" storage location (where the usage type = USER)!
See:
https://www.vertica.com/docs/9.1.x/HTML/index.htm#Authoring/SQLReferenceManual/Statements/CreateLocation.htm
https://www.vertica.com/docs/9.1.x/HTML/index.htm#Authoring/AdministratorsGuide/DBUsersAndPrivileges/Privileges/StorageLocationPrivileges.htm
Hi Jim,
I understand that by creating a "user" storage location, I am able to grant the read permission to other database users.
However, I am trying to share the exported parquet files with other applications outside of Vertica. Is it possible to change the default directory permission at OS level from "drwx--S---" to "drwxrwsr-x"?
Thanks!
Hi,
There is not currently a way to change the "default" directory permissions when exporting to Parquet. There is a feature coming very soon that will let you do that if exporting to HDFS. And there is also a feature request for other file systems to be supported. I'll update the JIRA to let them know about your interest.
For now, maybe you can change the permissions yourself from vsql (if that's how you are exporting)?
Example: