All of lore.kernel.org
 help / color / mirror / Atom feed
* parsing the output of ethtool programmatically
@ 2015-06-25  1:28 Robert Urban
  2015-09-05  9:53 ` Ben Hutchings
  0 siblings, 1 reply; 4+ messages in thread
From: Robert Urban @ 2015-06-25  1:28 UTC (permalink / raw)
  To: bwh, netdev

Hello,

there doesn't seem to be any flag to request ethtool to present its output in a
script-friendly form.  Things like:
>         Link partner advertised link modes:  10baseT/Half 10baseT/Full
>                                              100baseT/Half 100baseT/Full
>                                              1000baseT/Full
are kind of pain to parse.

Something to consider?

Robert Urban

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: parsing the output of ethtool programmatically
  2015-06-25  1:28 parsing the output of ethtool programmatically Robert Urban
@ 2015-09-05  9:53 ` Ben Hutchings
  2015-09-08  2:52   ` roopa
  0 siblings, 1 reply; 4+ messages in thread
From: Ben Hutchings @ 2015-09-05  9:53 UTC (permalink / raw)
  To: Robert Urban, bwh, netdev

[-- Attachment #1: Type: text/plain, Size: 706 bytes --]

On Thu, 2015-06-25 at 03:28 +0200, Robert Urban wrote:
> Hello,
> 
> there doesn't seem to be any flag to request ethtool to present its output in a
> script-friendly form.  Things like:
> >         Link partner advertised link modes:  10baseT/Half 10baseT/Full
> >                                              100baseT/Half 100baseT/Full
> >                                              1000baseT/Full
> are kind of pain to parse.
> 
> Something to consider?

Or write a library for using SIOCETHTOOL.  The interface is fairly well
documented now and there are other users besides the ethtool utility.

Ben.

-- 
Ben Hutchings
friends: People who know you well, but like you anyway.


[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 811 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: parsing the output of ethtool programmatically
  2015-09-05  9:53 ` Ben Hutchings
@ 2015-09-08  2:52   ` roopa
  2017-10-26  0:21     ` Robert Urban
  0 siblings, 1 reply; 4+ messages in thread
From: roopa @ 2015-09-08  2:52 UTC (permalink / raw)
  To: Ben Hutchings; +Cc: Robert Urban, bwh, netdev

On 9/5/15, 2:53 AM, Ben Hutchings wrote:
> On Thu, 2015-06-25 at 03:28 +0200, Robert Urban wrote:
>> Hello,
>>
>> there doesn't seem to be any flag to request ethtool to present its output in a
>> script-friendly form.  Things like:
>>>          Link partner advertised link modes:  10baseT/Half 10baseT/Full
>>>                                               100baseT/Half 100baseT/Full
>>>                                               1000baseT/Full
>> are kind of pain to parse.
>>
>> Something to consider?
> Or write a library for using SIOCETHTOOL.  The interface is fairly well
> documented now and there are other users besides the ethtool utility.

one of the requests which we usually get is ethtool output in json 
format. since iproute2 tools are already getting
an option to print in json format, would be nice if we considered an 
option to print in json for ethtool too.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: parsing the output of ethtool programmatically
  2015-09-08  2:52   ` roopa
@ 2017-10-26  0:21     ` Robert Urban
  0 siblings, 0 replies; 4+ messages in thread
From: Robert Urban @ 2017-10-26  0:21 UTC (permalink / raw)
  To: roopa, Ben Hutchings; +Cc: bwh, netdev

may I also suggest being able to specify the offload parameters in the format in
which "ethtool -k <nic>" prints them? The user can only guess which -K
parameters correspond to the -k parameters.


On 09/08/2015 04:52 AM, roopa wrote:
> On 9/5/15, 2:53 AM, Ben Hutchings wrote:
>> On Thu, 2015-06-25 at 03:28 +0200, Robert Urban wrote:
>>> Hello,
>>>
>>> there doesn't seem to be any flag to request ethtool to present its output in a
>>> script-friendly form.  Things like:
>>>>          Link partner advertised link modes:  10baseT/Half 10baseT/Full
>>>>                                               100baseT/Half 100baseT/Full
>>>>                                               1000baseT/Full
>>> are kind of pain to parse.
>>>
>>> Something to consider?
>> Or write a library for using SIOCETHTOOL.  The interface is fairly well
>> documented now and there are other users besides the ethtool utility.
>
> one of the requests which we usually get is ethtool output in json format.
> since iproute2 tools are already getting
> an option to print in json format, would be nice if we considered an option to
> print in json for ethtool too.
>
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-10-26  0:30 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-06-25  1:28 parsing the output of ethtool programmatically Robert Urban
2015-09-05  9:53 ` Ben Hutchings
2015-09-08  2:52   ` roopa
2017-10-26  0:21     ` Robert Urban

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.