Date: Mon, 24 Jun 2002 23:54:37 +0200 (CEST) From: Cyrille Lefevre <cyrille.lefevre@laposte.net> To: freebsd stable <freebsd-stable@FreeBSD.org> Subject: unable to alias more than 1 ip address in a subnet Message-ID: <200206242154.g5OLsbql001728@gits.gits.dyndns.org>
next in thread | raw e-mail | index | archive | help
Hi,
maybe I've discovered why I can't run netscape4, which hang my
machine, for weeks (months?).
netscape is configured to pass through the junkbuster proxy which
is normally started on an IP alias. unfortunatelly, junkbuster won't
start for some time because the alias is missing while it is normally
setup at boot time through dhclient-exit-script.
here is my configuration :
# uname -a
FreeBSD gits 4.6-STABLE FreeBSD 4.6-STABLE #15: Sun Jun 23 06:31:23 CEST 2002 root@gits:/disk2/freebsd/src/sys/compile/CUSTOM i386
# ifconfig ep0
(immediatly after boot)
ep0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
inet 212.198.229.153 netmask 0xffffff00 broadcast 212.198.229.255
inet 192.168.144.96 netmask 0xffffff00 broadcast 192.168.144.255
ether 00:60:08:1a:9a:37
media: Ethernet 10baseT/UTP
# netstat -rn
(ditto)
Routing tables
Internet:
Destination Gateway Flags Refs Use Netif Expire
127.0.0.1 127.0.0.1 UH 4 195 lo0
192.168.144 link#1 UC 0 0 ep0
192.168.144.96 127.0.0.1 UGHS 0 0 lo0
192.168.144.97 127.0.0.1 UGHS 0 0 lo0
212.198.229 link#1 UC 1 0 ep0
212.198.229.153 127.0.0.1 UGHS 0 0 lo0
212.198.229.255 ff:ff:ff:ff:ff:ff UHLWb 1 5 ep0
here is the interresting part of the dhclient-exit-script trace file :
+ awk -v interface=ep0
/[ ]*#[ ]*alias/ && $3 == interface { print $4, $5 }
/usr/local/etc/dhclient.conf
+ read alias_ip_address alias_subnet_mask
+ alias_subnet_arg=netmask 255.255.255.0
+ [ x212.198.229.153 != x192.168.144.97 ]
+ [ x192.168.144.97 != x ]
+ ifconfig ep0 inet alias 192.168.144.97 netmask 255.255.255.0
ifconfig: ioctl (SIOCAIFADDR): File exists
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+ route add 192.168.144.97 127.0.0.1
add host 192.168.144.97: gateway 127.0.0.1
+ read alias_ip_address alias_subnet_mask
and the dhclient.conf configuration file :
timeout 60;
retry 60;
select-timeout 5;
reboot 10;
initial-interval 5;
interface "ep0" {
request subnet-mask, broadcast-address, time-offset, routers,
domain-name, domain-name-servers, host-name;
require subnet-mask, domain-name-servers;
prepend domain-name "gits.fr.invalid "; # the final space is required
prepend domain-name-servers 127.0.0.1;
}
alias {
interface "ep0";
fixed-address 192.168.144.96;
option subnet-mask 255.255.255.0;
# alias ep0 192.168.144.97 255.255.255.0
}
so, the first alias (192.168.144.96) is well configured, but not the second one.
there is no problem to create a new alias in another subnet, but no more :
# ifconfig ep0 inet alias 192.168.146.96
(ok)
# ifconfig ep0 inet alias 192.168.146.97
ifconfig: ioctl (SIOCAIFADDR): File exists
# ifconfig ep0
ep0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
inet 212.198.229.153 netmask 0xffffff00 broadcast 212.198.229.255
inet 192.168.144.96 netmask 0xffffff00 broadcast 192.168.144.255
inet 192.168.146.96 netmask 0xffffff00 broadcast 192.168.146.255
ether 00:60:08:1a:9a:37
media: Ethernet 10baseT/UTP
any idea ?
Cyrille.
--
Cyrille Lefevre mailto:cyrille.lefevre@laposte.net
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200206242154.g5OLsbql001728>
