Hai
Hai

Reputation: 21

How to permanenty save sub interface IP (logic/virual interface) on solaris

I am using Solaris 10. I want to add sub interface (including ip and mask) and save it to keep it when server reboot (Ex: Bge0:1, Bge0:2...)

General, I am use NetConf to add sub interface and assign iP for it, but it is too long for add multiple Interfaces.

Is there other way to do it like creating a file and runing it. Thanks.

Upvotes: 0

Views: 324

Answers (1)

Romeo Ninov
Romeo Ninov

Reputation: 7255

Add in /etc files like hostname.bge0:1 and so on with appropriate information

yourhostname netmask + broadcast + up 

Also you need to add in /etc/hosts pairs for those hostnames

<your IP> yourhostname 

Then plumb the interface

ifconfig bge0:1 plumb

and then up it

ifconfig bge0:1 `cat /etc/hostname.bge0:1`

Do not forget to add appropriate netmask record in /etc/netmasks

<your IP network> <your IP network netmask>

Upvotes: 0

Related Questions