Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Custom role not installed, lab sources file share not accessible #1605

Open
randallt opened this issue Feb 6, 2024 · 4 comments
Open

Comments

@randallt
Copy link

randallt commented Feb 6, 2024

Description

I am trying to install Exchange 2019 in Azure. I am using this redacted script to execute through the steps (up to Install-lab):
automatedlab_redacted.ps1.txt

I'm not sure if I got into a weird state issue with Azure resources. I ran it a few times where it appeared that everything succeeded, but when I went to the ExExVM, Exchange WAS NOT installed.

I deleted all AutomatedLab stuff from my Azure subscription and tried again, and now I'm getting an error on trying to mount the Exchange ISO:

15:23:45|01:12:56|00:00:04.189|       - Mounting ISO image '\\automatedlabsourcestjejh.file.core.windows.net\labsources\ISOs\ExchangeServer2019-x64-CU12.ISO' to computer 'ExExVM'
15:23:47|01:12:58|00:00:00.001|       - Executing lab command activity: 'Mounting ExchangeServer2019-x64-CU12.ISO on ExExVM' on machines 'ExExVM'
15:23:47|01:12:58|00:00:00.011|         - Waiting for completion
'\\automatedlabsourcestjejh.file.core.windows.net\labsources\ISOs\ExchangeServer2019-x64-CU12.ISO' is not accessible.
At C:\Program Files\WindowsPowerShell\Modules\AutomatedLabWorker\5.50.0\AutomatedLabWorker.psm1:5185 char:32
+             $result.AddRange(@(Invoke-Command @parameters))
+                                ~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : OperationStopped: ('\\automatedlab...not accessible.:String) [], RuntimeException
    + FullyQualifiedErrorId : '\\automatedlabsourcestjejh.file.core.windows.net\labsources\ISOs\ExchangeServer2019-x64-CU12.ISO' is not accessible.

Full log:
automatedlab_run_2024-02-06_fresh_after_deleting_LabSources.txt

If I log into any of the VMs, I get a message that a mapped network share could not be reconnected, so it seems to have something to do with that.
image
image

Steps to reproduce the issue

Tried to run through the '07.3 Exchange 2019 Server and client, domain joined.ps1' sample script, but adapted to run in Azure.

Commands used attached in description.

PowerShell Version

Name                           Value                                                                                                                                                                      
----                           -----                                                                                                                                                                      
PSVersion                      5.1.22621.2506                                                                                                                                                             
PSEdition                      Desktop                                                                                                                                                                    
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}                                                                                                                                                    
BuildVersion                   10.0.22621.2506                                                                                                                                                            
CLRVersion                     4.0.30319.42000                                                                                                                                                            
WSManStackVersion              3.0                                                                                                                                                                        
PSRemotingProtocolVersion      2.3                                                                                                                                                                        
SerializationVersion           1.1.0.1

AutomatedLab Version

Name                      Version
----                      -------
AutomatedLab              5.50.0 
AutomatedLab.Common       2.3.17 
AutomatedLab.Recipe       5.50.0 
AutomatedLab.Ships        5.50.0 
AutomatedLabCore          5.50.0 
AutomatedLabDefinition    5.50.0 
AutomatedLabNotifications 5.50.0 
AutomatedLabTest          5.50.0 
AutomatedLabUnattended    5.50.0 
AutomatedLabWorker        5.50.0
@randallt
Copy link
Author

randallt commented Feb 6, 2024

Is there something I'm missing here about getting the LabSources shared properly set up?

@randallt
Copy link
Author

randallt commented Feb 6, 2024

It looks like the automatic mapping of the file share into the VMs is not working.

According to:

This by default will synchronize your entire local lab sources folder with a pre-created Azure file share called labsources in the resource group AutomatedLabSources and the lab's randomly-named storage account. This file share will automatically be mapped on each virtual machine.
Operating system images are automatically skipped in the synchronization process as they are readily available on Azure and are not being used.

I manually mapped the storage account file share, and strangely, what are supposed to be the top-level folders are showing as files:
image

So something went wrong with the downloading of the ISO somehow.

@randallt
Copy link
Author

randallt commented Feb 6, 2024

Alright, I got this storage issue working by adding a call to Sync-LabAzureLabSources--that created the folders in the file share. Might be good to harden this a little.

After this, it appeared that the installation completed successfully, but when looking on the exchange VM, in the C:\ExchangeSetupLogs\ExchangeSetup.log file, there are a lot of errors about, e.g. PrepareAD not being run and .Net Framework 4.8 prereq not being met, and System.DirectoryServices.DirectoryServicesCOMException (0x80072030): There is no such object on the server.

I checked, and the .net version was still 4.7.2.

@randallt
Copy link
Author

randallt commented Feb 7, 2024

Just to follow up here. After many hours trying to debug this, it looks like the command to install .Net 4.8 on the Exchange VM just silently fails each time. However, it is successful on the DC, which is running through the same code. I flipped the order of the VMs and it still only failed on the Exchange VM. I haven't been able to find any indication of what is going wrong yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant