1

IIS を有効にする単純な構成を使用してストレージ アカウントをプロビジョニングしました。サブスクリプションは適切に処理されており、zip は BLOB ストレージに存在し、問題なく設定されているようです。いくつかの出力:

VERBOSE: Performing the operation "Apply configuration 'IISInstall'" on target "VM".
[2015-05-18 21:58:13] With extensions added:
[2015-05-18 21:58:13] Microsoft.WindowsAzure.Commands.ServiceManagement.Model.PersistentVM
OperationDescription : New-AzureService
OperationId          : 257df04c-cc1f-a4d5-a840-e127f9e799bd
OperationStatus      : Succeeded

問題なく VM を作成します。

VERBOSE: 9:58:19 PM - Begin Operation: New-AzureVM - Create Deployment with VM fbconfigtest5
VERBOSE: 9:59:53 PM - Completed Operation: New-AzureVM - Create Deployment with VM fbconfigtest5
OperationDescription : New-AzureVM
OperationId          : 5063c04f-8902-abb2-838a-3d7f5f685bc2
OperationStatus      : Succeeded

VERBOSE: 9:59:54 PM - InstanceStatus is RoleStateUnknown
VERBOSE: 10:01:27 PM - InstanceStatus is Provisioning
VERBOSE: 10:05:36 PM - InstanceStatus is ReadyRole
[2015-05-18 22:05:36] Vm Created: 
[2015-05-18 22:05:36] Succeeded

そして、ポーリング ループに入り、DSC が完了するのを待ちます。

$status = Get-AzureVMDscExtensionStatus -ServiceName $ServiceName -Name $ServiceName

while($status.StatusCode -ne 1 -and $CurrTime -lt $TimeOut )
{
    $CurrTime = Get-Date
    $status = Get-AzureVMDscExtensionStatus -ServiceName $ServiceName -Name     $ServiceName -verbose
    write-log "Currents status is :"
    write-log $status.Status
    Write-log $status.StatusMessage
    write-log $status.DscConfigurationLog
    start-sleep -seconds 60
}

約 5 分かかりますが、私が報告するステータスの 3 つのバリエーションは次のとおりです。

VERBOSE: 10:05:38 PM - Completed Operation: Get Deployment
WARNING: The specified resource extension reference cannot be found.
[2015-05-18 22:05:38] Currents status is :

...

VERBOSE: 10:07:43 PM - Completed Operation: Get Deployment
[2015-05-18 22:07:43] Currents status is :
[2015-05-18 22:07:43] Transitioning
[2015-05-18 22:07:44] Initializing DSC extension.

...

VERBOSE: 10:10:50 PM - Completed Operation: Get Deployment
[2015-05-18 22:10:50] Currents status is :
[2015-05-18 22:10:51] Transitioning
[2015-05-18 22:10:51] Rebooting VM to complete installation.

...

VERBOSE: 10:16:02 PM - Completed Operation: Get Deployment
[2015-05-18 22:16:02] Currents status is :
[2015-05-18 22:16:02] Error
[2015-05-18 22:16:02] An error occurred downloading the Azure Blob: Exception calling "DownloadFile" with "2" argument(s): "The remote server returned an error: (404) Not Found."
The Set-AzureVMDscExtension cmdlet grants access to the blobs only for 1 hour; have you exceeded that interval?

これは、次のブログ投稿のサンプル コードと非常によく似ています。 dsc 拡張機能.aspx

新しい命名規則が使用されていますか? Config を再度設定して vm を次のように更新しても、次のようになります。

$aVM = Get-AzureVM -ServiceName fbconfigtest5 -Name fbconfigtest5
$aVM = Set-AzureVMDscExtension -VM $aVM -ConfigurationArchive IISInstall.ps1.zip -ConfigurationName IISInstall -ContainerName windows-powershell-dsc
$aVM | Update-AzureVM

それでも同じエラーが発生します。

Get-AzureVMDscExtensionStatus -ServiceName $ServiceName -Name $ServiceName -verbose
VERBOSE: 10:51:06 PM - Completed Operation: Get Deployment

ServiceName         : fbconfigtest5
Name                : fbconfigtest5
Status              : Error
StatusCode          : -1
Timestamp           : 5/18/2015 10:13:55 PM
StatusMessage       : An error occurred downloading the Azure Blob: Exception calling "DownloadFile" with "2" argument(s): "The remote server returned an 
                  error: (404) Not Found."
                  The Set-AzureVMDscExtension cmdlet grants access to the blobs only for 1 hour; have you exceeded that interval?
DscConfigurationLog : {}

アイデア、考えはありますか?コンテキストについてもっと明確にしようと思いますが、タイムスタンプによると、この VM の時間枠をほとんど超えています。家に帰ったら、非常に明示的な構成ストレージ、呼び出し、およびコンテキスト設定で更新します。

4

1 に答える 1

0

ランディ

で使用したものと同じストレージ コンテキストを使用して、コマンドレットPublish-AzureVMDscConfigurationで構成アーカイブを公開していることを確認してください。Set-AzureVMDscExtension

これで問題が解決しない場合は、zip ファイルを Azure に公開する方法の詳細を含む完全な再現を追加し、1 時間以内に新しい「マシン側ログからの URL」を使用して自分で blob をダウンロードしてみてください。ランニングセット。

于 2015-06-26T23:14:34.620 に答える