New-AzCosmosDBService
建立新的 CosmosDB 服務。
語法
New-AzCosmosDBService
-ResourceGroupName <String>
-AccountName <String>
-ServiceName <String>
-InstanceSize <String>
-InstanceCount <Int32>
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
New-AzCosmosDBService
-ServiceName <String>
-InstanceSize <String>
-InstanceCount <Int32>
-ParentObject <PSDatabaseAccountGetResults>
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Description
New-AzCosmosDBService Cmdlet 會建立新的 CosmosDB 服務。
範例
範例 1
New-AzCosmosDBService -ResourceGroupName "ResourceGroup" -AccountName "AccountName" -ServiceName "ServiceName" -InstanceSize "Cosmos.D4s" -InstanceCount 1
Name : {serviceName}
Id : {id}
Resource : Microsoft.Azure.Commands.CosmosDB.Models.PSServiceGetResults
參數
-AccountName
Cosmos DB 資料庫帳戶的名稱。
類型: | String |
Position: | Named |
預設值: | None |
必要: | True |
接受管線輸入: | False |
接受萬用字元: | False |
-DefaultProfile
用於與 Azure 通訊的認證、帳戶、租用戶和訂用帳戶。
類型: | IAzureContextContainer |
別名: | AzContext, AzureRmContext, AzureCredential |
Position: | Named |
預設值: | None |
必要: | False |
接受管線輸入: | False |
接受萬用字元: | False |
-InstanceCount
服務的實例大小
類型: | Int32 |
Position: | Named |
預設值: | None |
必要: | True |
接受管線輸入: | False |
接受萬用字元: | False |
-InstanceSize
服務的實例計數
類型: | String |
Position: | Named |
預設值: | None |
必要: | True |
接受管線輸入: | False |
接受萬用字元: | False |
-ParentObject
CosmosDB Account 物件
類型: | PSDatabaseAccountGetResults |
Position: | Named |
預設值: | None |
必要: | True |
接受管線輸入: | True |
接受萬用字元: | False |
-ResourceGroupName
資源組名。
類型: | String |
Position: | Named |
預設值: | None |
必要: | True |
接受管線輸入: | False |
接受萬用字元: | False |
-ServiceName
服務的名稱
類型: | String |
Position: | Named |
預設值: | None |
必要: | True |
接受管線輸入: | False |
接受萬用字元: | False |