Sun, 27 Aug 2006, by per@computer.org:
Kastus Shchuka wrote:
I'm trying to assign a virtual IP to the loopback interface 'lo': [..] How do you check for that? ifconfig might not show your secondary address. Try "ip addr show dev lo"
I just checked it with 'ifconfig', thinking that I should be seeing a second interface 'lo:n' ?
# ip addr show dev lo 1: lo: <LOOPBACK,UP> mtu 16436 qdisc noqueue link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo inet 192.168.2.231/32 scope global lo inet6 ::1/128 scope host valid_lft forever preferred_lft forever
Well, there it is! Excellent.
I'm curious; why don't you use e.g. 127.22.0.1/32 as a virtual IP address (instead of an RFC1918 address)? It would then be a lot clearer that the addres belongs to LO imho, and not cause any possible confusion in the future. Theo -- Theo v. Werkhoven Registered Linux user# 99872 http://counter.li.org ICBM 52 13 26N , 4 29 47E. + ICQ: 277217131 SUSE 9.2 + Jabber: muadib@jabber.xs4all.nl Kernel 2.6.8 + See headers for PGP/GPG info. Claimer: any email I receive will become my property. Disclaimers do not apply.