Solaris 10 – Change IP Address without reboot

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.

11 thoughts on “Solaris 10 – Change IP Address without reboot”

  1. Thanks for the above info!! would appreciate if someone could help me with below query.
    I have Solaris 10 installed in virtualbox 4. I have configured my network as mentioned in this post. I want to make a network between 2 solaris 10 systems installed in Virtualbox OR between solaris 10 and local windows xp (host machine). If you can guide and advise what steps to be performed to achieve target will be highly appreciated.

    Also, below are the details/query i would like to know/update.
    1) what will be my default gateway when my ip is 10.10.12.1?
    2) I am using virtualbox 4. I have enable NAT in network adapter.
    3) I have not defined router since confused with default gateway
    4) How can i connect to internet from solaris machine installed in Virtual box

    Thanks 🙂

  2. Ramachandran N

    I have to change the netmask of the interface without reboot, I changed in /etc/netmasks file and I used the following commands:

    ifconfig igb0 x.x.x.x netmasks newnetmask
    svcadm restart network/physical

    But no effect at all.

Leave a Comment

Your email address will not be published. Required fields are marked *