k8s 常用命令
[root@master ~]# kubectl get nodes
NAME STATUS ROLES AGE VERSION master Ready master 1h v1.8.1 node1 Ready <none> 1h v1.8.1 node2 Ready <none> 1h v1.8.1
[root@master network]# kubectl get po --all-namespaces
NAMESPACE NAME READY STATUS RESTARTS AGE kube-system etcd-master / Running 3m kube-system kube-apiserver-master / Running 4m kube-system kube-controller-manager-master / Running 4m kube-system kube-dns-545bc4bfd4-kvvg2 / Running 4m kube-system kube-flannel-ds-djdp4 / Running 21s kube-system kube-flannel-ds-mb75s / Running 1m kube-system kube-flannel-ds-sxpkq / Running 18s kube-system kube-proxy-6s8wz / Running 21s kube-system kube-proxy-d4snf / Running 4m kube-system kube-proxy-lnxfv / Running 18s kube-system kube-scheduler-master / Running 4m
kubectl get svc
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE kubernetes ClusterIP 10.96.0.1 <none> /TCP 8m
kubectl logs -f kubernetes-dashboard-759ccc86d9-svmlk --namespace=kube-system
// :: Starting overwatch // :: Using in-cluster config to connect to apiserver // :: Using service account token for csrf signing // :: No request provided. Skipping authorization // :: Successful initial request to the apiserver, version: v1.8.2 // :: New synchronizer has been registered: kubernetes-dashboard-key-holder-kube-system. Starting // :: Starting secret synchronizer for kubernetes-dashboard-key-holder in namespace kube-system // :: Generating JWE encryption key // :: Storing encryption key in a secret // :: Creating in-cluster Heapster client // :: Metric client health check failed: the server could not find the requested resource (get services heapster). Retrying in seconds. // :: Serving insecurely on HTTP port: // :: Metric client health check failed: the server could not find the requested resource (get services heapster). Retrying in seconds. // :: Metric client health check failed: the server could not find the requested resource (get services heapster). Retrying in seconds. // :: Metric client health check failed: the server could not find the requested resource (get services heapster). Retrying in seconds. // :: Metric client health check failed: the server could not find the requested resource (get services heapster). Retrying in seconds.
kubectl get pods -n kube-system -o wide
NAME READY STATUS RESTARTS AGE IP NODE etcd-master / Running 7m 10.10.6.11 master kube-apiserver-master / Running 8m 10.10.6.11 master kube-controller-manager-master / Running 8m 10.10.6.11 master kube-dns-545bc4bfd4-kvvg2 / Running 8m 10.96.0.2 master kube-flannel-ds-djdp4 / Running 4m 10.10.6.13 node2 kube-flannel-ds-mb75s / Running 5m 10.10.6.11 master kube-flannel-ds-sxpkq / Running 4m 10.10.6.12 node1 kube-proxy-6s8wz / Running 4m 10.10.6.13 node2 kube-proxy-d4snf / Running 8m 10.10.6.11 master kube-proxy-lnxfv / Running 4m 10.10.6.12 node1 kube-scheduler-master / Running 8m 10.10.6.11 master kubernetes-dashboard-759ccc86d9-svmlk / Running 2m 10.96.2.2 node1
kubectl get svc --all-namespaces
NAMESPACE NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE default kubernetes ClusterIP 10.96.0.1 <none> /TCP 1h kube-system kube-dns ClusterIP 10.96.0.10 <none> /UDP,/TCP 1h kube-system kubernetes-dashboard NodePort 10.104.11.151 <none> :/TCP 1h [root@master ~]#
k8s 常用命令的更多相关文章
- [转帖] K8S 常用命令
k8s常用命令 原贴地址 查看集群信息: [root@kubernetes-master pods]# kubectl cluster-info kubectl cluster-info展示结果 k ...
- K8s常用命令操作
K8s常用命令操作 一.kubectl命令补全 1.master安装命令补全,并临时生效 yum install -y bash-completion source /usr/share/bash-c ...
- k8s常用命令
K8s一些命令:通过yaml文件创建:kubectl create -f xxx.yaml (不建议使用,无法更新,必须先delete)kubectl apply -f xxx.yaml (创建+更新 ...
- k8s常用命令记录
目录 kubectl常用命令 kubectl get pod -n dev 查看日志 查看pod详情 删除pod 删除job 进入pod里面 查看namespace 创建namespace 删除nam ...
- k8s 常用命令汇集
通过yaml文件创建: kubectl create -f xxx.yaml (不建议使用,无法更新,必须先delete) kubectl apply -f xxx.yaml (创建+更新,可以重复使 ...
- k8s常用命令演示
kubectl run --image=xxx name_xx --port kubectl run --image=nginx nginx-app --port=80 kubectl expose ...
- ARTS-S k8s常用命令
本地访问minikube的docker eval $(minikube docker-env) 删除statefulset kubectl delete statefulset web --casca ...
- k8s常用操作命令
K8s常用命令操作 一.kubectl命令补全 .master安装命令补全,并临时生效 yum install -y bash-completion source /usr/share/bash-co ...
- 使用kubectl管理Kubernetes(k8s)集群:常用命令,查看负载,命名空间namespace管理
目录 一.系统环境 二.前言 三.kubectl 3.1 kubectl语法 3.2 kubectl格式化输出 四.kubectl常用命令 五.查看kubernetes集群node节点和pod负载 5 ...
随机推荐
- ScrollView嵌套ListView冲突问题的最优解决方式
项目做多了之后.会发现事实上ScrollView嵌套ListVew或者GridView等非经常常使用,可是你也会发现各种奇怪问题产生.依据个人经验如今列出常见问题以及代码最少最简单的解决方法. 问题一 ...
- silverlight RadGridView总结二(转载)
系列二 实现RadGridView行中添加不同控件,并在控件中绑定不同的数据源 先上一段前台代码 <telerik:RadGridView Grid.Row="2" ...
- mongo views
db.itemsView.drop(); db.items.aggregate([ { "$match": { "status": "true&quo ...
- Spring Boot(五):Spring Boot的启动器Starter大全及自定义Starter
现有启动器Starter目录 Spring Boot应用启动器基本的一共有44种,具体如下: 1)spring-boot-starter 这是Spring Boot的核心启动器,包含了自动配置.日志和 ...
- Google I/O 2014 大会总结 Android开发新方向
昨天晚上,Google I/O 2014大会召开,会上主要展示了下面几个部分的创新内容: Android L 操作系统 首先是界面,谷歌又一次设计了一套 UI 规范.并称之为"Materia ...
- Atitit.软件开发的非功能性需求attilax 总结
Atitit.软件开发的非功能性需求attilax 总结 1. 运行环境约束:用户对软件系统运行环境的要求. 1 2. 兼容性 2 3. 7.6 数据库 database (imp by ati) ...
- Android开发系列之创建自定义控件
Android开发过程中我们经常需要定义自己的控件,一方面基于复用的角度考虑,一方面也是基于逻辑处理思维的角度考虑.在这篇博客里面,笔者想要介绍.总结几种Android自定义控件的方法,如果有什么不对 ...
- 游戏引擎 Unity 的入门易精通难体现在哪?为什么?
04月212014年 [王楠的回答(37票)]: 为什么入门简单,看一下官网的文档和视频教程就知道了,看完几段视频和例子就能让初学者做出能玩的东西,其他同类商业引擎都做不到.物体+组件的结构,所见 ...
- Audiosink design
Audiosink的设计,需要满足下列一些需求: 良好的chain_based 支持.绝大多数简单playback pipelines都是将音频数据从decoder直接push给audiosink; ...
- [已解决]pycharm报错:AttributeError: module 'pip' has no attribute 'main'
> 更新pip后,pycharm更新模块报错,经过一番查找,现提供两种解决办法. 报错片段信息如下: AttributeError: module 'pip' has no attribute ...