Remove a virtual interface in Solaris

Contributor Icon Contributed by qmchenry Date Icon October 3, 2003  
Tag Icon Tagged: Solaris networking

Solaris allows multiple virtual or logical interfaces to exist with different IP addresses on the same physical interface. Virtual interfaces are created or plumbed up using the plumb directive in ifconfig. They are unplumbed using the unplumb directive.


To remove the virtual interface eri1:7, run the following command as root:

ifconfig eri1:7 unplumb

See also: Create a virtual interface in Solaris

Previous recipe | Next recipe |
 
  • Anonymous
    to my experience, unplumbing a virtual interface will remove the real interface too.
    so it would be wise to just bring it down instead of unplumbing.
  • jhavard
    According to the <font color="orange">ifconfig man page</font>:


    To delete a logical interface, simply name the interface
    specifying an address of 0, after ensuring that the inter-
    face has been marked as "down". For example, the command:

    ifconfig le0:1 0 down
    will delete the logical interface le0:1.



    The previous comment is correct that unplumbing a logical interface in Solaris will unplumb the physical interface, as plumbing is a "physical" matter.
  • Anonymous
    On Solaris 8, you can remove the virtual interface by using removeif option of the ifconfig command :

    ifconfig <physical_interface> removeif <logical_address>

    for eg.:

    $ ifconfig -a
    lo0: flags=1000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4> mtu 8232 index 1
    inet 127.0.0.1 netmask ff000000
    bge0: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 3
    inet 1.2.31.216 netmask fffff800 broadcast 1.2.31.255
    bge0:1: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 3
    inet 1.2.31.24 netmask fffff800 broadcast 1.2.31.255

    # ifconfig bge0 removeif 1.2.31.26

    $ ifconfig -a
    lo0: flags=1000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4> mtu 8232 index 1
    inet 127.0.0.1 netmask ff000000
    bge0: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 3
    inet 1.2.31.216 netmask fffff800 broadcast 1.2.31.255
blog comments powered by Disqus