Home 修改本机hostnamechangehostnameinlinux
Post
Cancel

修改本机hostnamechangehostnameinlinux

Run this command in Terminal:

$ sudo scutil --set HostName larryx.local

This is also helpful if you’re in Terminal and have a really long hostname at your prompt. If you want to view your current hostname, run this command in Terminal:

$ hostname

This post is licensed under CC BY 4.0 by the author.