trident icon indicating copy to clipboard operation
trident copied to clipboard

Resize Docker Volume with ontap-nas and ontap-nas-economy

Open chaudhariatul opened this issue 2 years ago • 2 comments

Describe the bug Volume size cannot be updated to a new size.

Environment

  • Trident version: 23.01
  • Trident installation flags used:
  • Container runtime: Docker CE 20.10.16
  • Kubernetes version: N/A
  • Kubernetes orchestrator: N/A
  • Kubernetes enabled feature gates: N/A
  • OS: AmazonLinux2
  • NetApp backend types: AWS FSx

To Reproduce Steps to reproduce the behavior:

  1. Install docker yum -y install docker
  2. Create Trident config file gp01.json
    {
          "version": 1,
          "storageDriverName": "ontap-nas-economy",
          "allowVolumeExpansion": true,
          "managementLIF": "10.10.10.180",
          "dataLIF": "10.10.10.180",
          "svm": "svm03",
          "clientCertificate": "adadsadsadadaad........",
          "clientPrivateKey": "LS0tLS1CRUd.........",
          "aggregate": "aggr1",
          "storagePrefix": "gp01_"
    }
  1. docker plugin install docker plugin install --grant-all-permissions --alias gp01 netapp/trident-plugin:23.01 config=gp01.json
  2. docker plugin ls
ID             NAME               DESCRIPTION                             ENABLED
410f33f4a3a5   gp01:latest   Trident - NetApp Docker Volume Plugin   true

Expected behavior

  1. Create a docker volume docker volume create -d gp01 --name gp01_vol01 --opt size=10G
  2. Update volume size docker volume create -d gp01 --name gp01_vol01 --opt size=50G
  3. docker volume should be resized to 50G

Additional context

This is needed for some workloads where we need to run an application as a docker container and persist data in NFS share.

chaudhariatul avatar Mar 22 '23 22:03 chaudhariatul

Hi @chaudhariatul,

Docker doesn't officially support expanding a volume via that CLI. The docker volume create command only supports creating the volume.

As a work around, you can expand your AWS FSx volume. For an NFS volume this is non-disruptive and the increased volume capacity will immediately be available for use.

gnarl avatar Mar 23 '23 17:03 gnarl

Hi @gnarl,

Yeah, I tried these and within the container when share is mounted (qtree included) this shows the change in capacity, however docker volume inspect still shows the original capacity.

I'm guessing a feature request is needed on Trident to provide integration to increase volume (or qtree) capacity.

chaudhariatul avatar Mar 23 '23 18:03 chaudhariatul

@chaudhariatul Please let us know if this issue still exists with the newer versions of Trident. If not, please close the issue.

sjpeeris avatar Oct 30 '24 12:10 sjpeeris