Q. How do I change my hostname under OpenBSD operating system?
A. The hostname command displays the name of the current host. The superuser (root) can set the host name by editing a /etc/myname file. This is used at system boot time by netstart to initialize the hostname.
Task: OpenBSD Display hostname
Type the any one of the following command
# hostname
# cat /etc/myname
Output:
openbsd.nixcraft.in
Task: OpenBSD Chane Host Name
Simply login as root and type the following command:
# echo "new-hostname.domain.com" > /etc/myname
# echo "server.nixcraft.in" > /etc/myname
# echo 'unixbox' > /etc/myname
Featured Articles:
- 20 Linux System Monitoring Tools Every SysAdmin Should Know
- 20 Linux Server Hardening Security Tips
- My 10 UNIX Command Line Mistakes
- Linux: 20 Iptables Examples For New SysAdmins

- 25 PHP Security Best Practices For Sys Admins
- The Novice Guide To Buying A Linux Laptop
- 10 Greatest Open Source Software Of 2009
- Top 5 Email Client For Linux, Mac OS X, and Windows Users
- Top 20 OpenSSH Server Best Security Practices
- Top 10 Open Source Web-Based Project Management Software
- Top 5 Linux Video Editor Software
Facebook it - Tweet it - Print it -

