karthikvenkat17 / SAPStopStartACSS

MIT License
1 stars 1 forks source link

Azure - SAP ACSS script issues #1

Open VBraun2023 opened 1 year ago

VBraun2023 commented 1 year ago

Hi Venkat,

Thank you very much for providing these runbooks. While testing the ACSS runbooks I cam accross some issues and wonder if you would pick them up and fix. I was already in contact with Microsoft but they suggested to log the problems here. I'm attaching a Word document were Microsoft added some comments (highlighted in yellow). Would be so kind and take a look?

Many thanks and regards,

Volker ACSS-Automation-runbooks-Response.docx

karthikvenkat17 commented 1 year ago

Thanks @VBraun2023 for the sharing the test results. i will get them fixed.

VBraun2023 commented 1 year ago

Thank you, Venkat.

There is one more issue now. The stop script aborts with an error message for the DEV system DGA.

_Write-Error: SAP System DGA is not registered or environment is Production. Please check if the environment is correct or register the system and try again_

However, the status in ACSS shows "registered" .

Do you have any ideas what might be causing this error?

Regards, Volker 2023-11-15 09_12_11-Azure Center for SAP solutions - Microsoft Azure

VBraun2023 commented 11 months ago

Hi Venkat,

regarding the last error I believe the error is somewhere located in $sapVIS = Get-AzWorkloadsSapVirtualInstance -SubscriptionId $virtualInstanceSubscription | Where-Object { $_.Name -eq $virtualInstanceName } Write-Output $sapVIS if ($sapVIS.State -eq "RegistrationComplete") {

-and ##$sapVIS.Environment -ne "Production" )

    Write-Output "SAP Virtual Instance $($virtualInstanceName) is registerd and environment is not Production. Proceeding to stop SAP System"
}
else {
    Write-Error "SAP System $($sapVIS.State) is not registered or environment is Production. Please check if the environment is correct or register the system and try again" -ErrorAction Stop
}

Looks like Get-AzWorkloadsSapVirtualInstance is not returning any values. Am I missing some modules or maybe a wrong version of a module?

Thanks and regards

Volker