How to change hostname and ip in solaris | Unix Linux Forums | IP Networking

  Go Back    


IP Networking Learn TCP/IP, Internet Protocol, Routing, Routers, Network protocols in this UNIX and Linux forum.

How to change hostname and ip in solaris

IP Networking


Closed Thread    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 05-27-2002
PennyLi PennyLi is offline
Registered User
 
Join Date: May 2002
Last Activity: 6 December 2002, 6:55 AM EST
Location: Hong Kong
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
How to change hostname and ip in solaris

Dear all, I am going to change the IP address and hostname in my solaris, but I don't know how to do it.

If you have any idea or suggestion, please fell free to let me know.

Thanks and Regards
Sponsored Links
    #2  
Old 05-27-2002
killerserv's Avatar
killerserv killerserv is offline Forum Advisor  
Registered User
 
Join Date: Dec 2000
Last Activity: 22 January 2014, 10:05 AM EST
Location: Phoenix, AZ
Posts: 670
Thanks: 0
Thanked 3 Times in 3 Posts
The files that set hostname and IP address are always in /etc
(Solaris: /etc/inet/hosts)
Solaris has commands sys-unconfig, sysidconfig, and friends for when you really want to unconfigure/reconfigure a host
But back to the modest change-the-hostname task, Files to edit:

/etc/hostname.<interface-name> (hme0, le0, ...)
/etc/nodename
/etc/defaultrouter
/etc/netmasks (maybe)
/etc/net/ticlts/hosts (optional)
/etc/net/ticots/hosts (optional)
/etc/net/ticotsord/hosts (optional)

Now when you reboot, the host should come up with its new name and/or IP address.
If the machine has any possibly-delicate services that it provides (e.g. sendmail on your main mail server), you might want to disable these (take the relevant symlinks out of /etc/rc2.d before rebooting. Give a try do post back the results.
Sponsored Links
    #3  
Old 06-04-2002
linuxpenguin's Avatar
linuxpenguin linuxpenguin is offline Forum Advisor  
Registered User
 
Join Date: May 2002
Last Activity: 28 March 2014, 4:09 PM EDT
Location: India
Posts: 350
Thanks: 0
Thanked 5 Times in 5 Posts
Re: How to change hostname and ip in solaris

Hi

To be on the safest side i have a few tips for you. Remember one thing that all the host settings are generally in the files /etc

so what you can do is, execute the following command

find . -exec grep `hostname` -print {} \; 2>/dev/null

The first column of the output is the list of all the files which need to be changed.

However i guess that the commands provided by the system are a more elegant way to do this all. Just a experiment, let me know that when you have executed the system commands do the files that you get from the list above get updated. Please let me know this.

rgds
penguin
Sponsored Links
Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
change hostname end ip adresse in solaris 9 lid-j-one Solaris 2 11-04-2008 03:39 PM
Change hostname in Solaris 9 shabu Solaris 6 06-02-2007 03:41 PM
Solaris - unknown hostname - how can I change hostname? XNOR UNIX for Dummies Questions & Answers 1 03-29-2007 10:52 PM



All times are GMT -4. The time now is 05:17 AM.