docs
uk8s
Service Discovery
CloudProvider Plugin Upgrade

CloudProvider Plugin Update

UK8S implements the creation and binding of the cluster's LoadBalancer type services (SVC) and SurferCloud ULB products through the CloudProvider plugin.

Version issue

  • Lower than 20.10.1 version

Before version 20.10.1, there was a bug that would cause misjudgments during Service restart, leading to repeated creation of ULB instances and writing into the cluster, causing the corresponding Service in the cluster to be unavailable. For this, we optimized the CloudProvider plugin, improved the call logic of the related ULB interface, and avoided the occurrence of the above problems.

  • 24.03.13 version

Beginning with version 24.03.13, it supports Application Load Balancing ALB, but there is an issue with this version when multiple Services bind to the same ALB. Users using this version are advised to upgrade to 24.06.28 as soon as possible.

If your cluster's CloudProvider version is the corresponding version, please be sure to update in time according to the documentation to avoid affecting your business. The upgrade process does not affect online business, but we still advise you to perform updates during off-peak business hours. If you encounter problems, please feel free to contact us.

1. Version review and plugin upgrade

1.1 Console operation

For UK8S clusters within the maintenance version, the CloudProvider plugin upgrade function can be activated on the console management page "Plugin-CloudProvider" page. Activating the CloudProvider plugin upgrade function will execute the CloudProvider plugin query task in the cluster and will need about 3 minutes, please do not operate the cluster during this process. After the upgrade function is turned on, you can see the CloudProvider plugin version information and click on "Upgrade CloudProvider" to perform the upgrade.

The upgrade process takes approximately 1-3 minutes. During the upgrade process, the "Current Version" column will be displayed as "Upgrading". After the upgrade is completed, the latest version number is displayed. If the upgrade fails, you can try the upgrade again or contact our technical support.

⚠️ When upgrading the cluster's CloudProvider plugin, please do not perform operations such as service publishing, etc.

1.2 Manual upgrade

If the cluster version is not within our maintenance version, the console will not be able to upgrade directly, refer to: UK8S Version Maintenance Instructions.

At this time, you can manually upgrade the cloudprovider, please execute the following command:

kubectl apply -f https://docs.surfercloud.com/uk8s/yaml/cloudprovider/24.06.28.yml

1.3 Upgrade from an older version

If the Kubernetes version is before 1.14, or if you cannot see the CloudProvider version information in the console, you need to upgrade via the command line.

Log in to your cluster's Master nodes, if executing systemctl status ucloudcp is running, please be sure to close the binary program ucloudcp and update it on 3 Master nodes.

1. Close the old version of CloudProvider

Please log in to all 3 master nodes and execute the following commands

systemctl stop ucloudcp
systemctl disable ucloudcp

2. Pre-Configure ConfigMap

Please fill in the related information below and save the file as userdata.yaml.

apiVersion: v1
kind: ConfigMap
metadata:
  name: uk8sconfig
  namespace: kube-system
data:
  UCLOUD_ACCESS_PRIKEY: xxxxxxxxxxxxxxx  #API PRIKEY
  UCLOUD_ACCESS_PUBKEY: xxxxxxxxxxxxxxx  #API_PUBKEY
  UCLOUD_API_ENDPOINT: http://api.service.surfercloud.com
  UCLOUD_PROJECT_ID: org-xxxxxx   #The project ID where the cluster is located
  UCLOUD_REGION_ID: cn-bj2  #The region where the cluster is located, refer to: https://docs.surfercloud.com//docs/api/summary/regionlist
  UCLOUD_SUBNET_ID: subnet-xxxxxx  #The subnet ID where the cluster is located
  UCLOUD_UK8S_CLUSTER_ID: uk8s-xxxxxx  #UK8S cluster name
  UCLOUD_VPC_ID: uvnet-xxxxxx   #The VPC ID where the cluster is located

3. Create ConfigMap

kubectl apply -f userdata.yaml

4. Deploy CloudProvider

kubectl apply -f https://docs.surfercloud.com/uk8s/yaml/cloudprovider/22.07.1.yml

5. Check if the deployment is successful

If the Pod is not in running state, please contact our technical support in time. After the update is successful, you can view the version information on the console and proceed with the subsequent upgrade.

kubectl get pod -n kube-system -l app=cloudprovider-ucloud -o wide

2. Change record

Updated version: 24.06.28

Updated time: June 28, 2024

Updated content:

  • Fixed the issue of binding multiple svcs to the same ALB

Updated version: 24.03.13

Update time: March 14, 2024

Update content:

  • Support ALB

Update version: 24.03.5

Update time: March 7, 2024

Update content:

  • Support mixed use of ULB4's tcp and udp protocols

Update version: 23.04.2

Update time: July 6, 2023

Update content:

  • Reduce the timeout of telemetry to avoid the normal use of ULB being affected by telemetry timeout

Updated version: 22.10.1

Updated time: October 25, 2022

Updated content:

  • Optimized ULB Backend addition logic, speeding up the speed of LoadBalancer type Service to get the external IP
  • Optimized the default bandwidth configuration of the EIP bound by the external network ULB. If the bandwidth is not explicitly specified in the Service, it will not update the bandwidth value of the existing EIP. For the new EIP created by the Cloud Provider, the default bandwidth is still used.

Updated version: 22.07.1

Updated time: July 15, 2022

Updated content:

  • Optimized ULB query logic, improve service modification and deletion speed.
  • Added a fallback mechanism to match ULB through EIP. This is to prevent ULB reconstruction caused by the user manually modifying the ULB name or remarks causing the Service to not be able to match ULB correctly.

Updated version: 22.06.2

Updated time: June 28, 2022

Updated content:

  • Fixed the defect where the service's externalTrafficPolicy attribute is Local, and lacks ULB info injection.

Updated version: 22.06.1

Updated time: June 10, 2022

Updated content:

  • Updated dependent cloud provider framework to v0.20.15, to introduce kubernetes/cloud-provider#38 so that node status updates can notify the cloud provider as quickly as possible unchecked and nodes with "node.kubernetes.io/exclude-from-external-load-balancers" label will not join the lb in rs, but no longer based on SchedulingDisabled status (behavior changes brought about by the upgrade of the k8s cloud provider framework)

Updated version: 21.10.2

Updated time: November 4, 2021

Updated content:

  • Optimized the verification of the ULB name, and fixed the issue where the initial creation of VServer failed causing Service creation to fail.

Updated version: 21.10.1

Updated time: October 14, 2021

Updated content:

  • When using a specified ULB to create a LoadBalancer type Service, it cannot specify the ULB created by CloudProvider.

Updated version: 21.05.2

Updated time: May 28, 2021

Updated content:

  • Add Endpoint Controller, sense Endpoint changes, only add the host node running Pod into ULB VServer Backends when externalTrafficPolicy=Local.
  • Note: Frequent changes of Endpoint will cause a large number of ULB API calls, you need to add the following parameters to the cloud provider for speed limit processing. If you need to adjust the parameters, you must adjust the plugin through the command line.
containers:
  - name: cloudprovider-ucloud
    image: uhub.surfercloud.com/uk8s/cloudprovider-ucloud:21.05.2
    args:
    - "--endpoint-updates-batch-period=10"   ## All Endpoint events are processed every N seconds, the default is 10

Updated version: 21.05.1

Updated time: May 11, 2021

Updated content:

  • Support UDP type ULB health check mode, it is necessary to declare the following parameters in the Service's Annotations. For ULB health check mechanism, please refer to: Health Check. For ULB annotation details, please refer to: ULB Parameter Description
annotations:
  ## The following parameters are only valid for UDP type ULB
  service.beta.kubernetes.io/ucloud-load-balancer-vserver-monitor-type: "customize"      ## Set health check type to customize, representing UDP health check
  service.beta.kubernetes.io/ucloud-load-balancer-vserver-monitor-reqmsg: ""    ## Represents the request message sent out by UDP health check
  service.beta.kubernetes.io/ucloud-load-balancer-vserver-monitor-respmsg: ""   ## Represents the response message that the UDP health check request should receive

Updated version: 21.04.1

Updated time: April 22, 2021

Updated content:

  • You can use Service Annotation to add annotations to nodes, so that when they are set to not schedulable (that is, execute Cordon node operation), they will not be automatically removed from ULB
annotations:
  ## Defaults to 'true', when set to 'false', the node will not be automatically removed from ULB when it is not scheduled
  service.beta.kubernetes.io/ucloud-load-balancer-remove-unscheduled-backend: "false"

Updated version: 21.02.1

Updated time: February 6, 2021

Updated content:

  • Support for internal ULB7
  • Support for ULB7's TCP mode

Updated version: 20.10.2

Updated time: October 29, 2020

Updated content:

Updated version: 20.10.1

Updated time: October 20, 2020

Updated content:

  • After successfully creating a LoadBalancer type Service dynamically, the plugin will inject the associated ULB Id into the Service's Annotations, to avoid ULB reconstruction caused by factors such as API timeouts.

Updated version: 20.09.4

Updated time: September 18, 2020

Change content:

  • Upgrade SurferCloud Go SDK to fix ULB firewall settings,
  • Added newly created, use temporary ULB client for API calls.

Updated version: 20.09.3

Updated time: September 17, 2020

Change content:

  • Updated monitoring information (non-mandatory update).

Updated version: 20.09.2

Updated time: September 8, 2020

Change content:

  • Increased fault tolerance of ULB-related interface calls after cloudprovider restart, improving the stability of cluster operation.
  • Company
  • ContactUs
  • Blog
Copyright © 2024 SurferCloud All Rights Reserved