「VxRail:kubectlコマンドの戻り値: 権限のないサーバにログインしている必要があります

Summary: VxRail Managerのkubectlコマンドで次の結果が返されます。kubeconfigデータが正しくないため、サーバー(Unauthorized)にログインする必要があります。

This article applies to This article does not apply to This article is not tied to any specific product. Not all product versions are identified in this article.

Symptoms

VxRail Managerでkubectlコマンドを実行すると、次の出力が表示されます。

error: You must be logged in to the server (Unauthorized)

エラーが発生します。サーバにログインする必要があります(未承認)
これは、rke2 YAMLファイルからkubeconfigをロードする場合には表示されません。/etc/rancher/rke2/rke2.yaml

kubectl --kubeconfig /etc/rancher/rke2/rke2.yaml -n helium get nodes

kubectl --kubeconfig /etc/rancher/rke2/rke2.yaml -n helium get nodes
 

このエラーは、スクリプト dell_node_replacement.pyでノードの削除オプションを実行している場合にも表示されます。

Failed to clean redis!\error: You must be logged in to the server (Unauthorized)
error: pod, type/name or --filename must be specified 

Cause

RKE2サービスが1年以上実行されている $HOME/.kube/config 有効期限が切れています。

Resolution

この問題が発生した場合は、 Dellサポート にお問い合わせの上、このKBを参照用に提供してください。 

Affected Products

VxRail Appliance Family, VxRail Appliance Series
Article Properties
Article Number: 000212809
Article Type: Solution
Last Modified: 08 Apr 2025
Version:  6
Find answers to your questions from other Dell users
Support Services
Check if your device is covered by Support Services.