DragonFly submit List (threaded) for 2004-01
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]
Re: hostname(1) change
Hi Matt n all,
Matthew Dillon probed the keyboard and on Sun, Jan 04, 2004 at 06:55:01PM -0800 produced:
>
> :Thanks for the suggestion Emiel, attached is a new patchset (based on clean
> :source), I haven't done much IPV6 work, but it seems to work ok, you can now
> :do the following and get the same result;
> :
> :hostname www.6bone.net
> :hostname -r 3ffe:b00:c18:1::10
> :hostname -r 206.123.31.124
>
> I like it! How would you like to add one more feature... the ability
> to have hostname pull the IP address out of a network interface and then
> reverse resolve it to set the host name, e.g.
>
> hostname -i fxp0
>
> -Matt
>
Thanks, actually, that was my original intention, hence using -r (for reverse)
and leaving -i for interface. I just knew whacking out the code for reverse
would be quicker (that, and I had a need for it). I'll add some interface
probing code and resubmit. I assume using sysctl(3) is the correct method
for grabbing the interface details (I'm using ifconfig(8) as a reference) and
using the first IP address found on the given interface would be appropriate?
Cheers,
--
Kent Ibbetson
bsd@xxxxxxxxxx
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]