LATEST VERSION: v1.3 - RELEASE NOTES
Pivotal Container Service v1.3

Scaling Existing Clusters

This topic explains how to scale an existing cluster by using the PKS CLI to increase or decrease the number of worker nodes in the cluster.

Follow the steps below to scale an existing cluster using the PKS CLI.

  1. On the command line, run the following command to log in:

    pks login -a PKS-API -u USERNAME -k
    
    See Log in to the PKS CLI for more information about the pks login command.

  2. To view the current number of worker nodes in your cluster, run the following command:

    pks cluster CLUSTER-NAME
    

    Where CLUSTER-NAME is the name of your cluster.

  3. Run the following command:

    pks resize CLUSTER-NAME --num-nodes NUMBER-OF-WORKER-NODES
    

    Where:

    • CLUSTER-NAME is the name of your cluster.
    • NUMBER-OF-WORKER-NODES is the number of worker nodes you want to set for the cluster.
      • To scale down your existing cluster, enter a number lower than the current number of worker nodes.
      • To scale up your existing cluster, enter a number higher than the current number of worker nodes. The maximum number of worker nodes you can set is configured in the Plan pane of the Pivotal Container Service tile in Pivotal Ops Manager.

    For example:

    $ pks resize my-cluster --num-nodes 5
    

    Note: This command may roll additional virtual machines in the cluster, which can affect workloads if the worker nodes are at capacity.


Please send any feedback you have to pks-feedback@pivotal.io.

Create a pull request or raise an issue on the source for this page in GitHub