HowTo: Change IP Address in Solaris 10 without reboot
Posted on Nov 20, 2007 under Networking, Solaris |Tags:ip-address Solaris solaris-10   
Adding or editing the IP address on a Solaris 10 server is different from the previous versions of the OS (Solaris 9, Solaris 8 etc).
In the previous versions of the Solaris Operating System, you need to edit the /etc/hosts file and add/edit the entry for the IP address and the hostname.
Example:
192.168.1.1 sun1
However, in Solaris 10, you should edit the /etc/hosts file (a symlink to /etc/inet/hosts file) and the /etc/inet/ipnodes file and add an entry for IP address and hostname.
Once done, restart the Network service using
# svcadm restart network/physical
or reboot the server for the changes to take effect.
Although, the /etc/inet/ipnodes files is primarily for IPv6 only, without adding an entry to the file, the IP address (IPv4) doesn't become active. This seems to be a known problem but the good news is this is now fixed in the Solaris 10 U4 (08/07 build).
Also, ensure that the /etc/netmasks file with the network ID and the netmask.
If you're new here, you may want to subscribe to my RSS feed. Thanks for visiting!


by Larry Breyer, on February 22 2008 @ 12:46 pm
You make no mention of /etc/defaultrouter. Why is that?
by admin, on February 22 2008 @ 12:58 pm
You need to change the Default router only if the gateway changes. In other words, if the server is moved to a new subnet with a new Gateway then yes, default router needs to be changed.
I’ve written a seperate article for that
http://www.itsyourip.com/networking/howto-change-the-default-gateway-or-default-router-in-sun-solaris/
May be I should add a note to this article. Thanks for that. I’ll do that!
by Ifeatu, on October 13 2008 @ 3:40 am
Great, please modify the permissions on the hosts file to read & write before you start editing the file.