On Tue, 2009-09-01 at 21:59 -0700, Peter Memishian wrote:
> > >  > Given that iptun *must* have both addresses, is it better to require 
> > > them
>  > >  > to be provided as a comma-separated pair?
>  > > 
>  > > That's not so; e.g. a 6to4 tunnel only has one address.
>  > 
>  > true. for ipadm the syntax is -a <addr>[,<addr>] where the tunnel type
>  > is used to check if one or two addresses is needed. but my point was
>  > that, instead of using a separate -l and -r we could get both in the
>  > same option..
> 
> Yes.  I'm fine with `-a <addr>[,<addr>]' (I think I suggested it a while
> back), but I think Seb doesn't care for it much, and it seems some feel
> confused by the order of the addresses (though I find it natural that the
> source/local address is first).  I think I'm fine with most anything as
> long as dladm and ipadm work similarly (that is, I can deal with "-l"
> meaning something different with create-iptun, though of course it'd be
> preferable to not have to do that :-).

I don't care for it indeed.  The dladm syntax (and the ifconfig syntax
before it) did not require either address to be specified at all for
point-to-point tunnels (nor the source for 6to4 tunnels).  The link is
simply not bound to IP underneath (and the link state isn't up) until
required addresses are set, and one can modify either address
independently.  For example, one has the flexibility do the following as
distinct steps:

dladm create-iptun -T ipv4 tun0
dladm modify-iptun -s <src> tun0
dladm modify-iptun -d <dst> tun0

That would turn into:

dladm create-iptun -T ipv4 tun0
dladm modify-iptun -a <src> tun0
dladm modify-iptun -a ,<dst> tun0

I'm not a fan.  It feels like we're squeezing two link attributes into
one option.  I can live with this in the interest of uniformity (and
maybe my aversion to it isn't rational), but as another alternative, how
about -a and -r (-a for the local address, and -r for the remote
address)?  Do you think that this is any better?

-Seb


Reply via email to