CREATE-STORAGE-VAULT
CREATE-STORAGE-VAULTβ
Descriptionβ
This command is used to create a storage vault. The subject of this document describes the syntax for creating Doris self-maintained storage vault.
CREATE STORAGE VAULT [IF NOT EXISTS] vault
[properties]
propertiesβ
type
Only two types of vaults are allowed: S3 and HDFS. -- Required
S3 Vaultβ
s3.endpoint
The endpoint used for object storage. Notice, please don't provide the endpoint with any
http://
orhttps://
. And for Azure Blob Storage, the endpoint should be like${ak}.blob.core.windows.net/
. -- Requireds3.region
The region of your bucket.(Not required when you'r using GCP or AZURE). -- Required
s3.root.path
The path where the data would be stored. -- Required
s3.bucket
The bucket of your object storage account. (StorageAccount if you're using Azure). -- Required
s3.access_key
The access key of your object storage account. (AccountName if you're using Azure). -- Required
s3.secret_key
The secret key of your object storage account. (AccountKey if you're using Azure). -- Required
provider
The cloud vendor which provides the object storage service. -- Required
HDFS Vaultβ
fs.defaultFS
Hadoop configuration property that specifies the default file system to use. -- Required
path_prefix
The path prefix to where the data would be stored. -- optional. It would be the root_path of your Hadoop user if you don't provide any prefix.
hadoop.username
Hadoop configuration property that specifies the user accessing the file system. -- optional. It would be the user starting Hadoop process if you don't provide any user.
hadoop.security.authentication
The authentication way used for hadoop. -- optional. If you'd like to use kerberos you can provide with
kerboros
.hadoop.kerberos.principal
The path to your kerberos principal. -- optional
hadoop.kerberos.keytab
The path to your kerberos keytab. -- optional
Exampleβ
create a HDFS storage vault.
CREATE STORAGE VAULT IF NOT EXISTS hdfs_vault
PROPERTIES (
"type"="hdfs",
"fs.defaultFS"="hdfs://127.0.0.1:8020"
);create a S3 storage vault using azure.
CREATE STORAGE VAULT IF NOT EXISTS s3_vault
PROPERTIES (
"type"="S3",
"s3.endpoint"="ak.blob.core.windows.net/",
"s3.access_key" = "ak",
"s3.secret_key" = "sk",
"s3.root.path" = "ssb_sf1_p2_s3",
"s3.bucket" = "doris-build-1308700295",
"provider" = "AZURE"
);create a S3 storage vault using OSS.
CREATE STORAGE VAULT IF NOT EXISTS s3_vault
PROPERTIES (
"type"="S3",
"s3.endpoint"="oss.aliyuncs.com",
"s3.access_key" = "ak",
"s3.secret_key" = "sk",
"s3.region" = "cn-hangzhou",
"s3.root.path" = "ssb_sf1_p2_s3",
"s3.bucket" = "doris-build-1308700295",
"provider" = "OSS"
);create a S3 storage vault using COS.
CREATE STORAGE VAULT IF NOT EXISTS s3_vault
PROPERTIES (
"type"="S3",
"s3.endpoint"="cos.ap-guangzhou.myqcloud.com",
"s3.access_key" = "ak",
"s3.secret_key" = "sk",
"s3.region" = "ap-guangzhou",
"s3.root.path" = "ssb_sf1_p2_s3",
"s3.bucket" = "doris-build-1308700295",
"provider" = "COS"
);create a S3 storage vault using OBS.
CREATE STORAGE VAULT IF NOT EXISTS s3_vault
PROPERTIES (
"type"="S3",
"s3.endpoint"="obs.cn-north-4.myhuaweicloud.com",
"s3.access_key" = "ak",
"s3.secret_key" = "sk",
"s3.region" = "cn-north-4",
"s3.root.path" = "ssb_sf1_p2_s3",
"s3.bucket" = "doris-build-1308700295",
"provider" = "OBS"
);create a S3 storage vault using AWS.
CREATE STORAGE VAULT IF NOT EXISTS s3_vault
PROPERTIES (
"type"="S3",
"s3.endpoint"="s3.us-east-1.amazonaws.com",
"s3.access_key" = "ak",
"s3.secret_key" = "sk",
"s3.region" = "us-east-1",
"s3.root.path" = "ssb_sf1_p2_s3",
"s3.bucket" = "doris-build-1308700295",
"provider" = "S3"
);
Keywordsβ
CREATE, STORAGE VAULT