設定預設的 MySQL 認證

Microsoft.MySQLServer.SetDefaultCred.Task (Task)

設定 MySQL CIM 模組連線到執行中之伺服器時所要使用的認證。此工作會設定所有執行個體的預設使用者名稱及密碼

Element properties:

TargetMicrosoft.MySQLServer.Installation.Unix
AccessibilityPublic
CategoryMaintenance
EnabledTrue
RemotableFalse
Timeout300

Member Modules:

ID Module Type TypeId RunAs 
SetDefaultCredentials WriteAction Microsoft.MySQLServerCredentials.WSMan.Invoke.WriteAction Default

Source Code:

<Task ID="Microsoft.MySQLServer.SetDefaultCred.Task" Target="Microsoft.MySQLServer.Installation.Unix" Accessibility="Public" Enabled="true">
<Category>Maintenance</Category>
<WriteAction ID="SetDefaultCredentials" TypeID="Microsoft.MySQLServerCredentials.WSMan.Invoke.WriteAction">
<TargetSystem>$Target/Host/Property[Type="Unix!Microsoft.Unix.Computer"]/PrincipalName$</TargetSystem>
<MySQLUserName>$Config/MySQLUserName$</MySQLUserName>
<MySQLPassword>$Config/MySQLPassword$</MySQLPassword>
<MySQLPort>0</MySQLPort>
<BindAddress>$Target/Property[Type="Microsoft.MySQLServer.Installation"]/BindAddress$</BindAddress>
</WriteAction>
</Task>