Allow scheduling of pods on Kubernetes master?

前端 未结 8 777
逝去的感伤
逝去的感伤 2020-12-03 06:54

I set up Kubernetes on CoreOS on bare metal using the generic install scripts. It\'s running the current stable release, 1298.6.0, with Kubernetes version 1.5.4.

We\

相关标签:
8条回答
  • 2020-12-03 07:44

    For anyone using kops on AWS. I wanted to enable scheduling of Pods on master.

    $ kubectl get nodes -owide was giving me this output:

    NAME                                          STATUS
    ...
    ...
    ip-1**-**-**-***.********.compute.internal    Ready                      node
    ip-1**-**-**-***.********.master.internal     Ready,SchedulingDisabled   master
                                                        ^^^^^^^^^^^^^^^^^^
    ip-1**-**-**-***.********.compute.internal    Ready                      node
    ...
    ...
    

    And $ kubectl describe nodes ip-1**-**-**-***.********.master.internal:

    ...
    ...
    Taints:             <none>
    Unschedulable:      true
    ...                 ^^^^
    ...
    

    Patching the master with this command:

    $ kubectl patch node MASTER_NAME -p "{\"spec\":{\"unschedulable\":false}}"

    worked for me and scheduling of Pods is now enabled.

    Ref: https://github.com/kubernetes/kops/issues/639#issuecomment-287015882

    0 讨论(0)
  • 2020-12-03 07:46

    If you are using Kubernetes 1.7 and above:

    kubectl taint node mymasternode node-role.kubernetes.io/master:NoSchedule-
    
    0 讨论(0)
提交回复
热议问题