Upgrade GKE node types
If you’re running Portworx on GKE and want to migrate to nodes with more resources, you can do this by adding new nodes and retiring old ones. Perform the following steps to migrate nodes:
Add a new node pool containing your desired node type.
Ensure that all nodes in the new node pool have Portworx in storageless mode.
Disable auto scaling in the old pool.
Choose a node from your old node pool that you want to remove:
pxctl cluster list
Cluster ID: 8ed1d365-fd1b-11e6-b01d-0242ac110002 Status: OK Nodes in the cluster: ID DATA IP CPU MEM TOTAL MEM FREE CONTAINERS VERSION STATUS bf9eb27d-415e-41f0-8c0d-4782959264bc 126.96.36.199 0.125078 34 GB 33 GB N/A 1.1.4-6b35842 Online 7d97f9ea-a4ff-4969-9ee8-de2699fa39b4 188.8.131.52 0.187617 34 GB 33 GB N/A 1.1.4-6b35842 Online 492596eb-94f3-4422-8cb8-bc72878d4be5 184.108.40.206 0.125078 34 GB 33 GB N/A 1.1.4-6b35842 Online
Once you’ve chosen a node ID, enter the following
kubectlcommand to drain the node, replacing
<node-id>with the ID of the node that you want to remove:
kubectl drain <node-id> --ignore-daemonsets --delete-emptydir-data
Drain volume attachments:
pxctl service node drain-attachments submit --node <node-id>
Delete the node from Kubernetes:
kubectl delete node <node>
In the GKE console, find the node by name and delete the instance.
Choose a storageless node and restart Portworx so that it becomes a storage node:
kubectl label <node> px/service=restart --overwrite
Wait until the storage node is back up before proceeding.
Re-enable attachments on the node:
pxctl service node uncordon-attachments --node <node-id>
Repeat steps 4 through 10 for each remaining node in your cluster that you want to remove.