创建部署问题时,请参考下面模板,你提供的信息越多,越容易及时获得解答。如果未按模板创建问题,管理员有权关闭问题。
确保帖子格式清晰易读,用 markdown code block 语法格式化代码块。
你只花一分钟创建的问题,不能指望别人花上半个小时给你解答。
在Centos7.7中离线安装k8s时报错,运行如下命令:
./kk create cluster -f config-sample.yaml -a kubesphere.tar.gz –with-packages
报错信息如下:

全部信息如下:
[root@master ~]# ./kk create cluster -f config-sample.yaml -a kubesphere.tar.gz –with-packages
| | / / | | | | / /
| |/ / _ _| |__ ___| |/ / ___ _ _
| \| | | | '_ \ / _ \ \ / _ \ | | |
| |\ \ || | |) | __/ |\ \ __/ |_| |
\| \/\,|./ \\| \/\|\__, |
__/ |
|___/
22:13:11 CST [NodePreCheckModule] A pre-check on nodes
22:13:12 CST success: [node2]
22:13:12 CST success: [master]
22:13:12 CST success: [node1]
22:13:12 CST [ConfirmModule] Display confirmation form
+——–+——+——+———+———-+——-+——-+———–+——–+———+————+————-+——————+————–+
| name | sudo | curl | openssl | ebtables | socat | ipset | conntrack | chrony | docker | nfs client | ceph client | glusterfs client | time |
+——–+——+——+———+———-+——-+——-+———–+——–+———+————+————-+——————+————–+
| master | y | y | y | y | y | y | y | y | 20.10.8 | | | | CST 22:13:12 |
| node1 | y | y | y | y | y | y | y | y | 20.10.8 | | | | CST 22:13:12 |
| node2 | y | y | y | y | y | y | y | y | 20.10.8 | | | | CST 22:13:11 |
+——–+——+——+———+———-+——-+——-+———–+——–+———+————+————-+——————+————–+
This is a simple check of your environment.
Before installation, you should ensure that your machines meet all requirements specified at
https://github.com/kubesphere/kubekey#requirements-and-recommendations
Continue this installation? [yes/no]: yes
22:13:13 CST success: [LocalHost]
22:13:13 CST [UnArchiveArtifactModule] Check the KubeKey artifact md5 value
22:13:39 CST success: [LocalHost]
22:13:39 CST [UnArchiveArtifactModule] UnArchive the KubeKey artifact
22:13:39 CST skipped: [LocalHost]
22:13:39 CST [UnArchiveArtifactModule] Create the KubeKey artifact Md5 file
22:13:39 CST skipped: [LocalHost]
22:13:39 CST [RepositoryModule] Get OS release
22:13:39 CST success: [node1]
22:13:39 CST success: [node2]
22:13:39 CST success: [master]
22:13:39 CST [RepositoryModule] Sync repository iso file to all nodes
22:13:47 CST success: [master]
22:13:47 CST success: [node2]
22:13:47 CST success: [node1]
22:13:47 CST [RepositoryModule] Mount iso file
22:13:47 CST success: [node2]
22:13:47 CST success: [node1]
22:13:47 CST success: [master]
22:13:47 CST [RepositoryModule] Backup original repository
22:13:47 CST success: [node1]
22:13:47 CST success: [node2]
22:13:47 CST success: [master]
22:13:47 CST [RepositoryModule] Add local repository
22:13:48 CST stdout: [master]
Loaded plugins: fastestmirror
Cleaning repos: base-local
Cleaning up list of fastest mirrors
Other repos take up 448 M of disk space (use –verbose for details)
Loaded plugins: fastestmirror
Determining fastest mirrors
base-local | 2.9 kB 00:00
(⅓): base-local/filelists_ | 100 kB 00:00
(⅔): base-local/other_db | 87 kB 00:00
(3/3): base-local/primary_db | 188 kB 00:00
Metadata Cache Created
22:13:48 CST stdout: [node2]
Loaded plugins: fastestmirror
Cleaning repos: base-local
Cleaning up list of fastest mirrors
Other repos take up 429 M of disk space (use –verbose for details)
Loaded plugins: fastestmirror
Determining fastest mirrors
base-local | 2.9 kB 00:00
(⅓): base-local/filelists_ | 100 kB 00:00
(⅔): base-local/other_db | 87 kB 00:00
(3/3): base-local/primary_db | 188 kB 00:00
Metadata Cache Created
22:13:48 CST stdout: [node1]
Loaded plugins: fastestmirror
Cleaning repos: base-local
Cleaning up list of fastest mirrors
Other repos take up 429 M of disk space (use –verbose for details)
Loaded plugins: fastestmirror
Determining fastest mirrors
base-local | 2.9 kB 00:00
(⅓): base-local/filelists_ | 100 kB 00:00
(⅔): base-local/other_db | 87 kB 00:00
(3/3): base-local/primary_db | 188 kB 00:00
Metadata Cache Created
22:13:48 CST success: [master]
22:13:48 CST success: [node2]
22:13:48 CST success: [node1]
22:13:48 CST [RepositoryModule] Install packages
22:13:48 CST stdout: [node1]
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
Package 1:openssl-1.0.2k-22.el7_9.x86_64 already installed and latest version
Package socat-1.7.3.2-2.el7.x86_64 already installed and latest version
Package conntrack-tools-1.4.4-7.el7.x86_64 already installed and latest version
Package ipset-7.1-1.el7.x86_64 already installed and latest version
Package ebtables-2.0.10-16.el7.x86_64 already installed and latest version
Package chrony-3.4-1.el7.x86_64 already installed and latest version
Nothing to do
22:13:48 CST stdout: [master]
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
Package 1:openssl-1.0.2k-22.el7_9.x86_64 already installed and latest version
Package socat-1.7.3.2-2.el7.x86_64 already installed and latest version
Package conntrack-tools-1.4.4-7.el7.x86_64 already installed and latest version
Package ipset-7.1-1.el7.x86_64 already installed and latest version
Package ebtables-2.0.10-16.el7.x86_64 already installed and latest version
Package chrony-3.4-1.el7.x86_64 already installed and latest version
Nothing to do
22:13:48 CST stdout: [node2]
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
Package 1:openssl-1.0.2k-22.el7_9.x86_64 already installed and latest version
Package socat-1.7.3.2-2.el7.x86_64 already installed and latest version
Package conntrack-tools-1.4.4-7.el7.x86_64 already installed and latest version
Package ipset-7.1-1.el7.x86_64 already installed and latest version
Package ebtables-2.0.10-16.el7.x86_64 already installed and latest version
Package chrony-3.4-1.el7.x86_64 already installed and latest version
Nothing to do
22:13:48 CST success: [node1]
22:13:48 CST success: [master]
22:13:48 CST success: [node2]
22:13:48 CST [RepositoryModule] Reset repository to the original repository
22:13:48 CST success: [node1]
22:13:48 CST success: [node2]
22:13:48 CST success: [master]
22:13:48 CST [RepositoryModule] Umount ISO file
22:13:48 CST success: [master]
22:13:48 CST success: [node2]
22:13:48 CST success: [node1]
22:13:48 CST [NodeBinariesModule] Download installation binaries
22:13:48 CST message: [localhost]
downloading amd64 kubeadm v1.21.5 …
22:13:49 CST message: [localhost]
kubeadm is existed
22:13:49 CST message: [localhost]
downloading amd64 kubelet v1.21.5 …
22:13:50 CST message: [localhost]
kubelet is existed
22:13:50 CST message: [localhost]
downloading amd64 kubectl v1.21.5 …
22:13:50 CST message: [localhost]
kubectl is existed
22:13:50 CST message: [localhost]
downloading amd64 helm v3.6.3 …
22:13:50 CST message: [localhost]
helm is existed
22:13:50 CST message: [localhost]
downloading amd64 kubecni v0.9.1 …
22:13:51 CST message: [localhost]
kubecni is existed
22:13:51 CST message: [localhost]
downloading amd64 docker 20.10.8 …
22:13:51 CST message: [localhost]
docker is existed
22:13:51 CST message: [localhost]
downloading amd64 crictl v1.22.0 …
22:13:51 CST message: [localhost]
crictl is existed
22:13:51 CST message: [localhost]
downloading amd64 etcd v3.4.13 …
22:13:51 CST message: [localhost]
etcd is existed
22:13:51 CST success: [LocalHost]
22:13:51 CST [ConfigureOSModule] Prepare to init OS
22:13:52 CST success: [node2]
22:13:52 CST success: [master]
22:13:52 CST success: [node1]
22:13:52 CST [ConfigureOSModule] Generate init os script
22:13:52 CST success: [node1]
22:13:52 CST success: [node2]
22:13:52 CST success: [master]
22:13:52 CST [ConfigureOSModule] Exec init os script
22:13:52 CST stdout: [node2]
setenforce: SELinux is disabled
Disabled
net.ipv6.conf.eth0.accept_dad = 0
net.ipv6.conf.eth0.accept_ra = 1
net.ipv6.conf.eth0.accept_ra_defrtr = 1
net.ipv6.conf.eth0.accept_ra_rtr_pref = 1
net.ipv6.conf.eth0.accept_ra_rt_info_max_plen = 1
net.ipv4.ip_forward = 1
net.bridge.bridge-nf-call-arptables = 1
net.bridge.bridge-nf-call-ip6tables = 1
net.bridge.bridge-nf-call-iptables = 1
net.ipv4.ip_local_reserved_ports = 30000-32767
vm.max_map_count = 262144
vm.swappiness = 1
fs.inotify.max_user_instances = 524288
kernel.pid_max = 65535
22:13:52 CST stdout: [node1]
setenforce: SELinux is disabled
Disabled
net.ipv6.conf.eth0.accept_dad = 0
net.ipv6.conf.eth0.accept_ra = 1
net.ipv6.conf.eth0.accept_ra_defrtr = 1
net.ipv6.conf.eth0.accept_ra_rtr_pref = 1
net.ipv6.conf.eth0.accept_ra_rt_info_max_plen = 1
net.ipv4.ip_forward = 1
net.bridge.bridge-nf-call-arptables = 1
net.bridge.bridge-nf-call-ip6tables = 1
net.bridge.bridge-nf-call-iptables = 1
net.ipv4.ip_local_reserved_ports = 30000-32767
vm.max_map_count = 262144
vm.swappiness = 1
fs.inotify.max_user_instances = 524288
kernel.pid_max = 65535
22:13:53 CST stdout: [master]
setenforce: SELinux is disabled
Disabled
net.ipv6.conf.eth0.accept_dad = 0
net.ipv6.conf.eth0.accept_ra = 1
net.ipv6.conf.eth0.accept_ra_defrtr = 1
net.ipv6.conf.eth0.accept_ra_rtr_pref = 1
net.ipv6.conf.eth0.accept_ra_rt_info_max_plen = 1
net.ipv4.ip_forward = 1
net.bridge.bridge-nf-call-arptables = 1
net.bridge.bridge-nf-call-ip6tables = 1
net.bridge.bridge-nf-call-iptables = 1
net.ipv4.ip_local_reserved_ports = 30000-32767
vm.max_map_count = 262144
vm.swappiness = 1
fs.inotify.max_user_instances = 524288
kernel.pid_max = 65535
22:13:53 CST success: [node2]
22:13:53 CST success: [node1]
22:13:53 CST success: [master]
22:13:53 CST [ConfigureOSModule] configure the ntp server for each node
22:13:53 CST skipped: [node2]
22:13:53 CST skipped: [node1]
22:13:53 CST skipped: [master]
22:13:53 CST [KubernetesStatusModule] Get kubernetes cluster status
22:13:53 CST success: [master]
22:13:53 CST [InstallContainerModule] Sync docker binaries
22:13:53 CST skipped: [master]
22:13:53 CST skipped: [node2]
22:13:53 CST skipped: [node1]
22:13:53 CST [InstallContainerModule] Generate containerd service
22:13:53 CST skipped: [master]
22:13:53 CST skipped: [node2]
22:13:53 CST skipped: [node1]
22:13:53 CST [InstallContainerModule] Enable containerd
22:13:53 CST skipped: [master]
22:13:53 CST skipped: [node2]
22:13:53 CST skipped: [node1]
22:13:53 CST [InstallContainerModule] Generate docker service
22:13:53 CST skipped: [master]
22:13:53 CST skipped: [node2]
22:13:53 CST skipped: [node1]
22:13:53 CST [InstallContainerModule] Generate docker config
22:13:53 CST skipped: [master]
22:13:53 CST skipped: [node1]
22:13:53 CST skipped: [node2]
22:13:53 CST [InstallContainerModule] Enable docker
22:13:53 CST skipped: [master]
22:13:53 CST skipped: [node2]
22:13:53 CST skipped: [node1]
22:13:53 CST [InstallContainerModule] Add auths to container runtime
22:13:53 CST success: [master]
22:13:53 CST success: [node1]
22:13:53 CST success: [node2]
22:13:53 CST [PushModule] Push images to private registry
22:13:56 CST message: [LocalHost]
push image dockerhub.kubekey.local/kubesphereio/alertmanager:v0.21.0 failed: manifest-sha256:913293083cb14085bfc01018bb30d1dcbbc9ed197ae21ef2ca917b0d29265198: waiting |————————————–|
layer-sha256:626a2a3fee8c6a9b5b866adc6cb15d54b5d901b6a084a2519bf7f905325b0711: waiting |————————————–|
layer-sha256:518f5393dbbc3263d91649c9ec3d203190803d4b4eef0b941da0315a02bba151: waiting |————————————–|
layer-sha256:addd0e4e1dc5b43938da068f0f7e0c8a075678fbbfebd568cd3ee628441d3d35: waiting |————————————–|
layer-sha256:012b22e92c79d65c693d5318ae75e639d2927f757fee1d4f42caf2061da2a89f: waiting |————————————–|
config-sha256:c876f5897d7b07a19836227e26de9053c4ae14c114e43635df6fdb4a4b251ba6: waiting |————————————–|
layer-sha256:74ad1ee664e622ec991fd498f26e99f8416af162f2bca26e40ab9ec08abf9ad0: waiting |————————————–|
layer-sha256:0f8c40e1270f10d085dda8ce12b7c5b17cd808f055df5a7222f54837ca0feae0: waiting |————————————–|
elapsed: 0.1 s total: 0.0 B (0.0 B/s)
ctr: unexpected response: 401 Unauthorized
: exit status 1
22:13:56 CST failed: [LocalHost]
error: Pipeline[CreateClusterPipeline] execute failed: Module[PushModule] exec failed:
failed: [LocalHost] [PushImages] exec failed after 1 retires: push image dockerhub.kubekey.local/kubesphereio/alertmanager:v0.21.0 failed: manifest-sha256:913293083cb14085bfc01018bb30d1dcbbc9ed197ae21ef2ca917b0d29265198: waiting |————————————–|
layer-sha256:626a2a3fee8c6a9b5b866adc6cb15d54b5d901b6a084a2519bf7f905325b0711: waiting |————————————–|
layer-sha256:518f5393dbbc3263d91649c9ec3d203190803d4b4eef0b941da0315a02bba151: waiting |————————————–|
layer-sha256:addd0e4e1dc5b43938da068f0f7e0c8a075678fbbfebd568cd3ee628441d3d35: waiting |————————————–|
layer-sha256:012b22e92c79d65c693d5318ae75e639d2927f757fee1d4f42caf2061da2a89f: waiting |————————————–|
config-sha256:c876f5897d7b07a19836227e26de9053c4ae14c114e43635df6fdb4a4b251ba6: waiting |————————————–|
layer-sha256:74ad1ee664e622ec991fd498f26e99f8416af162f2bca26e40ab9ec08abf9ad0: waiting |————————————–|
layer-sha256:0f8c40e1270f10d085dda8ce12b7c5b17cd808f055df5a7222f54837ca0feae0: waiting |————————————–|
elapsed: 0.1 s total: 0.0 B (0.0 B/s)
ctr: unexpected response: 401 Unauthorized
: exit status 1
请问有什么方法可以解决?