Skip to content

Cannot create Software Repository Firmware or OS Image Links. #189

@tgrabrian

Description

@tgrabrian

Describe the bug
Calls to New-IntersightSoftwarerepositoryOperatingSystemFile or New-IntersightFirmwareDistributable produce error ""code":"InvalidRequest","message":"Cannot set property 'softwarerepository.File.Version'. This property is required.","messageId":"barcelona_request_cannot_access_property_required","messageParams":{"1":"softwarerepository.File","2":"Version"},"traceId":"TRACE"}"

Each of the above cmdlets call out a specific, seemingly internal function which throws the error:
"Error calling CreateSoftwarerepositoryOperatingSystemFile" or "Error calling CreateFirmwareDistributable"

To Reproduce

$Organization = "default"
$Result = Get-IntersightOrganizationOrganization -Name $Organization
$OrgRef = Get-IntersightMoMoRef -ManagedObject $Result

$Catalog = Get-IntersightSoftwarerepositoryCatalog -Name "user-catalog" -Organization $OrgRef
$CatalogRef = Get-IntersightMoMoRef -ManagedObject $Catalog

$dictionary = [Collections.Generic.Dictionary[string, object]]::new()
$dictionary.Add("LocationLink", "https://1.1.1.1/test.iso")
$Source = Initialize-IntersightSoftwarerepositoryFileServer -ClassId "SoftwarerepositoryHttpServer" -ObjectType "SoftwarerepositoryHttpServer" -AdditionalProperties $dictionary

$OsImage = @{
    Catalog = $CatalogRef
    Name    = "test.iso"
    Source  = $Source
    Vendor  = "VMware"
    Version = "ESXi 6.0 U2"
}
New-IntersightSoftwarerepositoryOperatingSystemFile @OsImage
# New-IntersightSoftwarerepositoryOperatingSystemFile: Error calling CreateSoftwarerepositoryOperatingSystemFile: {"code":"InvalidRequest","message":"Cannot set property 'softwarerepository.File.Version'. This property is required.","messageId":"barcelona_request_cannot_access_property_required","messageParams":{"1":"softwarerepository.File","2":"Version"},"traceId":"zIj4RCB749ewbZMsp3g-Y2z7q-JyvvpegPFj3Kb_e-dZDhbW3qTR_A=="}

$dictionary = [Collections.Generic.Dictionary[string, object]]::new()
$dictionary.Add("LocationLink", "https://1.1.1.1/ucs-c220m5-huu-4.3.2.240053.iso")
$dictionary.Add("Username", "")
$Source = Initialize-IntersightSoftwarerepositoryFileServer -ClassId "SoftwarerepositoryHttpServer" -ObjectType "SoftwarerepositoryHttpServer" -AdditionalProperties $dictionary

$Firmware = @{
    Source          = $Source
    Version         = "4.3(2.240053)"
    Catalog         = $CatalogRef
    Name            = "ucs-c220m5-huu-4.3.2.240053"
    SupportedModels = @("HX220C-M5SX", "HXAF220C-M5SN", "HXAF220C-M5SX", "UCSC-C220-M5L", "UCSC-C220-M5SN", "UCSC-C220-M5SX")
    Description     = ""
}
New-IntersightFirmwareDistributable @Firmware 
# New-IntersightFirmwareDistributable: Error calling CreateFirmwareDistributable: {"code":"InvalidRequest","message":"Cannot set property 'softwarerepository.File.Version'. This property is required.","messageId":"barcelona_request_cannot_access_property_required","messageParams":{"1":"softwarerepository.File","2":"Version"},"traceId":"AR3qFxl-S-aAeIkn3effwmB9P2CIAjBj6u8X46F4pVvqO9ugF2gHqw=="}

Version used

  • PowerShell 7.4.1
  • Intersight.PowerShell Version 1.0.11.2025021903
  • Intersight SaaS

Expected behavior
Expect no errors and successful object creation.

Additional context
The above configuration snipbit was made by manually performing the action within the Intersight portal, inspecting the network traffic during said actions, then replicating the behavior within Powershell. You'll also notice that the above configuration requires the use of the "-AdditonalProperties" parameter on the calls to Initialize-IntersightSoftwarerepositoryFileServer as it does not natively support any of the required parameters.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions