
How do I change the hostname in Solaris 9?Dave, I have just purchased your book Solaris 9 for Dummies to help me learn the OS. I have been accustomed to the rubbish Windows XP Pro system and fed up with crashes and the rest of the multitude of problems that are inherent to Windows therefore I purchased a Sun Ultra 5 workstation (refurbished) and really want to get to know it and how to use it. Thanks for your note and for buying my Solaris book. True confession time, though: subsequent to writing that book, I have loaned out my Solaris Blade system to a colleague for a research project, so I actually don't have an Solaris 9 box available to test out my answer. However, it's pretty straightforward nonetheless. Your first step is to become root, which you should be able to do by using either the sudo or su root command. Try both, one will work (I prefer the former, personally). Once you've done that, move into the /etc directory and use a combination of find and grep to see what files contain the name "alfred": find . -type f -print | xargs grep -i alfred I'm sure it'll be in at least /etc/hosts, /etc/nodename and /etc/hostname.xxx (where 'xxx' is your network interface name, like en0 or hme0). It's possible that it might also appear in any of the following too: /etc/net/ticlts/hosts, /etc/net/ticots/hosts, /etc/net/ticotsord/hosts and /etc/inet/ipnodes. Anywhere you find "alfred", change it to the hostname of your choice. Don't use spaces or punctuation in the name, however, to ensure that no Solaris applications trip up or get confused. That should do the trick. Reboot and you should have re-christened your Solaris 9 system with a new hostname!
Help others find this article at Del.icio.us, Digg, Netscape, Reddit, and Simpy.
Categorized:
Unix and Linux Help
(Article 3897)
Tagged: Previous: SSH Tunnels? How do I use an ssh tunnel to secure my email? Next: Why aren't my favicons displayed? Subscribe!
Never miss another useful Q&A article again! Subscribe to AskDaveTaylor with Google Reader.
Rather amazingly, there are no comments on this article yet.
I have a lot to say, but ...
I do have a comment, now that you mention it!
|
Search
Find just the answers you seek from among our 1700+ free tech support articles by using our Lijit search engine.
Help!
Subscribe to
Ask Dave Taylor!
Free Updates!
Sign up and get free weekly updates and special offers on books, seminars, workshops and more.
Articles and Reviews
Auctions and Online Shopping Blogs and RSS Feeds Building Web site traffic Business and Management Cell Phones and Mobile Phones CGI Scripts and Web Site Programming Computer and Internet Basics d) None of the Above HTML and CSS Mac OS X Help MySpace, Facebook, Twitter and Social Network Help Pay Per Click (PPC) Search Engine Optimization Shell Script Programming Sony PSP, MP3 Players, Etc. The Writing Business Unix and Linux Help Video Game Tips and Help Windows Help
Recent Entries
Join the List!
Book Links
|