aws / aws-parallelcluster-ui

Apache License 2.0
31 stars 20 forks source link

PerUnitStorageThroughput included in YAML when adding scratch filesystem #116

Closed simone-pignotti closed 1 year ago

simone-pignotti commented 1 year ago

Description

When adding FSX storage of type SCRATCH_2, the following line gets automatically added to the YAML configuration file and makes the creation/update fail:

[...]
SharedStorage:
  - Name: FsxLustre2
    StorageType: FsxLustre
    MountDir: /scratch
    FsxLustreSettings:
      StorageCapacity: '1200'
      DeploymentType: SCRATCH_2
      PerUnitStorageThroughput: 125

Steps to reproduce the issue

Add a SCRATCH_2 FsxLustre storage resource to a cluster through the UI.

Expected behaviour

The PerUnitStorageThroughput key should be omitted from the YAML.

Actual behaviour

The creation fails with the following error message:

FsxPersistentOptionsValidator: Per unit storage throughput can only be used when deployment type is one of ['PERSISTENT_1', 'PERSISTENT_2'].
FsxStorageTypeOptionsValidator: 'SCRATCH_2'

NB: this also happens any time the same cluster is edited, even if no change to the storage is made. I have to manually delete the PerUnitStorageThroughput: 125 line at every update.

Required info

BarcoMasile commented 1 year ago

Hi Simone, thanks for reaching out and definitely good catch! We'll track this bug and fit it in our board ASAP

I'll update this issue when the fix is merged

mtfranchetto commented 1 year ago

Hello @simone-pignotti, we have fixed the issue with #148. At the moment, since the code is not released yet, you can fix the issue by manually updating the PCUI Lambda function with the build_and_update_lambda.sh script.