jberezanski / ChocolateyPackages

Chocolatey packages maintained by me
MIT License
83 stars 51 forks source link

visualstudio2017buildtools installation error #89

Closed zhan9san closed 1 year ago

zhan9san commented 4 years ago

OS: AWS EC2 Windows 2016 choco version

C:\Windows\system32>choco --version
0.10.15

Error Message:

C:\Windows\system32>choco install -y visualstudio2017buildtools
Chocolatey v0.10.15
Installing the following packages:
visualstudio2017buildtools
By installing you accept licenses for the packages.
Progress: Downloading visualstudio2017buildtools 15.9.22.0... 100%

dotnetfx v4.8.0.20190930 [Approved]
dotnetfx package files install completed. Performing other installation steps.
Attempt to get headers for https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe failed.
  The remote file either doesn't exist, is unauthorized, or is forbidden for url 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe'. Exception calling "GetResponse" with "0" argument(s): "The underlying connection was closed: An unexpected error occurred on a send."
Downloading dotnetfx 64 bit
  from 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe'
ERROR: The remote file either doesn't exist, is unauthorized, or is forbidden for url 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe'. Exception calling "GetResponse" with "0" argument(s): "The underlying connection was closed: An unexpected error occurred on a send."
The install of dotnetfx was NOT successful.
Error while running 'C:\ProgramData\chocolatey\lib\dotnetfx\tools\ChocolateyInstall.ps1'.
 See log for details.

visualstudio2017buildtools v15.9.22.0 [Approved]
visualstudio2017buildtools package files install completed. Performing other installation steps.
Attempt to get headers for https://aka.ms/vs/15/release/channel failed.
  The remote file either doesn't exist, is unauthorized, or is forbidden for url 'https://aka.ms/vs/15/release/channel'. Exception calling "GetResponse" with "0" argument(s): "The underlying connection was closed: An unexpected error occurred on a send."
Downloading channel manifest
  from 'https://aka.ms/vs/15/release/channel'
ERROR: The remote file either doesn't exist, is unauthorized, or is forbidden for url 'https://aka.ms/vs/15/release/channel'. Exception calling "GetResponse" with "0" argument(s): "The underlying connection was closed: An unexpected error occurred on a send."
The install of visualstudio2017buildtools was NOT successful.
Error while running 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyInstall.ps1'.
 See log for details.

Chocolatey installed 0/2 packages. 2 packages failed.
 See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).

Failures
 - visualstudio2017buildtools (exited 404) - Error while running 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyInstall.ps1'.
 See log for details.
 - dotnetfx (exited 404) - Error while running 'C:\ProgramData\chocolatey\lib\dotnetfx\tools\ChocolateyInstall.ps1'.
 See log for details.

Maybe it's an issue about TLS 1.3.

The download URL is reachable through chrome/curl on Windows 2016 but there is an error when I access it through IE. The error message is like below.

Turn on TLS 1.0, TLS 1.1, and TLS 1.2 in Advanced settings and try connecting to  again. If this error persists, it is possible that this site uses an unsupported protocol or cipher suite such as RC4 (link for the details), which is not considered secure. Please contact your site administrator.

I am sure that TLS 1.0, TLS 1.1, and TLS 1.2 is checked in IE Advanced settings.

And choco works well when I install other applications such as googlechrome, curl and wireshark.

Besides, choco install -y visualstudio2017buildtools worked well serval days ago and it works well on my local side(windows server 2016 in virtual box).

Could you give me some suggestions? Thanks in advance.

zhan9san commented 4 years ago

Debug log is too long. Hope it is useful.

C:\Windows\system32>choco install -dvy visualstudio2017buildtools
Chocolatey v0.10.15
Chocolatey is running on Windows v 10.0.14393.0
Attempting to delete file "C:/ProgramData/chocolatey/choco.exe.old".
Attempting to delete file "C:\ProgramData\chocolatey\choco.exe.old".
Command line: "C:\ProgramData\chocolatey\choco.exe" install -dvy visualstudio2017buildtools
Received arguments: install -dvy visualstudio2017buildtools
RemovePendingPackagesTask is now ready and waiting for PreRunMessage.
Sending message 'PreRunMessage' out if there are subscribers...
[Pending] Removing all pending packages that should not be considered installed...
Performing validation checks.
Global Configuration Validation Checks:
 - Package Exit Code / Exit On Reboot = Checked
System State Validation Checks:
 Reboot Requirement Checks:
 - Pending Computer Rename = Checked
 - Pending Component Based Servicing = Checked
 - Pending Windows Auto Update = Checked
 - Pending File Rename Operations = Ignored
 - Pending Windows Package Installer = Checked
 - Pending Windows Package Installer SysWow64 = Checked
The source 'https://chocolatey.org/api/v2/' evaluated to a 'normal' source type

NOTE: Hiding sensitive configuration data! Please double and triple
 check to be sure no sensitive data is shown, especially if copying
 output to a gist for review.
Configuration: CommandName='install'|
CacheLocation='C:\Users\jzhang4\AppData\Local\Temp\chocolatey'|
ContainsLegacyPackageInstalls='True'|
CommandExecutionTimeoutSeconds='2700'|WebRequestTimeoutSeconds='30'|
Sources='https://chocolatey.org/api/v2/'|SourceType='normal'|
Debug='True'|Verbose='True'|Trace='False'|Force='False'|Noop='False'|
HelpRequested='False'|UnsuccessfulParsing='False'|RegularOutput='True'|
QuietOutput='False'|PromptForConfirmation='False'|AcceptLicense='True'|
AllowUnofficialBuild='False'|Input='visualstudio2017buildtools'|
AllVersions='False'|SkipPackageInstallProvider='False'|
PackageNames='visualstudio2017buildtools'|Prerelease='False'|
ForceX86='False'|OverrideArguments='False'|NotSilent='False'|
ApplyPackageParametersToDependencies='False'|
ApplyInstallArgumentsToDependencies='False'|IgnoreDependencies='False'|
AllowMultipleVersions='False'|AllowDowngrade='False'|
ForceDependencies='False'|Information.PlatformType='Windows'|
Information.PlatformVersion='10.0.14393.0'|
Information.PlatformName='Windows Server 2016'|
Information.ChocolateyVersion='0.10.15.0'|
Information.ChocolateyProductVersion='0.10.15'|
Information.FullName='choco, Version=0.10.15.0, Culture=neutral, PublicKeyToken=79d02ea9cad655eb'|

Information.Is64BitOperatingSystem='True'|
Information.Is64BitProcess='True'|Information.IsInteractive='True'|
Information.UserName='jzhang4'|Information.UserDomainName='NONPROD'|
Information.IsUserAdministrator='True'|
Information.IsUserSystemAccount='False'|
Information.IsUserRemoteDesktop='False'|
Information.IsUserRemote='True'|
Information.IsProcessElevated='True'|
Information.IsLicensedVersion='False'|Information.LicenseType='Foss'|
Information.CurrentDirectory='C:\Windows\system32'|
Features.AutoUninstaller='True'|Features.ChecksumFiles='True'|
Features.AllowEmptyChecksums='False'|
Features.AllowEmptyChecksumsSecure='True'|
Features.FailOnAutoUninstaller='False'|
Features.FailOnStandardError='False'|Features.UsePowerShellHost='True'|
Features.LogEnvironmentValues='False'|Features.LogWithoutColor='False'|
Features.VirusCheck='False'|
Features.FailOnInvalidOrMissingLicense='False'|
Features.IgnoreInvalidOptionsSwitches='True'|
Features.UsePackageExitCodes='True'|
Features.UseEnhancedExitCodes='False'|
Features.UseFipsCompliantChecksums='False'|
Features.ShowNonElevatedWarnings='True'|
Features.ShowDownloadProgress='True'|
Features.StopOnFirstPackageFailure='False'|
Features.UseRememberedArgumentsForUpgrades='False'|
Features.IgnoreUnfoundPackagesOnUpgradeOutdated='False'|
Features.SkipPackageUpgradesWhenNotInstalled='False'|
Features.RemovePackageInformationOnUninstall='False'|
Features.ExitOnRebootDetected='False'|
Features.LogValidationResultsOnWarnings='True'|
Features.UsePackageRepositoryOptimizations='True'|
Features.ScriptsCheckLastExitCode='False'|
ListCommand.LocalOnly='False'|
ListCommand.IdOnly='False'|ListCommand.IncludeRegistryPrograms='False'|
ListCommand.PageSize='25'|ListCommand.Exact='False'|
ListCommand.ByIdOnly='False'|ListCommand.ByTagOnly='False'|
ListCommand.IdStartsWith='False'|ListCommand.OrderByPopularity='False'|
ListCommand.ApprovedOnly='False'|
ListCommand.DownloadCacheAvailable='False'|
ListCommand.NotBroken='False'|
ListCommand.IncludeVersionOverrides='False'|
UpgradeCommand.FailOnUnfound='False'|
UpgradeCommand.FailOnNotInstalled='False'|
UpgradeCommand.NotifyOnlyAvailableUpgrades='False'|
UpgradeCommand.ExcludePrerelease='False'|
NewCommand.AutomaticPackage='False'|
NewCommand.UseOriginalTemplate='False'|SourceCommand.Command='unknown'|
SourceCommand.Priority='0'|SourceCommand.BypassProxy='False'|
SourceCommand.AllowSelfService='False'|
SourceCommand.VisibleToAdminsOnly='False'|
FeatureCommand.Command='unknown'|ConfigCommand.Command='unknown'|
ApiKeyCommand.Remove='False'|PinCommand.Command='unknown'|
OutdatedCommand.IgnorePinned='False'|Proxy.BypassOnLocal='True'|
_ Chocolatey:ChocolateyInstallCommand - Normal Run Mode _
Installing the following packages:
visualstudio2017buildtools
By installing you accept licenses for the packages.
Using 'https://chocolatey.org/api/v2/'.
- Supports prereleases? 'True'.
- Is ServiceBased? 'True'.
Package 'visualstudio2017buildtools' found on source 'https://chocolatey.org/api/v2/'
[NuGet] Attempting to resolve dependency 'chocolatey-visualstudio.extension (≥ 1.8.1)'.
Progress: Downloading visualstudio2017buildtools 15.9.22.0... 100%
[NuGet] Attempting to resolve dependency 'KB2919355 (≥ 1.0.20160915)'.
[NuGet] Attempting to resolve dependency 'KB2919442 (≥ 1.0.20160915)'.
[NuGet] Attempting to resolve dependency 'KB2999226 (≥ 1.0.20161201)'.
[NuGet] Attempting to resolve dependency 'chocolatey-windowsupdate.extension (≥ 1.0.2)'.
[NuGet] Attempting to resolve dependency 'dotnetfx (≥ 4.6.2.0)'.
[NuGet] Attempting to resolve dependency 'chocolatey-dotnetfx.extension (≥ 1.0.1)'.
[NuGet] Attempting to resolve dependency 'visualstudio-installer (≥ 2.0.1)'.
[NuGet] Installing 'dotnetfx 4.8.0.20190930'.
[NuGet] Added file 'ChocolateyInstall.ps1' to folder 'dotnetfx\tools'.
[NuGet] Added file 'dotnetfx.nupkg' to folder 'dotnetfx'.
[NuGet] Added file 'dotnetfx.nuspec' to folder 'dotnetfx'.
[NuGet] Successfully installed 'dotnetfx 4.8.0.20190930'.

dotnetfx v4.8.0.20190930 [Approved]
dotnetfx package files install completed. Performing other installation steps.
Contents of 'C:\ProgramData\chocolatey\lib\dotnetfx\tools\ChocolateyInstall.ps1':
$version = '4.8'
$arguments = @{
    PackageName = 'dotnetfx'
    Release = 528040
    Version = $version
    ProductNameWithVersion = "Microsoft .NET Framework $version"
    Url = 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe'
    Checksum = '9B1F71CD1B86BB6EE6303F7BE6FBBE71807A51BB913844C85FC235D5978F3A0F'
    ChecksumType = 'sha256'
}

Install-DotNetFramework @arguments

Calling built-in PowerShell host with ['[System.Threading.Thread]::CurrentThread.CurrentCulture = '';[System.Threading.Thread]::CurrentThread.CurrentUICulture = ''; & import-module -name 'C:\ProgramData\chocolatey\helpers\chocolateyInstaller.psm1'; & 'C:\ProgramData\chocolatey\helpers\chocolateyScriptRunner.ps1' -packageScript 'C:\ProgramData\chocolatey\lib\dotnetfx\tools\ChocolateyInstall.ps1' -installArguments '' -packageParameters ''']
Redirecting System.Management.Automation.resources, Version=3.0.0.0, Culture=en-US, PublicKeyToken=31bf3856ad364e35, requested by ''
Host version is 5.1.14393.0, PowerShell Version is '5.1.14393.3471' and CLR Version is '4.0.30319.42000'.
VERBOSE: Exporting function 'Format-FileSize'.
VERBOSE: Exporting function 'Get-ChecksumValid'.
VERBOSE: Exporting function 'Get-ChocolateyUnzip'.
VERBOSE: Exporting function 'Get-ChocolateyWebFile'.
VERBOSE: Exporting function 'Get-EnvironmentVariable'.
VERBOSE: Exporting function 'Get-EnvironmentVariableNames'.
VERBOSE: Exporting function 'Get-FtpFile'.
VERBOSE: Exporting function 'Get-OSArchitectureWidth'.
VERBOSE: Exporting function 'Get-PackageParameters'.
VERBOSE: Exporting function 'Get-PackageParametersBuiltIn'.
VERBOSE: Exporting function 'Get-ToolsLocation'.
VERBOSE: Exporting function 'Get-UACEnabled'.
VERBOSE: Exporting function 'Get-UninstallRegistryKey'.
VERBOSE: Exporting function 'Get-VirusCheckValid'.
VERBOSE: Exporting function 'Get-WebFile'.
VERBOSE: Exporting function 'Get-WebFileName'.
VERBOSE: Exporting function 'Get-WebHeaders'.
VERBOSE: Exporting function 'Install-BinFile'.
VERBOSE: Exporting function 'Install-ChocolateyDesktopLink'.
VERBOSE: Exporting function 'Install-ChocolateyEnvironmentVariable'.
VERBOSE: Exporting function 'Install-ChocolateyExplorerMenuItem'.
VERBOSE: Exporting function 'Install-ChocolateyFileAssociation'.
VERBOSE: Exporting function 'Install-ChocolateyInstallPackage'.
VERBOSE: Exporting function 'Install-ChocolateyPackage'.
VERBOSE: Exporting function 'Install-ChocolateyPath'.
VERBOSE: Exporting function 'Install-ChocolateyPinnedTaskBarItem'.
VERBOSE: Exporting function 'Install-ChocolateyPowershellCommand'.
VERBOSE: Exporting function 'Install-ChocolateyShortcut'.
VERBOSE: Exporting function 'Install-ChocolateyVsixPackage'.
VERBOSE: Exporting function 'Install-ChocolateyZipPackage'.
VERBOSE: Exporting function 'Install-Vsix'.
VERBOSE: Exporting function 'Set-EnvironmentVariable'.
VERBOSE: Exporting function 'Set-PowerShellExitCode'.
VERBOSE: Exporting function 'Start-ChocolateyProcessAsAdmin'.
VERBOSE: Exporting function 'Test-ProcessAdminRights'.
VERBOSE: Exporting function 'Uninstall-BinFile'.
VERBOSE: Exporting function 'Uninstall-ChocolateyEnvironmentVariable'.
VERBOSE: Exporting function 'Uninstall-ChocolateyPackage'.
VERBOSE: Exporting function 'Uninstall-ChocolateyZipPackage'.
VERBOSE: Exporting function 'Update-SessionEnvironment'.
VERBOSE: Exporting function 'Write-ChocolateyFailure'.
VERBOSE: Exporting function 'Write-ChocolateySuccess'.
VERBOSE: Exporting function 'Write-FileUpdateLog'.
VERBOSE: Exporting function 'Write-FunctionCallLogMessage'.
VERBOSE: Exporting alias 'Get-ProcessorBits'.
VERBOSE: Exporting alias 'Get-OSBitness'.
VERBOSE: Exporting alias 'Get-InstallRegistryKey'.
VERBOSE: Exporting alias 'Generate-BinFile'.
VERBOSE: Exporting alias 'Add-BinFile'.
VERBOSE: Exporting alias 'Start-ChocolateyProcess'.
VERBOSE: Exporting alias 'Invoke-ChocolateyProcess'.
VERBOSE: Exporting alias 'Remove-BinFile'.
VERBOSE: Exporting alias 'refreshenv'.
Loading community extensions
Importing 'C:\ProgramData\chocolatey\extensions\chocolatey-core\chocolatey-core.psm1'
VERBOSE: Loading module from path 'C:\ProgramData\chocolatey\extensions\chocolatey-core\chocolatey-core.psm1'.
VERBOSE: Exporting function 'Get-UninstallRegistryKey'.
VERBOSE: Exporting function 'Get-AppInstallLocation'.
VERBOSE: Exporting function 'Get-AvailableDriveLetter'.
VERBOSE: Exporting function 'Get-EffectiveProxy'.
VERBOSE: Exporting function 'Get-PackageCacheLocation'.
VERBOSE: Exporting function 'Get-PackageParameters'.
VERBOSE: Exporting function 'Get-WebContent'.
VERBOSE: Exporting function 'Register-Application'.
VERBOSE: Exporting function 'Remove-Process'.
VERBOSE: Importing function 'Get-AppInstallLocation'.
VERBOSE: Importing function 'Get-AvailableDriveLetter'.
VERBOSE: Importing function 'Get-EffectiveProxy'.
VERBOSE: Importing function 'Get-PackageCacheLocation'.
VERBOSE: Importing function 'Get-PackageParameters'.
VERBOSE: Importing function 'Get-UninstallRegistryKey'.
VERBOSE: Importing function 'Get-WebContent'.
VERBOSE: Importing function 'Register-Application'.
VERBOSE: Importing function 'Remove-Process'.
Importing 'C:\ProgramData\chocolatey\extensions\chocolatey-dotnetfx\chocolatey-dotnetfx.psm1'
VERBOSE: Loading module from path 'C:\ProgramData\chocolatey\extensions\chocolatey-dotnetfx\chocolatey-dotnetfx.psm1'.
VERBOSE: Exporting function 'Install-DotNetFramework'.
VERBOSE: Exporting function 'Install-DotNetDevPack'.
VERBOSE: Importing function 'Install-DotNetDevPack'.
VERBOSE: Importing function 'Install-DotNetFramework'.
Importing 'C:\ProgramData\chocolatey\extensions\chocolatey-visualstudio\chocolatey-visualstudio.extension.psm1'
VERBOSE: Loading module from path 'C:\ProgramData\chocolatey\extensions\chocolatey-visualstudio\chocolatey-visualstudio.extension.psm1'.
VERBOSE: Exporting function 'Add-VisualStudioComponent'.
VERBOSE: Exporting function 'Add-VisualStudioWorkload'.
VERBOSE: Exporting function 'Get-VisualStudioInstaller'.
VERBOSE: Exporting function 'Get-VisualStudioInstallerHealth'.
VERBOSE: Exporting function 'Get-VisualStudioInstance'.
VERBOSE: Exporting function 'Get-VisualStudioVsixInstaller'.
VERBOSE: Exporting function 'Install-VisualStudio'.
VERBOSE: Exporting function 'Install-VisualStudioInstaller'.
VERBOSE: Exporting function 'Install-VisualStudioVsixExtension'.
VERBOSE: Exporting function 'Remove-VisualStudioComponent'.
VERBOSE: Exporting function 'Remove-VisualStudioProduct'.
VERBOSE: Exporting function 'Remove-VisualStudioWorkload'.
VERBOSE: Exporting function 'Uninstall-VisualStudio'.
VERBOSE: Exporting function 'Uninstall-VisualStudioVsixExtension'.
VERBOSE: Importing function 'Add-VisualStudioComponent'.
VERBOSE: Importing function 'Add-VisualStudioWorkload'.
VERBOSE: Importing function 'Get-VisualStudioInstaller'.
VERBOSE: Importing function 'Get-VisualStudioInstallerHealth'.
VERBOSE: Importing function 'Get-VisualStudioInstance'.
VERBOSE: Importing function 'Get-VisualStudioVsixInstaller'.
VERBOSE: Importing function 'Install-VisualStudio'.
VERBOSE: Importing function 'Install-VisualStudioInstaller'.
VERBOSE: Importing function 'Install-VisualStudioVsixExtension'.
VERBOSE: Importing function 'Remove-VisualStudioComponent'.
VERBOSE: Importing function 'Remove-VisualStudioProduct'.
VERBOSE: Importing function 'Remove-VisualStudioWorkload'.
VERBOSE: Importing function 'Uninstall-VisualStudio'.
VERBOSE: Importing function 'Uninstall-VisualStudioVsixExtension'.
Importing 'C:\ProgramData\chocolatey\extensions\chocolatey-windowsupdate\chocolatey-windowsupdate.psm1'
VERBOSE: Loading module from path 'C:\ProgramData\chocolatey\extensions\chocolatey-windowsupdate\chocolatey-windowsupdate.psm1'.
VERBOSE: Exporting function 'Install-WindowsUpdate'.
VERBOSE: Exporting function 'Test-WindowsUpdate'.
VERBOSE: Importing function 'Install-WindowsUpdate'.
VERBOSE: Importing function 'Test-WindowsUpdate'.
VERBOSE: Exporting function 'Format-FileSize'.
VERBOSE: Exporting function 'Get-ChecksumValid'.
VERBOSE: Exporting function 'Get-ChocolateyUnzip'.
VERBOSE: Exporting function 'Get-ChocolateyWebFile'.
VERBOSE: Exporting function 'Get-EnvironmentVariable'.
VERBOSE: Exporting function 'Get-EnvironmentVariableNames'.
VERBOSE: Exporting function 'Get-FtpFile'.
VERBOSE: Exporting function 'Get-OSArchitectureWidth'.
VERBOSE: Exporting function 'Get-PackageParameters'.
VERBOSE: Exporting function 'Get-PackageParametersBuiltIn'.
VERBOSE: Exporting function 'Get-ToolsLocation'.
VERBOSE: Exporting function 'Get-UACEnabled'.
VERBOSE: Exporting function 'Get-UninstallRegistryKey'.
VERBOSE: Exporting function 'Get-VirusCheckValid'.
VERBOSE: Exporting function 'Get-WebFile'.
VERBOSE: Exporting function 'Get-WebFileName'.
VERBOSE: Exporting function 'Get-WebHeaders'.
VERBOSE: Exporting function 'Install-BinFile'.
VERBOSE: Exporting function 'Install-ChocolateyDesktopLink'.
VERBOSE: Exporting function 'Install-ChocolateyEnvironmentVariable'.
VERBOSE: Exporting function 'Install-ChocolateyExplorerMenuItem'.
VERBOSE: Exporting function 'Install-ChocolateyFileAssociation'.
VERBOSE: Exporting function 'Install-ChocolateyInstallPackage'.
VERBOSE: Exporting function 'Install-ChocolateyPackage'.
VERBOSE: Exporting function 'Install-ChocolateyPath'.
VERBOSE: Exporting function 'Install-ChocolateyPinnedTaskBarItem'.
VERBOSE: Exporting function 'Install-ChocolateyPowershellCommand'.
VERBOSE: Exporting function 'Install-ChocolateyShortcut'.
VERBOSE: Exporting function 'Install-ChocolateyVsixPackage'.
VERBOSE: Exporting function 'Install-ChocolateyZipPackage'.
VERBOSE: Exporting function 'Install-Vsix'.
VERBOSE: Exporting function 'Set-EnvironmentVariable'.
VERBOSE: Exporting function 'Set-PowerShellExitCode'.
VERBOSE: Exporting function 'Start-ChocolateyProcessAsAdmin'.
VERBOSE: Exporting function 'Test-ProcessAdminRights'.
VERBOSE: Exporting function 'Uninstall-BinFile'.
VERBOSE: Exporting function 'Uninstall-ChocolateyEnvironmentVariable'.
VERBOSE: Exporting function 'Uninstall-ChocolateyPackage'.
VERBOSE: Exporting function 'Uninstall-ChocolateyZipPackage'.
VERBOSE: Exporting function 'Update-SessionEnvironment'.
VERBOSE: Exporting function 'Write-ChocolateyFailure'.
VERBOSE: Exporting function 'Write-ChocolateySuccess'.
VERBOSE: Exporting function 'Write-FileUpdateLog'.
VERBOSE: Exporting function 'Write-FunctionCallLogMessage'.
VERBOSE: Exporting function 'Get-AppInstallLocation'.
VERBOSE: Exporting function 'Get-AvailableDriveLetter'.
VERBOSE: Exporting function 'Get-EffectiveProxy'.
VERBOSE: Exporting function 'Get-PackageCacheLocation'.
VERBOSE: Exporting function 'Get-WebContent'.
VERBOSE: Exporting function 'Register-Application'.
VERBOSE: Exporting function 'Remove-Process'.
VERBOSE: Exporting function 'Install-DotNetDevPack'.
VERBOSE: Exporting function 'Install-DotNetFramework'.
VERBOSE: Exporting function 'Add-VisualStudioComponent'.
VERBOSE: Exporting function 'Add-VisualStudioWorkload'.
VERBOSE: Exporting function 'Get-VisualStudioInstaller'.
VERBOSE: Exporting function 'Get-VisualStudioInstallerHealth'.
VERBOSE: Exporting function 'Get-VisualStudioInstance'.
VERBOSE: Exporting function 'Get-VisualStudioVsixInstaller'.
VERBOSE: Exporting function 'Install-VisualStudio'.
VERBOSE: Exporting function 'Install-VisualStudioInstaller'.
VERBOSE: Exporting function 'Install-VisualStudioVsixExtension'.
VERBOSE: Exporting function 'Remove-VisualStudioComponent'.
VERBOSE: Exporting function 'Remove-VisualStudioProduct'.
VERBOSE: Exporting function 'Remove-VisualStudioWorkload'.
VERBOSE: Exporting function 'Uninstall-VisualStudio'.
VERBOSE: Exporting function 'Uninstall-VisualStudioVsixExtension'.
VERBOSE: Exporting function 'Install-WindowsUpdate'.
VERBOSE: Exporting function 'Test-WindowsUpdate'.
VERBOSE: Exporting alias 'Get-ProcessorBits'.
VERBOSE: Exporting alias 'Get-OSBitness'.
VERBOSE: Exporting alias 'Get-InstallRegistryKey'.
VERBOSE: Exporting alias 'Generate-BinFile'.
VERBOSE: Exporting alias 'Add-BinFile'.
VERBOSE: Exporting alias 'Start-ChocolateyProcess'.
VERBOSE: Exporting alias 'Invoke-ChocolateyProcess'.
VERBOSE: Exporting alias 'Remove-BinFile'.
VERBOSE: Exporting alias 'refreshenv'.
VERBOSE: Importing function 'Add-VisualStudioComponent'.
VERBOSE: Importing function 'Add-VisualStudioWorkload'.
VERBOSE: Importing function 'Format-FileSize'.
VERBOSE: Importing function 'Get-AppInstallLocation'.
VERBOSE: Importing function 'Get-AvailableDriveLetter'.
VERBOSE: Importing function 'Get-ChecksumValid'.
VERBOSE: Importing function 'Get-ChocolateyUnzip'.
VERBOSE: Importing function 'Get-ChocolateyWebFile'.
VERBOSE: Importing function 'Get-EffectiveProxy'.
VERBOSE: Importing function 'Get-EnvironmentVariable'.
VERBOSE: Importing function 'Get-EnvironmentVariableNames'.
VERBOSE: Importing function 'Get-FtpFile'.
VERBOSE: Importing function 'Get-OSArchitectureWidth'.
VERBOSE: Importing function 'Get-PackageCacheLocation'.
VERBOSE: Importing function 'Get-PackageParameters'.
VERBOSE: Importing function 'Get-PackageParametersBuiltIn'.
VERBOSE: Importing function 'Get-ToolsLocation'.
VERBOSE: Importing function 'Get-UACEnabled'.
VERBOSE: Importing function 'Get-UninstallRegistryKey'.
VERBOSE: Importing function 'Get-VirusCheckValid'.
VERBOSE: Importing function 'Get-VisualStudioInstaller'.
VERBOSE: Importing function 'Get-VisualStudioInstallerHealth'.
VERBOSE: Importing function 'Get-VisualStudioInstance'.
VERBOSE: Importing function 'Get-VisualStudioVsixInstaller'.
VERBOSE: Importing function 'Get-WebContent'.
VERBOSE: Importing function 'Get-WebFile'.
VERBOSE: Importing function 'Get-WebFileName'.
VERBOSE: Importing function 'Get-WebHeaders'.
VERBOSE: Importing function 'Install-BinFile'.
VERBOSE: Importing function 'Install-ChocolateyDesktopLink'.
VERBOSE: Importing function 'Install-ChocolateyEnvironmentVariable'.
VERBOSE: Importing function 'Install-ChocolateyExplorerMenuItem'.
VERBOSE: Importing function 'Install-ChocolateyFileAssociation'.
VERBOSE: Importing function 'Install-ChocolateyInstallPackage'.
VERBOSE: Importing function 'Install-ChocolateyPackage'.
VERBOSE: Importing function 'Install-ChocolateyPath'.
VERBOSE: Importing function 'Install-ChocolateyPinnedTaskBarItem'.
VERBOSE: Importing function 'Install-ChocolateyPowershellCommand'.
VERBOSE: Importing function 'Install-ChocolateyShortcut'.
VERBOSE: Importing function 'Install-ChocolateyVsixPackage'.
VERBOSE: Importing function 'Install-ChocolateyZipPackage'.
VERBOSE: Importing function 'Install-DotNetDevPack'.
VERBOSE: Importing function 'Install-DotNetFramework'.
VERBOSE: Importing function 'Install-VisualStudio'.
VERBOSE: Importing function 'Install-VisualStudioInstaller'.
VERBOSE: Importing function 'Install-VisualStudioVsixExtension'.
VERBOSE: Importing function 'Install-Vsix'.
VERBOSE: Importing function 'Install-WindowsUpdate'.
VERBOSE: Importing function 'Register-Application'.
VERBOSE: Importing function 'Remove-Process'.
VERBOSE: Importing function 'Remove-VisualStudioComponent'.
VERBOSE: Importing function 'Remove-VisualStudioProduct'.
VERBOSE: Importing function 'Remove-VisualStudioWorkload'.
VERBOSE: Importing function 'Set-EnvironmentVariable'.
VERBOSE: Importing function 'Set-PowerShellExitCode'.
VERBOSE: Importing function 'Start-ChocolateyProcessAsAdmin'.
VERBOSE: Importing function 'Test-ProcessAdminRights'.
VERBOSE: Importing function 'Test-WindowsUpdate'.
VERBOSE: Importing function 'Uninstall-BinFile'.
VERBOSE: Importing function 'Uninstall-ChocolateyEnvironmentVariable'.
VERBOSE: Importing function 'Uninstall-ChocolateyPackage'.
VERBOSE: Importing function 'Uninstall-ChocolateyZipPackage'.
VERBOSE: Importing function 'Uninstall-VisualStudio'.
VERBOSE: Importing function 'Uninstall-VisualStudioVsixExtension'.
VERBOSE: Importing function 'Update-SessionEnvironment'.
VERBOSE: Importing function 'Write-ChocolateyFailure'.
VERBOSE: Importing function 'Write-ChocolateySuccess'.
VERBOSE: Importing function 'Write-FileUpdateLog'.
VERBOSE: Importing function 'Write-FunctionCallLogMessage'.
VERBOSE: Importing alias 'Add-BinFile'.
VERBOSE: Importing alias 'Generate-BinFile'.
VERBOSE: Importing alias 'Get-InstallRegistryKey'.
VERBOSE: Importing alias 'Get-OSBitness'.
VERBOSE: Importing alias 'Get-ProcessorBits'.
VERBOSE: Importing alias 'Invoke-ChocolateyProcess'.
VERBOSE: Importing alias 'refreshenv'.
VERBOSE: Importing alias 'Remove-BinFile'.
VERBOSE: Importing alias 'Start-ChocolateyProcess'.
---------------------------Script Execution---------------------------
Running 'ChocolateyScriptRunner' for dotnetfx v4.8.0.20190930 with packageScript 'C:\ProgramData\chocolatey\lib\dotnetfx\tools\ChocolateyInstall.ps1', packageFolder:'C:\ProgramData\chocolatey\lib\dotnetfx', installArguments: '', packageParameters: '',
Running 'C:\ProgramData\chocolatey\lib\dotnetfx\tools\ChocolateyInstall.ps1'
Local file path: C:\Users\jzhang4\AppData\Local\Temp\chocolatey\dotnetfx\4.8.0.20190930\ndp48-x86-x64-allos-enu.exe
Running Get-ChocolateyWebFile -fileFullPath 'C:\Users\jzhang4\AppData\Local\Temp\chocolatey\dotnetfx\4.8.0.20190930\ndp48-x86-x64-allos-enu.exe' -checksumType 'sha256' -url 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe' -checksum '9B1F71CD1B86BB6EE6303F7BE6FBBE71807A51BB913844C85FC235D5978F3A0F' -checksumType64 'sha256' -packageName 'dotnetfx' -checksum64 '9B1F71CD1B86BB6EE6303F7BE6FBBE71807A51BB913844C85FC235D5978F3A0F' -url64bit 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe'
Running Get-ProcessorBits -compare '64'
CPU is 64 bit
Setting url to 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe' and bitPackage to 64
Running Get-WebHeaders -url 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe' -ErrorAction 'Stop'
Setting the UserAgent to 'chocolatey command line'
Request Headers:
  'Accept':'*/*'
  'User-Agent':'chocolatey command line'
Attempt to get headers for https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe failed.
  The remote file either doesn't exist, is unauthorized, or is forbidden for url 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe'. Exception calling "GetResponse" with "0" argument(s): "The underlying connection was closed: An unexpected error occurred on a send."
Downloading dotnetfx 64 bit
  from 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe'
Running Get-WebFile -url 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe' -fileName 'C:\Users\jzhang4\AppData\Local\Temp\chocolatey\dotnetfx\4.8.0.20190930\ndp48-x86-x64-allos-enu.exe' -options 'System.Collections.Hashtable'
Setting request timeout to  30000
Setting read/write timeout to  2700000
Setting the UserAgent to 'chocolatey command line'
ERROR: The remote file either doesn't exist, is unauthorized, or is forbidden for url 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe'. Exception calling "GetResponse" with "0" argument(s): "The underlying connection was closed: An unexpected error occurred on a send."
 at Get-WebFile, C:\ProgramData\chocolatey\helpers\functions\Get-WebFile.ps1: line 331
at Get-ChocolateyWebFile, C:\ProgramData\chocolatey\helpers\functions\Get-ChocolateyWebFile.ps1: line 345
at Install-DotNetFrameworkOrDevPack, C:\ProgramData\chocolatey\extensions\chocolatey-dotnetfx\DotNetFrameworkHelpers.ps1: line 100
at Install-DotNetFramework, C:\ProgramData\chocolatey\extensions\chocolatey-dotnetfx\DotNetFrameworkHelpers.ps1: line 156
at <ScriptBlock>, C:\ProgramData\chocolatey\lib\dotnetfx\tools\ChocolateyInstall.ps1: line 12
at <ScriptBlock>, C:\ProgramData\chocolatey\helpers\chocolateyScriptRunner.ps1: line 49
at <ScriptBlock>, <No file>: line 1
Built-in PowerShell host called with ['[System.Threading.Thread]::CurrentThread.CurrentCulture = '';[System.Threading.Thread]::CurrentThread.CurrentUICulture = ''; & import-module -name 'C:\ProgramData\chocolatey\helpers\chocolateyInstaller.psm1'; & 'C:\ProgramData\chocolatey\helpers\chocolateyScriptRunner.ps1' -packageScript 'C:\ProgramData\chocolatey\lib\dotnetfx\tools\ChocolateyInstall.ps1' -installArguments '' -packageParameters '''] exited with '404'.
Calling command ['"C:\Windows\System32\shutdown.exe" /a']
Command ['"C:\Windows\System32\shutdown.exe" /a'] exited with '1116'
Capturing package files in 'C:\ProgramData\chocolatey\lib\dotnetfx'
 Found 'C:\ProgramData\chocolatey\lib\dotnetfx\dotnetfx.nupkg'
  with checksum '2847A6A19411DA4CF1CF5959AACCA5E6'
 Found 'C:\ProgramData\chocolatey\lib\dotnetfx\dotnetfx.nuspec'
  with checksum 'E3B6DE1E6261B544728B08C080E9BD5B'
 Found 'C:\ProgramData\chocolatey\lib\dotnetfx\tools\ChocolateyInstall.ps1'
  with checksum 'F210703F69E4BE33D4F61821374F28B5'
Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\dotnetfx.4.8.0.20190930\.arguments".
Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\dotnetfx.4.8.0.20190930\.extra".
Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\dotnetfx.4.8.0.20190930\.version".
Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\dotnetfx.4.8.0.20190930\.sxs".
Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\dotnetfx.4.8.0.20190930\.pin".
Attempting to delete directory "C:\ProgramData\chocolatey\lib-bad\dotnetfx".
Sending message 'HandlePackageResultCompletedMessage' out if there are subscribers...
The install of dotnetfx was NOT successful.
Error while running 'C:\ProgramData\chocolatey\lib\dotnetfx\tools\ChocolateyInstall.ps1'.
 See log for details.
Moving 'C:\ProgramData\chocolatey\lib\dotnetfx'
 to 'C:\ProgramData\chocolatey\lib-bad\dotnetfx'
[NuGet] Installing 'visualstudio2017buildtools 15.9.22.0'.
[NuGet] Added file '.skipAutoUninstall' to folder 'visualstudio2017buildtools\tools'.
[NuGet] Added file 'ChocolateyInstall.ps1' to folder 'visualstudio2017buildtools\tools'.
[NuGet] Added file 'ChocolateyUninstall.ps1' to folder 'visualstudio2017buildtools\tools'.
[NuGet] Added file 'visualstudio2017buildtools.nupkg' to folder 'visualstudio2017buildtools'.
[NuGet] Added file 'visualstudio2017buildtools.nuspec' to folder 'visualstudio2017buildtools'.
[NuGet] Successfully installed 'visualstudio2017buildtools 15.9.22.0'.

visualstudio2017buildtools v15.9.22.0 [Approved]
visualstudio2017buildtools package files install completed. Performing other installation steps.
Setting installer args for visualstudio2017buildtools
Setting package parameters for visualstudio2017buildtools
Contents of 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyInstall.ps1':
Install-VisualStudio `
    -PackageName 'visualstudio2017buildtools' `
    -ApplicationName 'Microsoft Visual Studio Build Tools 2017' `
    -Url 'https://download.visualstudio.microsoft.com/download/pr/dfb60031-5f2b-4236-a36b-25a0197459bc/2f9a69561f6678f745b55ea38a606180b3941637d7e8cbbb65acae6933152d3e/vs_BuildTools.exe' `
    -Checksum '2F9A69561F6678F745B55EA38A606180B3941637D7E8CBBB65ACAE6933152D3E' `
    -ChecksumType 'SHA256' `
    -InstallerTechnology 'WillowVS2017OrLater' `
    -Product 'BuildTools' `
    -VisualStudioYear '2017' `
    -Preview $false

Calling built-in PowerShell host with ['[System.Threading.Thread]::CurrentThread.CurrentCulture = '';[System.Threading.Thread]::CurrentThread.CurrentUICulture = ''; & import-module -name 'C:\ProgramData\chocolatey\helpers\chocolateyInstaller.psm1'; & 'C:\ProgramData\chocolatey\helpers\chocolateyScriptRunner.ps1' -packageScript 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyInstall.ps1' -installArguments '' -packageParameters ''']
Redirecting Microsoft.WSMan.Management.resources, Version=3.0.0.0, Culture=en-US, PublicKeyToken=31bf3856ad364e35, requested by ''
Host version is 5.1.14393.0, PowerShell Version is '5.1.14393.3471' and CLR Version is '4.0.30319.42000'.
VERBOSE: Exporting function 'Format-FileSize'.
VERBOSE: Exporting function 'Get-ChecksumValid'.
VERBOSE: Exporting function 'Get-ChocolateyUnzip'.
VERBOSE: Exporting function 'Get-ChocolateyWebFile'.
VERBOSE: Exporting function 'Get-EnvironmentVariable'.
VERBOSE: Exporting function 'Get-EnvironmentVariableNames'.
VERBOSE: Exporting function 'Get-FtpFile'.
VERBOSE: Exporting function 'Get-OSArchitectureWidth'.
VERBOSE: Exporting function 'Get-PackageParameters'.
VERBOSE: Exporting function 'Get-PackageParametersBuiltIn'.
VERBOSE: Exporting function 'Get-ToolsLocation'.
VERBOSE: Exporting function 'Get-UACEnabled'.
VERBOSE: Exporting function 'Get-UninstallRegistryKey'.
VERBOSE: Exporting function 'Get-VirusCheckValid'.
VERBOSE: Exporting function 'Get-WebFile'.
VERBOSE: Exporting function 'Get-WebFileName'.
VERBOSE: Exporting function 'Get-WebHeaders'.
VERBOSE: Exporting function 'Install-BinFile'.
VERBOSE: Exporting function 'Install-ChocolateyDesktopLink'.
VERBOSE: Exporting function 'Install-ChocolateyEnvironmentVariable'.
VERBOSE: Exporting function 'Install-ChocolateyExplorerMenuItem'.
VERBOSE: Exporting function 'Install-ChocolateyFileAssociation'.
VERBOSE: Exporting function 'Install-ChocolateyInstallPackage'.
VERBOSE: Exporting function 'Install-ChocolateyPackage'.
VERBOSE: Exporting function 'Install-ChocolateyPath'.
VERBOSE: Exporting function 'Install-ChocolateyPinnedTaskBarItem'.
VERBOSE: Exporting function 'Install-ChocolateyPowershellCommand'.
VERBOSE: Exporting function 'Install-ChocolateyShortcut'.
VERBOSE: Exporting function 'Install-ChocolateyVsixPackage'.
VERBOSE: Exporting function 'Install-ChocolateyZipPackage'.
VERBOSE: Exporting function 'Install-Vsix'.
VERBOSE: Exporting function 'Set-EnvironmentVariable'.
VERBOSE: Exporting function 'Set-PowerShellExitCode'.
VERBOSE: Exporting function 'Start-ChocolateyProcessAsAdmin'.
VERBOSE: Exporting function 'Test-ProcessAdminRights'.
VERBOSE: Exporting function 'Uninstall-BinFile'.
VERBOSE: Exporting function 'Uninstall-ChocolateyEnvironmentVariable'.
VERBOSE: Exporting function 'Uninstall-ChocolateyPackage'.
VERBOSE: Exporting function 'Uninstall-ChocolateyZipPackage'.
VERBOSE: Exporting function 'Update-SessionEnvironment'.
VERBOSE: Exporting function 'Write-ChocolateyFailure'.
VERBOSE: Exporting function 'Write-ChocolateySuccess'.
VERBOSE: Exporting function 'Write-FileUpdateLog'.
VERBOSE: Exporting function 'Write-FunctionCallLogMessage'.
VERBOSE: Exporting alias 'Get-ProcessorBits'.
VERBOSE: Exporting alias 'Get-OSBitness'.
VERBOSE: Exporting alias 'Get-InstallRegistryKey'.
VERBOSE: Exporting alias 'Generate-BinFile'.
VERBOSE: Exporting alias 'Add-BinFile'.
VERBOSE: Exporting alias 'Start-ChocolateyProcess'.
VERBOSE: Exporting alias 'Invoke-ChocolateyProcess'.
VERBOSE: Exporting alias 'Remove-BinFile'.
VERBOSE: Exporting alias 'refreshenv'.
Loading community extensions
Importing 'C:\ProgramData\chocolatey\extensions\chocolatey-core\chocolatey-core.psm1'
VERBOSE: Loading module from path 'C:\ProgramData\chocolatey\extensions\chocolatey-core\chocolatey-core.psm1'.
VERBOSE: Exporting function 'Get-UninstallRegistryKey'.
VERBOSE: Exporting function 'Get-AppInstallLocation'.
VERBOSE: Exporting function 'Get-AvailableDriveLetter'.
VERBOSE: Exporting function 'Get-EffectiveProxy'.
VERBOSE: Exporting function 'Get-PackageCacheLocation'.
VERBOSE: Exporting function 'Get-PackageParameters'.
VERBOSE: Exporting function 'Get-WebContent'.
VERBOSE: Exporting function 'Register-Application'.
VERBOSE: Exporting function 'Remove-Process'.
VERBOSE: Importing function 'Get-AppInstallLocation'.
VERBOSE: Importing function 'Get-AvailableDriveLetter'.
VERBOSE: Importing function 'Get-EffectiveProxy'.
VERBOSE: Importing function 'Get-PackageCacheLocation'.
VERBOSE: Importing function 'Get-PackageParameters'.
VERBOSE: Importing function 'Get-UninstallRegistryKey'.
VERBOSE: Importing function 'Get-WebContent'.
VERBOSE: Importing function 'Register-Application'.
VERBOSE: Importing function 'Remove-Process'.
Importing 'C:\ProgramData\chocolatey\extensions\chocolatey-dotnetfx\chocolatey-dotnetfx.psm1'
VERBOSE: Loading module from path 'C:\ProgramData\chocolatey\extensions\chocolatey-dotnetfx\chocolatey-dotnetfx.psm1'.
VERBOSE: Exporting function 'Install-DotNetFramework'.
VERBOSE: Exporting function 'Install-DotNetDevPack'.
VERBOSE: Importing function 'Install-DotNetDevPack'.
VERBOSE: Importing function 'Install-DotNetFramework'.
Importing 'C:\ProgramData\chocolatey\extensions\chocolatey-visualstudio\chocolatey-visualstudio.extension.psm1'
VERBOSE: Loading module from path 'C:\ProgramData\chocolatey\extensions\chocolatey-visualstudio\chocolatey-visualstudio.extension.psm1'.
VERBOSE: Exporting function 'Add-VisualStudioComponent'.
VERBOSE: Exporting function 'Add-VisualStudioWorkload'.
VERBOSE: Exporting function 'Get-VisualStudioInstaller'.
VERBOSE: Exporting function 'Get-VisualStudioInstallerHealth'.
VERBOSE: Exporting function 'Get-VisualStudioInstance'.
VERBOSE: Exporting function 'Get-VisualStudioVsixInstaller'.
VERBOSE: Exporting function 'Install-VisualStudio'.
VERBOSE: Exporting function 'Install-VisualStudioInstaller'.
VERBOSE: Exporting function 'Install-VisualStudioVsixExtension'.
VERBOSE: Exporting function 'Remove-VisualStudioComponent'.
VERBOSE: Exporting function 'Remove-VisualStudioProduct'.
VERBOSE: Exporting function 'Remove-VisualStudioWorkload'.
VERBOSE: Exporting function 'Uninstall-VisualStudio'.
VERBOSE: Exporting function 'Uninstall-VisualStudioVsixExtension'.
VERBOSE: Importing function 'Add-VisualStudioComponent'.
VERBOSE: Importing function 'Add-VisualStudioWorkload'.
VERBOSE: Importing function 'Get-VisualStudioInstaller'.
VERBOSE: Importing function 'Get-VisualStudioInstallerHealth'.
VERBOSE: Importing function 'Get-VisualStudioInstance'.
VERBOSE: Importing function 'Get-VisualStudioVsixInstaller'.
VERBOSE: Importing function 'Install-VisualStudio'.
VERBOSE: Importing function 'Install-VisualStudioInstaller'.
VERBOSE: Importing function 'Install-VisualStudioVsixExtension'.
VERBOSE: Importing function 'Remove-VisualStudioComponent'.
VERBOSE: Importing function 'Remove-VisualStudioProduct'.
VERBOSE: Importing function 'Remove-VisualStudioWorkload'.
VERBOSE: Importing function 'Uninstall-VisualStudio'.
VERBOSE: Importing function 'Uninstall-VisualStudioVsixExtension'.
Importing 'C:\ProgramData\chocolatey\extensions\chocolatey-windowsupdate\chocolatey-windowsupdate.psm1'
VERBOSE: Loading module from path 'C:\ProgramData\chocolatey\extensions\chocolatey-windowsupdate\chocolatey-windowsupdate.psm1'.
VERBOSE: Exporting function 'Install-WindowsUpdate'.
VERBOSE: Exporting function 'Test-WindowsUpdate'.
VERBOSE: Importing function 'Install-WindowsUpdate'.
VERBOSE: Importing function 'Test-WindowsUpdate'.
VERBOSE: Exporting function 'Format-FileSize'.
VERBOSE: Exporting function 'Get-ChecksumValid'.
VERBOSE: Exporting function 'Get-ChocolateyUnzip'.
VERBOSE: Exporting function 'Get-ChocolateyWebFile'.
VERBOSE: Exporting function 'Get-EnvironmentVariable'.
VERBOSE: Exporting function 'Get-EnvironmentVariableNames'.
VERBOSE: Exporting function 'Get-FtpFile'.
VERBOSE: Exporting function 'Get-OSArchitectureWidth'.
VERBOSE: Exporting function 'Get-PackageParameters'.
VERBOSE: Exporting function 'Get-PackageParametersBuiltIn'.
VERBOSE: Exporting function 'Get-ToolsLocation'.
VERBOSE: Exporting function 'Get-UACEnabled'.
VERBOSE: Exporting function 'Get-UninstallRegistryKey'.
VERBOSE: Exporting function 'Get-VirusCheckValid'.
VERBOSE: Exporting function 'Get-WebFile'.
VERBOSE: Exporting function 'Get-WebFileName'.
VERBOSE: Exporting function 'Get-WebHeaders'.
VERBOSE: Exporting function 'Install-BinFile'.
VERBOSE: Exporting function 'Install-ChocolateyDesktopLink'.
VERBOSE: Exporting function 'Install-ChocolateyEnvironmentVariable'.
VERBOSE: Exporting function 'Install-ChocolateyExplorerMenuItem'.
VERBOSE: Exporting function 'Install-ChocolateyFileAssociation'.
VERBOSE: Exporting function 'Install-ChocolateyInstallPackage'.
VERBOSE: Exporting function 'Install-ChocolateyPackage'.
VERBOSE: Exporting function 'Install-ChocolateyPath'.
VERBOSE: Exporting function 'Install-ChocolateyPinnedTaskBarItem'.
VERBOSE: Exporting function 'Install-ChocolateyPowershellCommand'.
VERBOSE: Exporting function 'Install-ChocolateyShortcut'.
VERBOSE: Exporting function 'Install-ChocolateyVsixPackage'.
VERBOSE: Exporting function 'Install-ChocolateyZipPackage'.
VERBOSE: Exporting function 'Install-Vsix'.
VERBOSE: Exporting function 'Set-EnvironmentVariable'.
VERBOSE: Exporting function 'Set-PowerShellExitCode'.
VERBOSE: Exporting function 'Start-ChocolateyProcessAsAdmin'.
VERBOSE: Exporting function 'Test-ProcessAdminRights'.
VERBOSE: Exporting function 'Uninstall-BinFile'.
VERBOSE: Exporting function 'Uninstall-ChocolateyEnvironmentVariable'.
VERBOSE: Exporting function 'Uninstall-ChocolateyPackage'.
VERBOSE: Exporting function 'Uninstall-ChocolateyZipPackage'.
VERBOSE: Exporting function 'Update-SessionEnvironment'.
VERBOSE: Exporting function 'Write-ChocolateyFailure'.
VERBOSE: Exporting function 'Write-ChocolateySuccess'.
VERBOSE: Exporting function 'Write-FileUpdateLog'.
VERBOSE: Exporting function 'Write-FunctionCallLogMessage'.
VERBOSE: Exporting function 'Get-AppInstallLocation'.
VERBOSE: Exporting function 'Get-AvailableDriveLetter'.
VERBOSE: Exporting function 'Get-EffectiveProxy'.
VERBOSE: Exporting function 'Get-PackageCacheLocation'.
VERBOSE: Exporting function 'Get-WebContent'.
VERBOSE: Exporting function 'Register-Application'.
VERBOSE: Exporting function 'Remove-Process'.
VERBOSE: Exporting function 'Install-DotNetDevPack'.
VERBOSE: Exporting function 'Install-DotNetFramework'.
VERBOSE: Exporting function 'Add-VisualStudioComponent'.
VERBOSE: Exporting function 'Add-VisualStudioWorkload'.
VERBOSE: Exporting function 'Get-VisualStudioInstaller'.
VERBOSE: Exporting function 'Get-VisualStudioInstallerHealth'.
VERBOSE: Exporting function 'Get-VisualStudioInstance'.
VERBOSE: Exporting function 'Get-VisualStudioVsixInstaller'.
VERBOSE: Exporting function 'Install-VisualStudio'.
VERBOSE: Exporting function 'Install-VisualStudioInstaller'.
VERBOSE: Exporting function 'Install-VisualStudioVsixExtension'.
VERBOSE: Exporting function 'Remove-VisualStudioComponent'.
VERBOSE: Exporting function 'Remove-VisualStudioProduct'.
VERBOSE: Exporting function 'Remove-VisualStudioWorkload'.
VERBOSE: Exporting function 'Uninstall-VisualStudio'.
VERBOSE: Exporting function 'Uninstall-VisualStudioVsixExtension'.
VERBOSE: Exporting function 'Install-WindowsUpdate'.
VERBOSE: Exporting function 'Test-WindowsUpdate'.
VERBOSE: Exporting alias 'Get-ProcessorBits'.
VERBOSE: Exporting alias 'Get-OSBitness'.
VERBOSE: Exporting alias 'Get-InstallRegistryKey'.
VERBOSE: Exporting alias 'Generate-BinFile'.
VERBOSE: Exporting alias 'Add-BinFile'.
VERBOSE: Exporting alias 'Start-ChocolateyProcess'.
VERBOSE: Exporting alias 'Invoke-ChocolateyProcess'.
VERBOSE: Exporting alias 'Remove-BinFile'.
VERBOSE: Exporting alias 'refreshenv'.
VERBOSE: Importing function 'Add-VisualStudioComponent'.
VERBOSE: Importing function 'Add-VisualStudioWorkload'.
VERBOSE: Importing function 'Format-FileSize'.
VERBOSE: Importing function 'Get-AppInstallLocation'.
VERBOSE: Importing function 'Get-AvailableDriveLetter'.
VERBOSE: Importing function 'Get-ChecksumValid'.
VERBOSE: Importing function 'Get-ChocolateyUnzip'.
VERBOSE: Importing function 'Get-ChocolateyWebFile'.
VERBOSE: Importing function 'Get-EffectiveProxy'.
VERBOSE: Importing function 'Get-EnvironmentVariable'.
VERBOSE: Importing function 'Get-EnvironmentVariableNames'.
VERBOSE: Importing function 'Get-FtpFile'.
VERBOSE: Importing function 'Get-OSArchitectureWidth'.
VERBOSE: Importing function 'Get-PackageCacheLocation'.
VERBOSE: Importing function 'Get-PackageParameters'.
VERBOSE: Importing function 'Get-PackageParametersBuiltIn'.
VERBOSE: Importing function 'Get-ToolsLocation'.
VERBOSE: Importing function 'Get-UACEnabled'.
VERBOSE: Importing function 'Get-UninstallRegistryKey'.
VERBOSE: Importing function 'Get-VirusCheckValid'.
VERBOSE: Importing function 'Get-VisualStudioInstaller'.
VERBOSE: Importing function 'Get-VisualStudioInstallerHealth'.
VERBOSE: Importing function 'Get-VisualStudioInstance'.
VERBOSE: Importing function 'Get-VisualStudioVsixInstaller'.
VERBOSE: Importing function 'Get-WebContent'.
VERBOSE: Importing function 'Get-WebFile'.
VERBOSE: Importing function 'Get-WebFileName'.
VERBOSE: Importing function 'Get-WebHeaders'.
VERBOSE: Importing function 'Install-BinFile'.
VERBOSE: Importing function 'Install-ChocolateyDesktopLink'.
VERBOSE: Importing function 'Install-ChocolateyEnvironmentVariable'.
VERBOSE: Importing function 'Install-ChocolateyExplorerMenuItem'.
VERBOSE: Importing function 'Install-ChocolateyFileAssociation'.
VERBOSE: Importing function 'Install-ChocolateyInstallPackage'.
VERBOSE: Importing function 'Install-ChocolateyPackage'.
VERBOSE: Importing function 'Install-ChocolateyPath'.
VERBOSE: Importing function 'Install-ChocolateyPinnedTaskBarItem'.
VERBOSE: Importing function 'Install-ChocolateyPowershellCommand'.
VERBOSE: Importing function 'Install-ChocolateyShortcut'.
VERBOSE: Importing function 'Install-ChocolateyVsixPackage'.
VERBOSE: Importing function 'Install-ChocolateyZipPackage'.
VERBOSE: Importing function 'Install-DotNetDevPack'.
VERBOSE: Importing function 'Install-DotNetFramework'.
VERBOSE: Importing function 'Install-VisualStudio'.
VERBOSE: Importing function 'Install-VisualStudioInstaller'.
VERBOSE: Importing function 'Install-VisualStudioVsixExtension'.
VERBOSE: Importing function 'Install-Vsix'.
VERBOSE: Importing function 'Install-WindowsUpdate'.
VERBOSE: Importing function 'Register-Application'.
VERBOSE: Importing function 'Remove-Process'.
VERBOSE: Importing function 'Remove-VisualStudioComponent'.
VERBOSE: Importing function 'Remove-VisualStudioProduct'.
VERBOSE: Importing function 'Remove-VisualStudioWorkload'.
VERBOSE: Importing function 'Set-EnvironmentVariable'.
VERBOSE: Importing function 'Set-PowerShellExitCode'.
VERBOSE: Importing function 'Start-ChocolateyProcessAsAdmin'.
VERBOSE: Importing function 'Test-ProcessAdminRights'.
VERBOSE: Importing function 'Test-WindowsUpdate'.
VERBOSE: Importing function 'Uninstall-BinFile'.
VERBOSE: Importing function 'Uninstall-ChocolateyEnvironmentVariable'.
VERBOSE: Importing function 'Uninstall-ChocolateyPackage'.
VERBOSE: Importing function 'Uninstall-ChocolateyZipPackage'.
VERBOSE: Importing function 'Uninstall-VisualStudio'.
VERBOSE: Importing function 'Uninstall-VisualStudioVsixExtension'.
VERBOSE: Importing function 'Update-SessionEnvironment'.
VERBOSE: Importing function 'Write-ChocolateyFailure'.
VERBOSE: Importing function 'Write-ChocolateySuccess'.
VERBOSE: Importing function 'Write-FileUpdateLog'.
VERBOSE: Importing function 'Write-FunctionCallLogMessage'.
VERBOSE: Importing alias 'Add-BinFile'.
VERBOSE: Importing alias 'Generate-BinFile'.
VERBOSE: Importing alias 'Get-InstallRegistryKey'.
VERBOSE: Importing alias 'Get-OSBitness'.
VERBOSE: Importing alias 'Get-ProcessorBits'.
VERBOSE: Importing alias 'Invoke-ChocolateyProcess'.
VERBOSE: Importing alias 'refreshenv'.
VERBOSE: Importing alias 'Remove-BinFile'.
VERBOSE: Importing alias 'Start-ChocolateyProcess'.
---------------------------Script Execution---------------------------
Running 'ChocolateyScriptRunner' for visualstudio2017buildtools v15.9.22.0 with packageScript 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyInstall.ps1', packageFolder:'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools', installArguments: '', packageParameters: '',
Running 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyInstall.ps1'
Running 'Install-VisualStudio' for visualstudio2017buildtools with ApplicationName:'Microsoft Visual Studio Build Tools 2017' Url:'https://download.visualstudio.microsoft.com/download/pr/dfb60031-5f2b-4236-a36b-25a0197459bc/2f9a69561f6678f745b55ea38a606180b3941637d7e8cbbb65acae6933152d3e/vs_BuildTools.exe' Checksum:2F9A69561F6678F745B55EA38A606180B3941637D7E8CBBB65ACAE6933152D3E ChecksumType:SHA256 InstallerTechnology:'WillowVS2017OrLater' ProgramsAndFeaturesDisplayName:'Microsoft Visual Studio Build Tools 2017' VisualStudioYear:'2017' Product:'BuildTools' Preview:'False' DesiredProductVersion:''
Running 'Parse-Parameters' with s:''
No package parameters.
Resolving VS product instance(s)
Detecting Visual Studio products installed using the Willow installer (2017+)
Using the default VS CachePath: C:\ProgramData\Microsoft\VisualStudio\Packages
Base path 'C:\ProgramData\Microsoft\VisualStudio\Packages\_Instances' does not exist, assuming no products installed
Detecting instances of VS products with ProductId = 'Microsoft.VisualStudio.Product.BuildTools' ChannelId = 'VisualStudio.15.Release'
Detecting Visual Studio products installed using the Willow installer (2017+)
Using the default VS CachePath: C:\ProgramData\Microsoft\VisualStudio\Packages
Base path 'C:\ProgramData\Microsoft\VisualStudio\Packages\_Instances' does not exist, assuming no products installed
Resolved 0 product instance(s)
VERBOSE: Found 0 installed Visual Studio product(s) with ChannelId = VisualStudio.15.Release and ProductId = Microsoft.VisualStudio.Product.BuildTools
VERBOSE: Visual Studio installer will be downloaded from the Web
VERBOSE: Trying to determine the required installer and engine version from the manifests
Obtaining the channel manifest in order to determine the required installer version
Checking if the channel manifest URI has been provided
InstallChannelUri will not be used
Package parameters do not contain 'installChannelUri', it is empty or the scenario does not allow its use
Package parameters do not contain 'channelUri' or it is empty
ChannelReference InstallChannelUri property is empty
ChannelReference ChannelUri property is empty
Checking if the channel id has been provided
Package parameters do not contain 'channelId' or it is empty
Using channel id from the provided ChannelReference: 'VisualStudio.15.Release'
Using channel manifest URI computed from the channel id: 'https://aka.ms/vs/15/release/channel'
Not looking in LayoutPath because --noWeb was not passed in package parameters
VERBOSE: Obtaining the manifest file for url 'https://aka.ms/vs/15/release/channel' (channel manifest)
VERBOSE: Local cached file 'C:\Users\jzhang4\AppData\Local\Temp\chocolatey\chocolatey-visualstudio.extension\ChannelManifest_81725945.man' does not exist
VERBOSE: Downloading the manifest file (channel manifest)
Running Get-ChocolateyWebFile -url 'https://aka.ms/vs/15/release/channel' -packageName 'channel manifest' -fileFullPath 'C:\Users\jzhang4\AppData\Local\Temp\chocolatey\chocolatey-visualstudio.extension\ChannelManifest_81725945.man'
Running Get-ProcessorBits -compare '64'
CPU is 64 bit
Running Get-WebHeaders -url 'https://aka.ms/vs/15/release/channel' -ErrorAction 'Stop'
Setting the UserAgent to 'chocolatey command line'
Request Headers:
  'Accept':'*/*'
  'User-Agent':'chocolatey command line'
Attempt to get headers for https://aka.ms/vs/15/release/channel failed.
  The remote file either doesn't exist, is unauthorized, or is forbidden for url 'https://aka.ms/vs/15/release/channel'. Exception calling "GetResponse" with "0" argument(s): "The underlying connection was closed: An unexpected error occurred on a send."
Downloading channel manifest
  from 'https://aka.ms/vs/15/release/channel'
Running Get-WebFile -url 'https://aka.ms/vs/15/release/channel' -fileName 'C:\Users\jzhang4\AppData\Local\Temp\chocolatey\chocolatey-visualstudio.extension\ChannelManifest_81725945.man' -options 'System.Collections.Hashtable'
Setting request timeout to  30000
Setting read/write timeout to  2700000
Setting the UserAgent to 'chocolatey command line'
VERBOSE: No ISO to dismount
ERROR: The remote file either doesn't exist, is unauthorized, or is forbidden for url 'https://aka.ms/vs/15/release/channel'. Exception calling "GetResponse" with "0" argument(s): "The underlying connection was closed: An unexpected error occurred on a send."
 at Get-WebFile, C:\ProgramData\chocolatey\helpers\functions\Get-WebFile.ps1: line 331
at Get-ChocolateyWebFile, C:\ProgramData\chocolatey\helpers\functions\Get-ChocolateyWebFile.ps1: line 345
at Get-VSManifest, C:\ProgramData\chocolatey\extensions\chocolatey-visualstudio\Get-VSManifest.ps1: line 69
at Get-VSChannelManifest, C:\ProgramData\chocolatey\extensions\chocolatey-visualstudio\Get-VSChannelManifest.ps1: line 115
at Get-VSRequiredInstallerVersion, C:\ProgramData\chocolatey\extensions\chocolatey-visualstudio\Get-VSRequiredInstallerVersion.ps1: line 13
at Assert-VSInstallerUpdated, C:\ProgramData\chocolatey\extensions\chocolatey-visualstudio\Assert-VSInstallerUpdated.ps1: line 21
at Install-VisualStudio, C:\ProgramData\chocolatey\extensions\chocolatey-visualstudio\Install-VisualStudio.ps1: line 157
at <ScriptBlock>, C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyInstall.ps1: line 1
at <ScriptBlock>, C:\ProgramData\chocolatey\helpers\chocolateyScriptRunner.ps1: line 49
at <ScriptBlock>, <No file>: line 1
Built-in PowerShell host called with ['[System.Threading.Thread]::CurrentThread.CurrentCulture = '';[System.Threading.Thread]::CurrentThread.CurrentUICulture = ''; & import-module -name 'C:\ProgramData\chocolatey\helpers\chocolateyInstaller.psm1'; & 'C:\ProgramData\chocolatey\helpers\chocolateyScriptRunner.ps1' -packageScript 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyInstall.ps1' -installArguments '' -packageParameters '''] exited with '404'.
Calling command ['"C:\Windows\System32\shutdown.exe" /a']
Command ['"C:\Windows\System32\shutdown.exe" /a'] exited with '1116'
Capturing package files in 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools'
 Found 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\visualstudio2017buildtools.nupkg'
  with checksum 'E5F4A66FF98C7AC71C079826120084D0'
 Found 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\visualstudio2017buildtools.nuspec'
  with checksum 'C3E58C48ADA7E32E9AFFBE32C1FE70A6'
 Found 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\.skipAutoUninstall'
  with checksum 'D41D8CD98F00B204E9800998ECF8427E'
 Found 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyInstall.ps1'
  with checksum '620152EAA1AF8EB7E233A3620987E37A'
 Found 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyUninstall.ps1'
  with checksum '18CB839A9D378AFCC49A2AD4E90E4D2F'
Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\visualstudio2017buildtools.15.9.22.0\.arguments".
Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\visualstudio2017buildtools.15.9.22.0\.extra".
Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\visualstudio2017buildtools.15.9.22.0\.version".
Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\visualstudio2017buildtools.15.9.22.0\.sxs".
Attempting to delete file "C:\ProgramData\chocolatey\.chocolatey\visualstudio2017buildtools.15.9.22.0\.pin".
Attempting to delete directory "C:\ProgramData\chocolatey\lib-bad\visualstudio2017buildtools".
Sending message 'HandlePackageResultCompletedMessage' out if there are subscribers...
The install of visualstudio2017buildtools was NOT successful.
Error while running 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyInstall.ps1'.
 See log for details.
Moving 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools'
 to 'C:\ProgramData\chocolatey\lib-bad\visualstudio2017buildtools'
Attempting to delete file "C:\Users\jzhang4\AppData\Local\NuGet\Cache\visualstudio2017buildtools.15.9.22.0.nupkg".

Chocolatey installed 0/2 packages. 2 packages failed.
 See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).

Failures
 - visualstudio2017buildtools (exited 404) - Error while running 'C:\ProgramData\chocolatey\lib\visualstudio2017buildtools\tools\ChocolateyInstall.ps1'.
 See log for details.
 - dotnetfx (exited 404) - Error while running 'C:\ProgramData\chocolatey\lib\dotnetfx\tools\ChocolateyInstall.ps1'.
 See log for details.
Sending message 'PostRunMessage' out if there are subscribers...
Exiting with 404
CriticalWill commented 3 years ago

It looks like this issue is similar to issue #52 that was closed due to lack of response. Before seeing this issue, I requested to reopen that one. I'm attaching my log here as well and deleting my comment from the other request. chocolatey.log

jberezanski commented 3 years ago

ERROR: The remote file either doesn't exist, is unauthorized, or is forbidden for url 'https://download.visualstudio.microsoft.com/download/pr/014120d7-d689-4305-befd-3cb711108212/0fd66638cde16859462a6243a4629a50/ndp48-x86-x64-allos-enu.exe'. Exception calling "GetResponse" with "0" argument(s): "The underlying connection was closed: An unexpected error occurred on a send."

ERROR: The remote file either doesn't exist, is unauthorized, or is forbidden for url 'https://aka.ms/vs/15/release/channel'. Exception calling "GetResponse" with "0" argument(s): "The underlying connection was closed: An unexpected error occurred on a send."

It looks like Chocolatey is unable to download not only the Visual Studio manifest, but also the .NET 4.8 installer, so this is a more general problem. And yes, the error message is the same as one that would be shown when the client could not negotiate the TLS version with the server, but it might also mean other network issues (such as a traffic filtering device interfering with the connection).

However, choco.exe takes care of enabling TLS up to 1.2 if the system supports it (and Server 2016 certainly does). This strongly points to some other cause than TLS. You can test this by running

Write-Host "Default SecurityProtocol: $([Net.ServicePointManager]::SecurityProtocol)"
Write-Host "Attempting to download the VS channel manifest - this may fail because of TLS version"
Invoke-WebRequest -UseBasicParsing -Uri 'https://aka.ms/vs/15/release/channel' -OutFile vs15release.json
Write-Host "Enabling TLS 1.2 and older"
[Net.ServicePointManager]::SecurityProtocol = 'Tls12,Tls11,Tls'
Write-Host "Updated SecurityProtocol: $([Net.ServicePointManager]::SecurityProtocol)"
Write-Host "Attempting to download the VS channel manifest - if this fails, TLS version is not the cause"
Invoke-WebRequest -UseBasicParsing -Uri 'https://aka.ms/vs/15/release/channel' -OutFile vs15release.json

in a new PowerShell window.

If the last command above fails, I'd thoroughly examine the network configuration between the machine and the Internet, looking for any restrictions for outbound traffic:

jberezanski commented 1 year ago

Closing due to inactivity.