08-02-2004 07:16 PM - edited 03-02-2019 05:29 PM
havent tried to use loopback address, what's the essence of this command? will this mean that if I loose my physical connection i can still connect to the device? pls. help, what ip addres will i use?
08-02-2004 09:30 PM
Hello,
you need at least one active physical path to your device in order to get to your loopback interface and address.
A loopback interface on e.g. a Cisco router is a virtual physical interface. That is, it looks and behaves as if it were a real physical interface, in all ways. It is implemented and configured using the same commands and syntax you would use to select and configure a real physical interface, such as a serial or ethernet port.
The router will deliver traffic to networks assigned to a loopback interface as if it were delivering traffic to a real network, physically connected to the router. An ip network address assigned to the interface will cause an entry for that ip network to be placed in the router's routing table, just like one on a real physical network interface would. Shutting down the loopback interface would cause the router to remove the route to that network from it's routing table, just like shutting down a real physical interface would.
Any packets that a router delivers to a network on a loopback interface actually end up just being discarded.
Loopback interfaces can be used for a variety of purposes. E.g. loopback 0 is used to provide a single ip address for the router which can be reached from other points in the network through any of the router's true physical interfaces. Without this loopback interface, you would have to connect to the router specifically through one of it's true physical interfaces. If that interface happened to go down for some reason you'd have to know the addresses of the other interfaces and make a new connection to one of them, in order to reconnect to the router.
Loopbacks are also handy for use with ip unnumbered. If you have a multipoint interface using subinterfaces you could give every subinterface the same address and keep everything on the same subnet.
They're also handy for DNS. If your router hostname resolves to its loopback address you'll be able to reach the router using the hostname as long as
there is at least one real interface up. If you were to resolve the name to an actual interface address you wouldn't be able to reach the router at all
of that interface were down.
Another example of the usefulness of a loopback address would be NTP. Use the command ´ntp source LoopbackX´ when you want to use the loopback as source IP address for all NTP (Network Time Protocol) packets. The address is taken from the named interface. This command is useful if the address on an interface cannot be used as the destination for reply packets.
HTH,
Georg
08-02-2004 09:38 PM
It is also useful as the end-point for a tunnel (IP, DLSw, BSTUN etc.), again because the interface stays up.
Pete
08-02-2004 11:00 PM
loopback addresses are also very useful in IKA/IPSEC SA definitions..You can get tunnels established over more than one physical connection.
Serhat
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide