- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2011 06:22 PM - edited 03-06-2019 03:38 PM
Hi all,
need to know when and why we use the no ip address command?
thanks
mahesh
Solved! Go to Solution.
- Labels:
-
Other Switching
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2011 08:06 PM
Hi,
That is correct, simply put - no IP address is defined for the interface by default.Once you enter an ip address for an interface you make it a L3 port. You can disable IP processing on a particular interface (revert back to L2) by removing its IP address with the 'no ip address' command.
Hope that helps!
Cheers,
Abhishek.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2011 08:20 PM
The default configuration looks like this:
SWITCH(config)#show run int fa4/20
Building configuration...
Current configuration : 59 bytes
!
interface FastEthernet4/20
no ip address
shutdown
end
<<<<<<<<<< The above is a layer 3 interface now.
<<<<<<<<<< When you assign an ip address you would see the following.
SWITCH#conf t
SWITCH(config)#
SWITCH(config)#int fa4/20
SWITCH(config-if)#ip address 10.1.1.1 255.0.0.0
SWITCH(config-if)#^Z
SWITCH#show run int fa4/20
Building configuration...
Current configuration : 75 bytes
!
interface FastEthernet4/20
ip address 10.1.1.1 255.0.0.0
shutdown
end
SWITCH#
<<<<<<<<<<< when you make this a layer 2 inteface:
SWITCH#conf t
SWITCH(config)#int fa4/20
SWITCH(config-if)#no ip address
SWITCH(config-if)#switchport
SWITCH(config-if)#^Z
SWITCH#show run int fa4/20
Building configuration...
Current configuration : 56 bytes
!
interface FastEthernet4/20 <<<<< now its a layer 2 interface...
switchport
shutdown
end
SWITCH#
Hope this helps...
(please rate the helpful posts)
Regards,
ranraju
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2011 07:25 PM
Hello Mahesh,
If you have an IP address assigned to a layer 3 interface, and you wish to remove the assigned ip address on that interface, you use this command "no ip address".
To view the IP address on the interface you could use on of the following commands, "show running-config int gigx/y" or "show ip int br | ex unas".
Hope your question is answered.
Regards,
ranraju
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2011 07:39 PM
Hi Ranraju,
thanks for reply
I also see the command
no ip address on switchport that connects to IP phone?
do you know why we use this command on port going to Cisco phone?
mahesh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2011 07:47 PM
I guess you are looking at a layer 3 interface. And by default on the layer 3 interface you would see "no ip address" under it.. once you assing an ip address on that interface then you would just see that ip address under that interface.. eg " ip address 10.1.1.1 255.0.0.0"
Now if you want an ip phone to be connected to a layer 2 port and assign a voice and a data vlan - you could do so by making that interface a "switchport" first, once its made a "switchport" you will not see "no ip address" under that interface... as you cannot have an ip address on a layer 2 interface..
Hope this helps..
(please rate the helpful posts..)
Regards,
ranraju
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2011 08:06 PM
Hi,
That is correct, simply put - no IP address is defined for the interface by default.Once you enter an ip address for an interface you make it a L3 port. You can disable IP processing on a particular interface (revert back to L2) by removing its IP address with the 'no ip address' command.
Hope that helps!
Cheers,
Abhishek.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2011 08:20 PM
The default configuration looks like this:
SWITCH(config)#show run int fa4/20
Building configuration...
Current configuration : 59 bytes
!
interface FastEthernet4/20
no ip address
shutdown
end
<<<<<<<<<< The above is a layer 3 interface now.
<<<<<<<<<< When you assign an ip address you would see the following.
SWITCH#conf t
SWITCH(config)#
SWITCH(config)#int fa4/20
SWITCH(config-if)#ip address 10.1.1.1 255.0.0.0
SWITCH(config-if)#^Z
SWITCH#show run int fa4/20
Building configuration...
Current configuration : 75 bytes
!
interface FastEthernet4/20
ip address 10.1.1.1 255.0.0.0
shutdown
end
SWITCH#
<<<<<<<<<<< when you make this a layer 2 inteface:
SWITCH#conf t
SWITCH(config)#int fa4/20
SWITCH(config-if)#no ip address
SWITCH(config-if)#switchport
SWITCH(config-if)#^Z
SWITCH#show run int fa4/20
Building configuration...
Current configuration : 56 bytes
!
interface FastEthernet4/20 <<<<< now its a layer 2 interface...
switchport
shutdown
end
SWITCH#
Hope this helps...
(please rate the helpful posts)
Regards,
ranraju
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2011 08:50 PM
Hi Ranraju and Abhishek,
Many thanks for good explanation
regards
mahesh
