-
Notifications
You must be signed in to change notification settings - Fork 154
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d6fe7d6
commit d2fb2f4
Showing
12 changed files
with
102 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
source/kubernetes/concepts/scheduling/node_pressure_eviction.rst
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
.. _node_pressure_eviction: | ||
|
||
========================= | ||
节点压力驱逐 | ||
========================= | ||
|
||
节点压力驱逐(node pressure eviction) 是 ``kubelet`` 主动终止Pod以回收节点上资源的过程。Kubelet监控集群节点的内存、磁盘空间和文件系统inode等资源,当这些资源的一个或多个达到特定消耗水平,kubelet可以主动使节点上的一个或多个Pod失效以回收资源。 | ||
|
||
kubelet 使用各种参数来做出驱逐决定: | ||
|
||
- 驱逐信号 | ||
- 驱逐条件 | ||
- 监控间隔 | ||
|
||
|
||
参考 | ||
====== | ||
|
||
- `Kubernetes 文档 / 概念 / 调度、抢占和驱逐 / 节点压力驱逐 <https://kubernetes.io/zh-cn/docs/concepts/scheduling-eviction/node-pressure-eviction/>`_ | ||
- `Under Disk Pressure <https://neilcameronwhite.medium.com/under-disk-pressure-34b5ba4284b6>`_ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
curl -s "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh" | bash |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
51 changes: 51 additions & 0 deletions
51
source/kubernetes/kubeflow/install_kubeflow_single_command.rst
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
.. _install_kubeflow_single_command: | ||
|
||
================================== | ||
单条命令安装kubeflow | ||
================================== | ||
|
||
准备工作 | ||
========= | ||
|
||
- 使用默认 :ref:`k8s_storage` : Provisioner种类其实不多,我考虑使用以下几种类型: | ||
|
||
- :ref:`cephfs` | ||
- :ref:`linux_iscsi` | ||
- :ref:`nfs` | ||
- :ref:`ceph_rbd` | ||
- :ref:`k8s_local` | ||
|
||
- :ref:`kustomize` 5.0.3 以上: | ||
|
||
.. literalinclude:: ../deploy/kustomize/install_kustomize_script | ||
:caption: 官方二进制安装脚本执行(需要非常畅通的网络),在当前目录下对应OS的 ``kustomize`` | ||
|
||
- ``kubectl`` | ||
|
||
安装 | ||
======== | ||
|
||
- clone下仓库并进入 ``apps`` 目录: | ||
|
||
.. literalinclude:: install_kubeflow_single_command/install_kubeflow | ||
:language: bash | ||
:caption: 单条命令安装kubeflow | ||
|
||
.. note:: | ||
|
||
安装是如此简洁,令人击节赞叹...我厂的软件交付... | ||
|
||
- 完成安装后,可能需要等待一些时间让所有的pods就绪,可以通过以下命令来确认: | ||
|
||
.. literalinclude:: install_kubeflow_single_command/check_kubeflow | ||
:language: bash | ||
:caption: 检查是否所有安装的 ``kubeflow`` 相关Pods就绪 | ||
|
||
.. note:: | ||
|
||
我在 :ref:`y-k8s` 部署的虚拟机中采用了极小化的虚拟磁盘,遇到一个尴尬的问题就是 :ref:`node_pressure_eviction` ,也就是磁盘空间不足导致运行Pod被驱逐。在上述Pods检测就绪发现存在问题时,通过 :ref:`ceph_extend_rbd_drive_with_libvirt_xfs` 实现扩容解决 | ||
|
||
参考 | ||
===== | ||
|
||
- `Kubeflow Manifests: Install with a single command <https://github.com/kubeflow/manifests#install-with-a-single-command>`_ |
7 changes: 7 additions & 0 deletions
7
source/kubernetes/kubeflow/install_kubeflow_single_command/check_kubeflow
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
kubectl get pods -n cert-manager | ||
kubectl get pods -n istio-system | ||
kubectl get pods -n auth | ||
kubectl get pods -n knative-eventing | ||
kubectl get pods -n knative-serving | ||
kubectl get pods -n kubeflow | ||
kubectl get pods -n kubeflow-user-example-com |
5 changes: 5 additions & 0 deletions
5
source/kubernetes/kubeflow/install_kubeflow_single_command/install_kubeflow
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
git clone git@github.com:kubeflow/manifests.git | ||
cd manifests | ||
|
||
# 只需要以下单一命令进行安装 | ||
while ! kustomize build example | kubectl apply -f -; do echo "Retrying to apply resources"; sleep 10; done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
.. _k8s_local: | ||
|
||
============================= | ||
在Kubernetes中部署local存储 | ||
Kubernetes local存储 | ||
============================= | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters