How to change the linux hostname?


# hostname
test.com

# hostname server.com

# hostname
server.com

# vi /etc/hostname
server.com

Now restart and see the changes.

No comments: