This repository contains scripts, code and samples for automating the install and configuration of ArcGIS (Enterprise and Desktop) using Microsoft Windows PowerShell DSC (Desired State Configuration).
Apache License 2.0
120
stars
62
forks
source link
Documentation: Portal Content directory must exist, it will not be created #518
In this example the shared storage is on server.email.com and the main host is svr1.email.com that portal is installed onto.
Expected Behavior
Portal content directory would be created, like the default one is if it does not exist. In this example that would be \\server.email.com\share\PROJECT\Portal which has filepaths up to \\server.email.com\share\PROJECT created, but not Portal, as I figured that the installer would create the site directory.
Actual Behavior
It errors out saying cannot read from directory, because it was not created.
Trace-DSCJob : 1/16/2024 1:28:00 PM: PowerShell DSC resource ArcGIS_Portal failed to execute Set-TargetResource
functionality with error message: Cannot read from directory path
'\\server.email.com\share\PROJECT\Portal'. Please check that the location is valid and that the Portal
service account has permissions to the location.
At C:\Program Files\WindowsPowerShell\Modules\ArcGIS\4.2.0\ArcGIS.psm1:261 char:5
+ Trace-DSCJob -Job $Job -JobName $ConfigurationName -DebugMode $De ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException
+ FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Trace-DSCJob
Trace-DSCJob : 1/16/2024 1:28:00 PM: The SendConfigurationApply function did not succeed.
At C:\Program Files\WindowsPowerShell\Modules\ArcGIS\4.2.0\ArcGIS.psm1:261 char:5
+ Trace-DSCJob -Job $Job -JobName $ConfigurationName -DebugMode $De ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException
+ FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Trace-DSCJob
Steps to Reproduce
I have not tested making a brand new repro for this but for me it was:
Run the above script with InstallLicenseConfigure, making sure ContentDir is on a shared filesystem that contains all folders until the /Portal one, which is where I'd like the content directory to be made
Wait until it gets to the createSite step, which fails (this is probably a problem in ArcGIS Portal rather than DSC?)
It fails in the createSite
Important Factoids
The documentation says this on the 4.2.0 variables page:
ContentDirectoryLocation - The path where content of your new site will be initialized. Generally, it is the ContentDir mentioned above, followed by \arcgisportal\content, but it can be a completely independent path as well. For a Single Machine Portal this can be a Local Path (Ex. same as ContentDir), but for 2 Machine Portal this needs to be a Shared Location.
which does not mention the directory must exist, even if this is a brand new portal being brought up.
Manually creating the directory made it work. However, the documentation does not make it clear it does, and behavior with other directories not existing and being created but not this one seems inconsistent.
Community Note
Module Version
4.2.0
Affected Resource(s)
Configuration Files
In this example the shared storage is on server.email.com and the main host is svr1.email.com that portal is installed onto.
Expected Behavior
\\server.email.com\share\PROJECT\Portal
which has filepaths up to\\server.email.com\share\PROJECT
created, but notPortal
, as I figured that the installer would create the site directory.Actual Behavior
Steps to Reproduce
I have not tested making a brand new repro for this but for me it was:
Important Factoids
The documentation says this on the 4.2.0 variables page:
which does not mention the directory must exist, even if this is a brand new portal being brought up.
Manually creating the directory made it work. However, the documentation does not make it clear it does, and behavior with other directories not existing and being created but not this one seems inconsistent.
References
N/A