From: nobody@zk3.dec.com (Eric Werme - replace nobody with werme)
Subject: Re: Why doesn't ifconfig work?
Date: 1998/04/30 [thread overview]
Message-ID: <6iar3m$ot7$1@lead.zk3.dec.com> (raw)
In-Reply-To: 354744C0.E2B6F10C@ral1.zko.dec.com
John Chambers <jc@ral1.zko.dec.com> writes:
>On this Digital Unix 4.0B system, and on another 4.0D system, the ifconfig
>command doesn't seem to be able to change IP addresses at all. It always
>gives a 1 exit status, implying that it thinks that it has worked, but in fact
>the address doesn't change. Here's some evidence:
I've always thought the ifconfig "parser" (hah!) should be rewritten. Here
are some suggestions from someone who actually gets to work on it.
This is one way:
# ifconfig tu1 10.1.1.1 netmask 255.255.255.0
# ifconfig tu1
tu1: flags=c63<UP,BROADCAST,NOTRAILERS,RUNNING,MULTICAST,SIMPLEX>
inet 10.1.1.1 netmask ffffff00 broadcast 10.1.1.255 ipmtu 1500
# ifconfig tu1 down delete
tu1: delete inet address 10.1.1.1
# ifconfig tu1
tu1: flags=c62<BROADCAST,NOTRAILERS,RUNNING,MULTICAST,SIMPLEX>
# ifconfig tu1 10.1.2.3 netmask 255.255.255.0
# ifconfig tu1
tu1: flags=c63<UP,BROADCAST,NOTRAILERS,RUNNING,MULTICAST,SIMPLEX>
inet 10.1.2.3 netmask ffffff00 broadcast 10.1.2.255 ipmtu 1500
This is much "slicker":
# ifconfig tu1 10.1.1.1 netmask 255.255.255.0
tu1: flags=c63<UP,BROADCAST,NOTRAILERS,RUNNING,MULTICAST,SIMPLEX>
inet 10.1.1.1 netmask ffffff00 broadcast 10.1.1.255 ipmtu 1500
# ifconfig tu1 alias 10.1.2.3 netmask 255.255.255.0
# ifconfig tu1 -alias 10.1.1.1
# ifconfig tu1
tu1: flags=c63<UP,BROADCAST,NOTRAILERS,RUNNING,MULTICAST,SIMPLEX>
inet 10.1.2.3 netmask ffffff00 broadcast 10.1.2.255 ipmtu 1500
--
<> Eric (Ric) Werme <> The above is unlikely to contain <>
<> ROT-13 addresses: <> official claims or policies of <>
<> <jrezr@mx3.qrp.pbz> <> Digital Equipment Corp. <>
<> <jrezr@plorecbegny.arg> <> http://www.cyberportal.net/werme <>
next prev parent reply other threads:[~1998-04-30 4:00 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
1998-04-29 4:00 Why doesn't ifconfig work? John Chambers
1998-04-30 4:00 ` Eric Werme - replace nobody with werme [this message]
1998-05-04 4:00 ` John Chambers
1998-05-10 4:00 ` Paul Repacholi ( prep )
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox