当前位置:网站首页>Troubleshooting: kubectl reports an error validationerror: unknown field \u00a0
Troubleshooting: kubectl reports an error validationerror: unknown field \u00a0
2022-07-02 18:44:00 【Migrant worker Lao Wang】
Blog home page :https://tomcat.blog.csdn.net
Blogger's nickname : Lao Wang of migrant workers
Main areas :Java、Linux、K8S
We look forward to your attention, praise and collection comments
Fault details
Recently k8s Through the cluster kubectl apply -f When deploying resources , Encountered the following error . It was quickly solved at that time . Now record the faults and troubleshooting methods , To facilitate developers who encounter the same error .
error: error validating “nfs.yaml”: error validating data: [ValidationError(ServiceAccount): unknown field “\u00a0\u00a0name” in io.k8s.api.core.v1.ServiceAccount, ValidationError(ServiceAccount): unknown field “\u00a0\u00a0namespace” in io.k8s.api.core.v1.ServiceAccount]; if you choose to ignore these errors, turn validation off with --validate=false

The analysis reason
The error message has been clearly described , Because name Before “\u00a0\u00a0” Caused by two characters . We know through inquiry ,\u00a0 stay utf-8 In the encoding , Represents an uninterrupted space , Mainly used in office in , Let a word not wrap at the end . stay word in , Can pass ctrlshiftspace Input .
We are IDEA Open... In the editor nfs.yaml file , Then look for spaces , No match found name And all white space characters representing indentation . It also verifies the prompt message of error .

use Sublime Text open , It is easier to find differences :
It turns out the yaml The contents of the file are from a word Files are copied directly , Inadvertently, it contains some \u00a0 This special white space character .
Solve the problem
The solution is simple , Directly in the editor \u00a0 Replace with ordinary spaces ,IDEA,Sublime Text Can be easily realized .

After replacement, it can be deployed smoothly .

If you want to reprint , Please indicate the source of this article : Migrant worker Lao Wang's CSDN Blog https://blog.csdn.net/monarch91 .
边栏推荐
- 一款简约PHP个人发卡程序V4.0版本
- Leetcode(154)——寻找旋转排序数组中的最小值 II
- 呆错图床系统源码图片CDN加速与破J防盗链功能
- RTE11- 中断解耦功能
- MySQL 关于 only_full_group_by 限制
- Leetcode (154) -- find the minimum value II in the rotation sort array
- options should NOT have additional properties
- 问题包含哪些环节
- Web版3D可视化工具,程序员应该知道的97件事,AI前沿论文 | 资讯日报 #2022.07.01
- NM01-独立于总线协议的NM模块功能概述与API定义
猜你喜欢

NM01-独立于总线协议的NM模块功能概述与API定义

呆错图床系统源码图片CDN加速与破J防盗链功能

A simple PHP personal card issuing program v4.0

Wechat applet video sharing platform system graduation design completion (6) opening defense ppt

初夏,开源魔改一个带击杀音效的电蚊拍!

【每日一题】第一天

Chrome 正式支持 MathML,默认在 Chromium Dev 105 中启用

Leetcode interview question 17.04 Vanishing numbers

距离度量 —— 杰卡德距离(Jaccard Distance)

ESP32-C3入门教程 问题篇⑩——error: implicit declaration of function ‘esp_blufi_close‘;
随机推荐
【西北工业大学】考研初试复试资料分享
深度神经网络总结
300+篇文献!一文详解基于Transformer的多模态学习最新进展
Unity学习shader笔记[八十二]增强单通道颜色渲染的黑白处理
Leetcode interview question 16.17 Continuous sequence
cJSON 使用详解
Leetcode 面试题 16.15. 珠玑妙算
链游系统开发(Unity3D链游开发详情)丨链游开发成熟技术源码
Server PHP environment building tutorial, PHP server environment building graphic explanation
Wechat applet video sharing platform system graduation design completion (4) opening report
Leetcode (81) -- search rotation sort array II
如何设置VSCode删除整行快捷键?
Leetcode (154) -- find the minimum value II in the rotation sort array
Leetcode 面试题 16.17. 连续数列
Wechat nucleic acid detection appointment applet system graduation design completion (5) task statement
如何优雅的写 Controller 层代码?
SLAM|如何时间戳对齐?
M2DGR:多源多场景 地面机器人SLAM数据集(ICRA 2022 )
【Oracle 期末复习】表空间、表、约束、索引、视图的增删改
ESP32-C3入门教程 问题篇⑪——esp-tls: create_ssl_handle failed, tls_io_instance->options.trusted_certs null
