简体   繁体   English

hostnamectl 问题 系统尚未使用 systemd 作为 init 系统 (PID 1) 引导。 不能操作。 无法连接到总线:主机已关闭

[英]hostnamectl Problem System has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down

System has not been booted with systemd as init system (PID 1).系统尚未使用 systemd 作为 init system (PID 1) 引导。 Can't operate.不能操作。 Failed to connect to bus: Host is down无法连接到总线:主机已关闭

Unable change localhost name by this method and timezone?无法通过此方法和时区更改本地主机名称?

If you edit /etc/hostname , you can change your hostname to anything you want.如果您编辑/etc/hostname ,您可以将您的主机名更改为您想要的任何内容。

From this:由此:

localhost

To:至:

your-hostname-here

And then, you reboot the machine.然后,您重新启动机器。 Your new hostname SHOULD show up, and any services using that name must be routed to that IP address of that machine.您的新主机名应该出现,并且使用该名称的任何服务都必须路由到该机器的 IP 地址。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM