平凡的码农

Home Archives
2019-06-01

hostname设置

hostnamectl set-hostname ‘k8smaster’
这样设置后仅仅/etc/hostname里面有了

/etc/hosts里面依然要设置,否则ssh k8smaster依然不work, k8smaster是本机名

如果采用clone vm的方式搭建集群的话,clone后需要重新设置hostname,etc/hosts还有固定ip(/etc/sysconfig/network-script/ifcfg-xxx)

最后的结果是/etc/hostname里面各自的ip,/etc/hosts里面三个机器一样的,包括windows就是4个机器一样的

Share
  • linux
Newer
ssh password-less
Older
update timezone

Tags

  • AI
  • IO
  • OS
  • automation
  • cloud
  • database
  • docker
  • dubbo
  • git
  • grpc
  • hadoop
  • hardware
  • hbase
  • istio
  • java
  • javascript
  • jvm
  • kafka
  • kubernetes
  • linux
  • maven
  • microservices
  • mongodb
  • mysql
  • nodejs
  • powershell
  • python
  • react
  • redis
  • search
  • security
  • spark
  • spring
  • spring-boot
  • tomcat
  • win10
  • zookeeper
  • 网络

Tag Cloud

AI IO OS automation cloud database docker dubbo git grpc hadoop hardware hbase istio java javascript jvm kafka kubernetes linux maven microservices mongodb mysql nodejs powershell python react redis search security spark spring spring-boot tomcat win10 zookeeper 网络

Archives

  • November 2021
  • July 2021
  • June 2021
  • March 2021
  • July 2020
  • June 2020
  • May 2020
  • March 2020
  • February 2020
  • January 2020
  • October 2019
  • August 2019
  • July 2019
  • June 2019
  • May 2019
  • April 2019
  • March 2019
  • February 2019
  • January 2019
  • December 2018

Recent Posts

  • microservice basics
  • BOM dependency vs Parent Dependancy in Maven
  • machine learning basic
  • k8s pv
  • kafka leader选举
© 2021 xu, hang
Powered by Hexo
Home Archives