Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CentOS 7.2 1151 install AllInOne problem #354

Closed
xzzh999 opened this issue Nov 2, 2018 · 5 comments
Closed

CentOS 7.2 1151 install AllInOne problem #354

xzzh999 opened this issue Nov 2, 2018 · 5 comments

Comments

@xzzh999
Copy link

xzzh999 commented Nov 2, 2018

Hi~ Nice work!

When i follow the quick start step, and execute the kubectl version command, there were errors here:

[root@localhost ansible]# kubectl version
Client Version: version.Info{Major:"1", Minor:"12", GitVersion:"v1.12.1",
GitCommit:"4ed3216f3ec431b140b1d899130a69fc671678f4", 
GitTreeState:"clean", BuildDate:"2018-10-05T16:46:06Z",
 GoVersion:"go1.10.4", Compiler:"gc", Platform:"linux/amd64"}
The connection to the server localhost:8080 was refused - did you specify the right host or port?

and i just have modified the hosts file as follow:

# 'deploy' node, which the ansible-playbooks usually run on
# variable 'NTP_ENABLED(=yes/no)' enables/disables the NTP server 'chrony'
[deploy]
0.0.0.0 NTP_ENABLED=no

# 'etcd' cluster must have odd member(s) (1,3,5,...)
# variable 'NODE_NAME' is the distinct name of a member in 'etcd' cluster
[etcd]
0.0.0.0 NODE_NAME=etcd1

[kube-master]
0.0.0.0

[kube-node]
0.0.0.0

# variable NEW_INSTALL: 'yes' to setup a new harbor server; 'no' to integrate with existed one
[harbor]
#192.168.1.8 HARBOR_DOMAIN="harbor.yourdomain.com" NEW_INSTALL=no

# group reserved, add new 'kube-node' in it
[new-node]
#192.168.1.xx

[all:vars]
# --------- Main Variables ---------------
# Cluster Deployment Mode: allinone, single-master, multi-master
DEPLOY_MODE=allinone

# Versions supported: v1.8, v1.9, v1.10, v1.11, v1.12
K8S_VER="v1.12"

# Cluster's Master IP, auto generated
MASTER_IP="{{ groups['kube-master'][0] }}"
KUBE_APISERVER="https://{{ MASTER_IP }}:6443"

# Network plugins supported: calico, flannel, kube-router, cilium
CLUSTER_NETWORK="flannel"

# K8S Service CIDR, not overlap with node(host) networking
SERVICE_CIDR="10.68.0.0/16"

# Cluster CIDR (Pod CIDR), not overlap with node(host) networking
CLUSTER_CIDR="172.20.0.0/16"

# NodePort Range
NODE_PORT_RANGE="20000-40000"

# Kubernetes SVC IP (usually assigned with the first available IP of 'SERVICE_CIDR')
CLUSTER_KUBERNETES_SVC_IP="10.68.0.1"

# Cluster DNS Server's IP (assigned with an available IP of 'SERVICE_CIDR')
CLUSTER_DNS_SVC_IP="10.68.0.2"

# Cluster DNS Domain
CLUSTER_DNS_DOMAIN="cluster.local."

# Basic auth for apiserver
BASIC_AUTH_USER="admin"
BASIC_AUTH_PASS="test1234"

# -------- Additional Variables --------------------
# Binaries Directory
bin_dir="/opt/kube/bin"

# CA and other components cert/key Directory
ca_dir="/etc/kubernetes/ssl"

# Deploy Directory (kubeasz workspace), don't change the default value right now
base_dir="/etc/ansible"

My os is CentOS7.2 1151 x64, and it's pure clean, it's address is 80.0.0.245, and i'm new to k8s, need u help, thx.

@gjmzj
Copy link
Collaborator

gjmzj commented Nov 2, 2018

change 0.0.0.0 to a specific addr of the OS,and run ansible-playbook 90.setup.yml again

@xzzh999
Copy link
Author

xzzh999 commented Nov 2, 2018

Not working, reference to this, i also tried the command:
export KUBERNETES_MASTER=http://80.0.0.245:8080,
just the same errors:

[root@localhost ansible]# kubectl version
Client Version: version.Info{Major:"1",
 Minor:"12", GitVersion:"v1.12.1", GitCommit:"4ed3216f3ec431b140b1d899130a69fc671678f4", 
GitTreeState:"clean", BuildDate:"2018-10-05T16:46:06Z", 
GoVersion:"go1.10.4", Compiler:"gc", Platform:"linux/amd64"}
The connection to the server 80.0.0.245:8080 was
 refused - did you specify the right host or port?

@xzzh999
Copy link
Author

xzzh999 commented Nov 2, 2018

and when i execute ansible-playbook 90.setup.yml, there're not any info print, like ok or failed message, just silent end, i use the k8s.1-12-1.tar.gz and basic_images_kubeasz_0.3.tar.gz offline files.

@gjmzj
Copy link
Collaborator

gjmzj commented Nov 2, 2018

run ansible-playbook 99.clean.yml, or just use a new VM and start from the beginning.

@xzzh999
Copy link
Author

xzzh999 commented Nov 2, 2018

@gjmzj
It looks like is the pip install issue, i use pip install ansible, can install now, thanks again.

@xzzh999 xzzh999 closed this as completed Nov 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants