Subject: Re: /etc/ifaliases, or $ifaliases_ne0
To: None <itojun@iijlab.net>
From: Luke Mewburn <lukem@goanna.cs.rmit.edu.au>
List: tech-userlevel
Date: 11/28/1999 23:48:16
itojun@iijlab.net writes:
> /etc/netstart can parse /etc/ifaliases and $ifaliases_ifname.
> The parsing code in /etc/netstart is hardcoded to IPv4 (I mean,
> use of "inet"). Isn't it more correct to let user specify the address
> family portion? I would like to allow "inet6" at least.
> It would be nice if we can say "prefixlen" instead of "netmask".
>
> I admit there will be backward compatibility issue in
> $ifaliases_ifname case (because it chops the string into tokens
> and use every two pairs as argument). Let me know this should be
> modified. $ifaliases6_ifname is not nice...
how hard is it to determine if it's an ipv6 vs ipv4 address? i suppose
that doesn't help you're using names instead of addresses.
it's a shame that /etc/ifaliases wasn't as flexible as the /etc/ifconfig.XXX
format.
how about supporting /etc/ifaliases.XXX, with syntax of
family aliasaddress [optional parameters]
where optional parameters includes netmask, prefixlen, etc...
that doesn't help on the variable side (e.g $ifalias_XXX). however,
since you may have a number of aliases per interface, it would make
it tricky to support a variable number of args *and* multiple aliases
per interface in the one shell variable, so don't try and support
extending the $if* syntax in your rework.