共用方式為


New-AzureRmRedisCachePatchSchedule

新增修補程式排程。

警告

自 2024 年 2 月 29 日起,AzureRM PowerShell 模組已正式淘汰。 建議使用者從 AzureRM 遷移至 Az PowerShell 模組,以確保持續支援和更新。

雖然 AzureRM 模組可能仍可運作,但不再維護或支援它,但會根據用戶的判斷權和風險放置任何繼續使用。 如需轉換至 Az 模組的指引,請參閱我們的 移轉資源

語法

New-AzureRmRedisCachePatchSchedule
   [-ResourceGroupName <String>]
   -Name <String>
   -Entries <PSScheduleEntry[]>
   [-DefaultProfile <IAzureContextContainer>]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]

Description

New-AzureRmRedisCachePatchSchedule Cmdlet 會將修補程式排程新增至 Azure Redis 快取中的快取。

範例

範例 1:在快取上建立和新增修補程式排程

PS C:\>New-AzureRmRedisCachePatchSchedule -ResourceGroupName "ResourceGroup13" -Name "RedisCache06" -Entries @(New-AzureRmRedisCacheScheduleEntry -DayOfWeek "Weekend" -StartHourUtc 2 -MaintenanceWindow "06:00:00")

此命令會將修補程式排程新增至名為 RedisCache06 的快取。 Entries 參數會使用 New-AzureRmRedisCacheScheduleEntry 來建立排程的命令作為其值。

參數

-Confirm

執行 Cmdlet 之前先提示您確認。

類型:SwitchParameter
別名:cf
Position:Named
預設值:None
必要:False
接受管線輸入:False
接受萬用字元:False

-DefaultProfile

用於與 azure 通訊的認證、帳戶、租用戶和訂用帳戶。

類型:IAzureContextContainer
別名:AzureRmContext, AzureCredential
Position:Named
預設值:None
必要:False
接受管線輸入:False
接受萬用字元:False

-Entries

指定此 Cmdlet 在快取上設定的排程數位。 若要取得 PSScheduleEntry 物件,請使用 New-AzureRmRedisCacheScheduleEntry Cmdlet。

類型:PSScheduleEntry[]
Position:Named
預設值:None
必要:True
接受管線輸入:True
接受萬用字元:False

-Name

指定快取的名稱。

類型:String
Position:Named
預設值:None
必要:True
接受管線輸入:True
接受萬用字元:False

-ResourceGroupName

指定包含快取的資源群組名稱。

類型:String
Position:Named
預設值:None
必要:False
接受管線輸入:True
接受萬用字元:False

-WhatIf

顯示執行 Cmdlet 後會發生的情況。 未執行 Cmdlet。

類型:SwitchParameter
別名:wi
Position:Named
預設值:None
必要:False
接受管線輸入:False
接受萬用字元:False

輸入

String

PSScheduleEntry[]

輸出

PSScheduleEntry

備註

  • 關鍵詞:azure、azurerm、arm、resource、management、manager、redis、cache、web、webapp、website