Network setup

Tom H tomh0665 at gmail.com
Thu Jan 14 15:51:48 UTC 2016


On Thu, Jan 14, 2016 at 4:25 PM, Chris Green <cl at isbd.net> wrote:
> On Thu, Jan 14, 2016 at 09:14:05AM -0600, W Scott Lockwood III wrote:
>> On 1/14/2016 6:18 AM, Chris Green wrote:
>>>
>>> It's not even very obvious from the default help given by 'ip' how I
>>> would simply ask for the same information that 'ifconfig' gives me.
>>
>> ip addr
>
> Thanks, at least I know now. How I would be able to work that out from:-
>
>     Usage: ip [ OPTIONS ] OBJECT { COMMAND | help }
>            ip [ -force ] -batch filename
>     where  OBJECT := { link | addr | addrlabel | route | rule | neigh | ntable |
>                        tunnel | tuntap | maddr | mroute | mrule | monitor | xfrm |
>                        netns | l2tp | tcp_metrics | token }
>            OPTIONS := { -V[ersion] | -s[tatistics] | -d[etails] | -r[esolve] |
>                         -f[amily] { inet | inet6 | ipx | dnet | bridge | link } |
>                         -4 | -6 | -I | -D | -B | -0 |
>                         -l[oops] { maximum-addr-flush-attempts } |
>                         -o[neline] | -t[imestamp] | -b[atch] [filename] |
>                         -rc[vbuf] [size]}
>
> ... is anybody's guess.  :-)

There's no guessing involved.

>From the above, you look up "OBJECT" further down:

IP - COMMAND SYNTAX
   OBJECT
       address
              - protocol (IP or IPv6) address on a device.

Further down:

The names of all objects may be written in full or abbreviated form,
for example address can be abbreviated as addr or just a.

>From the above, you look up "COMMAND" further down:

COMMAND
       Specifies the action to perform on the object.  The set of
possible actions depends on the object type.  As a rule, it is
possible to add, delete and
       show (or list ) objects, but some objects do not allow all of
these operations or have some additional commands. The help command is
available for
       all objects. It prints out a list of available commands and
argument syntax conventions.

       If no command is given, some default command is assumed.
Usually it is list or, if the objects of this class cannot be listed,
help.

And further down:

SEE ALSO
       ip-address(8)

"ip" has far more features than "ifconfig". Tools with many options
have complex man pages; take a look at "man ps" or "man nmap".




More information about the ubuntu-users mailing list