|
|
Subscribe / Log in / New account

iproute2 and libbpf: vendoring on the small scale

iproute2 and libbpf: vendoring on the small scale

Posted Nov 15, 2020 20:30 UTC (Sun) by dtlin (subscriber, #36537)
In reply to: iproute2 and libbpf: vendoring on the small scale by geert
Parent article: iproute2 and libbpf: vendoring on the small scale

`ip l` and `ip a` being separate commands, short for `ip link` and `ip address`, as the help cryptically states.


to post comments

iproute2 and libbpf: vendoring on the small scale

Posted Nov 16, 2020 8:04 UTC (Mon) by Wol (subscriber, #4433) [Link] (4 responses)

So in order to get the informatiion I might want, I have to type three or four commands? Whereas ifconfig was just one command?

If that's what I want, how do I get multiple bits of information in one go?

Cheers,
Wol

iproute2 and libbpf: vendoring on the small scale

Posted Nov 18, 2020 0:18 UTC (Wed) by nix (subscriber, #2304) [Link] (2 responses)

'ip addr' displays all the information 'ip link' does about links and then adds address info to that, so that is usually enough unless you're looking for. ip -s addr if you want packet stats too (which I almost never do, so I'm glad it's off by default). ('ip link' is still valuable because that's what you use to *configure* the link layer: you can't use ip addr to do that.)

iproute2 and libbpf: vendoring on the small scale

Posted Nov 26, 2020 10:20 UTC (Thu) by ecree (guest, #95790) [Link] (1 responses)

But it's crazy that I have to type `ip -s addr` and can't `ip addr -s`, when command-subcommand-options is *so* much more natural. `tc` has this problem too. And `ip` doesn't understand `-h` at *all*, which is a cardinal sin for a Unix utility. (Though what can one expect from a Cisco-ism.)

iproute2 and libbpf: vendoring on the small scale

Posted Nov 27, 2020 22:19 UTC (Fri) by nix (subscriber, #2304) [Link]

I think it's supposed to indicate that the -s option applies to many ip subcommands. Quite a lot of other commands these days do the same thing: git for one. I find it a bit annoying, too, but it does allow git -P diff and git diff -P to mean different things... which matters a lot for a metastasized mega-command like git and... not so much at all for ip.

iproute2 and libbpf: vendoring on the small scale

Posted Nov 26, 2020 15:59 UTC (Thu) by opsec (subscriber, #119360) [Link]

Write a wrapper named ifconfig ? That uses 'ip l' and 'ip a' to get what you need ?

I'm a FreeBSD user, we still have ifconfig, so I feel the pain as well, when I get to a linux box 8-}


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds