Solved

find string before grep (ksh AIX)

Posted on 2013-06-17
3
533 Views
Last Modified: 2013-06-17
In the output of this entstat -d SEA-ADAPTER, I want to print ONLY the speed of every physical adapter in the etherchannel and its relative adapter name. Here in my case (ent0/ent2) I want this output:

ETHERNET STATISTICS (ent0) :
Media Speed Running: 100 Mbps Full Duplex
ETHERNET STATISTICS (ent2) :
Media Speed Running: 100 Mbps Full Duplex

I just want to know the speed of the physical adapters of our vioservers/ivms.

root@viosctg1_1 # entstat -d ent7
-------------------------------------------------------------

ETHERNET STATISTICS (ent7) :
Device Type: Shared Ethernet Adapter
Hardware Address: 00:14:5e:d1:51:e2
Elapsed Time: 0 days 0 hours 27 minutes 41 seconds

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 14656                                Packets: 19965
Bytes: 1322486                                Bytes: 1466621
Interrupts: 0                                 Interrupts: 18832
Transmit Errors: 30                           Receive Errors: 0
Packets Dropped: 30                           Packets Dropped: 0
                                              Bad Packets: 0
Max Packets on S/W Transmit Queue: 28
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Elapsed Time: 0 days 0 hours 0 minutes 0 seconds
Broadcast Packets: 1950                       Broadcast Packets: 3552
Multicast Packets: 6049                       Multicast Packets: 12129
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 4
Adapter Data Rate: 0
Driver Flags: Up Broadcast Running
        Simplex 64BitSupport ChecksumOffload
        DataRateSet


--------------------------------------------------------------
Statistics for adapters in the Shared Ethernet Adapter ent7
--------------------------------------------------------------
Number of adapters: 2
SEA Flags: 00000021
    < THREAD >
    < ACCOUNTING >
VLAN Ids :
    ent4: 830 831 832 833 834 835
Real Side Statistics:
    Packets received: 11916
    Packets bridged: 7972
    Packets consumed: 11745
    Packets fragmented: 0
    Packets transmitted: 6604
    Packets dropped: 0
Virtual Side Statistics:
    Packets received: 0
    Packets bridged: 0
    Packets consumed: 0
    Packets fragmented: 0
    Packets transmitted: 8087
    Packets dropped: 0
Other Statistics:
    Output packets generated: 6607
    Output packets dropped: 0
    Device output failures: 3
    Memory allocation failures: 0
    ICMP error packets sent: 0
    Non IP packets larger than MTU: 0
    Thread queue overflow packets: 0
High Availability Statistics:
    Control Channel PVID: 99
    Control Packets in: 11
    Control Packets out: 5531
Type of Packets Received:
    Keep-Alive Packets: 8
    Recovery Packets: 0
    Notify Packets: 1
    Limbo Packets: 2
    State: PRIMARY
    Bridge Mode: All
    Number of Times Server became Backup: 0
    Number of Times Server became Primary: 1
    High Availability Mode: Auto
    Priority: 1
--------------------------------------------------------------
Real Adapter: ent6

ETHERNET STATISTICS (ent6) :
Device Type: EtherChannel
Hardware Address: 00:14:5e:d1:51:e2

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 6604                                 Packets: 19941
Bytes: 748240                                 Bytes: 1464733
Interrupts: 0                                 Interrupts: 18809
Transmit Errors: 0                            Receive Errors: 0
Packets Dropped: 0                            Packets Dropped: 0
                                              Bad Packets: 0

Max Packets on S/W Transmit Queue: 28
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Broadcast Packets: 99                         Broadcast Packets: 3544
Multicast Packets: 15                         Multicast Packets: 12113
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 4
Adapter Data Rate: 200
Driver Flags: Up Broadcast Running
        Simplex Promiscuous 64BitSupport
        ChecksumOffload LargeSend DataRateSet

========================= ========================= ===========
========================= ========================= ===========

Statistics for every adapter in the EtherChannel:
-------------------------------------------------

Number of adapters: 2
Active channel: primary channel
Operating mode: Network interface backup mode

-------------------------------------------------------------

ETHERNET STATISTICS (ent0) :
Device Type: 2-Port 10/100/1000 Base-TX PCI-X Adapter (14108902)
Hardware Address: 00:14:5e:d1:51:e2

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 6652                                 Packets: 11921
Bytes: 757288                                 Bytes: 882025
Interrupts: 0                                 Interrupts: 11174
Transmit Errors: 0                            Receive Errors: 0
Packets Dropped: 0                            Packets Dropped: 0
                                              Bad Packets: 0
Max Packets on S/W Transmit Queue: 28
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Broadcast Packets: 72                         Broadcast Packets: 1752
Multicast Packets: 15                         Multicast Packets: 6050
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 1
Adapter Data Rate: 200
Driver Flags: Up Broadcast Running
        Simplex Promiscuous 64BitSupport
        ChecksumOffload LargeSend DataRateSet

2-Port 10/100/1000 Base-TX PCI-X Adapter (14108902) Specific Statistics:
------------------------------------------------------------------------
Link Status : Up
Media Speed Selected: Auto negotiation
Media Speed Running: 100 Mbps Full Duplex
PCI Mode: PCI-X (100-133)
PCI Bus Width: 64-bit
Latency Timer: 144
Cache Line Size: 128
Jumbo Frames: Disabled
TCP Segmentation Offload: Enabled
TCP Segmentation Offload Packets Transmitted: 0
TCP Segmentation Offload Packet Errors: 0
Transmit and Receive Flow Control Status: Disabled
Transmit and Receive Flow Control Threshold (High): 49152
Transmit and Receive Flow Control Threshold (Low): 24576
Transmit and Receive Storage Allocation (TX/RX): 8/56

-------------------------------------------------------------
Backup adapter - ent2:
======================

ETHERNET STATISTICS (ent2) :
Device Type: 2-Port 10/100/1000 Base-TX PCI-X Adapter (14108902)
Hardware Address: 00:14:5e:d1:51:e2

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 27                                   Packets: 8025
Bytes: 1718                                   Bytes: 583008
Interrupts: 0                                 Interrupts: 7639
Transmit Errors: 0                            Receive Errors: 0
Packets Dropped: 0                            Packets Dropped: 0
                                              Bad Packets: 0
Max Packets on S/W Transmit Queue: 0
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Broadcast Packets: 27                         Broadcast Packets: 1792
Multicast Packets: 0                          Multicast Packets: 6063
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 1
Adapter Data Rate: 200
Driver Flags: Up Broadcast Running
        Simplex Promiscuous 64BitSupport
        ChecksumOffload LargeSend DataRateSet

2-Port 10/100/1000 Base-TX PCI-X Adapter (14108902) Specific Statistics:
------------------------------------------------------------------------
Link Status : Up
Media Speed Selected: Auto negotiation
Media Speed Running: 100 Mbps Full Duplex
PCI Mode: PCI-X (100-133)
PCI Bus Width: 64-bit
Latency Timer: 144
Cache Line Size: 128
Jumbo Frames: Disabled
TCP Segmentation Offload: Enabled
TCP Segmentation Offload Packets Transmitted: 0
TCP Segmentation Offload Packet Errors: 0
Transmit and Receive Flow Control Status: Disabled
Transmit and Receive Flow Control Threshold (High): 49152
Transmit and Receive Flow Control Threshold (Low): 24576
Transmit and Receive Storage Allocation (TX/RX): 8/56

--------------------------------------------------------------
Virtual Adapter: ent4

ETHERNET STATISTICS (ent4) :
Device Type: Virtual I/O Ethernet Adapter (l-lan)
Hardware Address: 02:d9:70:00:40:0b

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 8057                                 Packets: 24
Bytes: 574936                                 Bytes: 1888
Interrupts: 0                                 Interrupts: 23
Transmit Errors: 30                           Receive Errors: 0
Packets Dropped: 30                           Packets Dropped: 0
                                              Bad Packets: 0

Max Packets on S/W Transmit Queue: 0
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Broadcast Packets: 1851                       Broadcast Packets: 8
Multicast Packets: 6034                       Multicast Packets: 16
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 0
Adapter Data Rate: 20000
Driver Flags: Up Broadcast Running
        Simplex Promiscuous AllMulticast
        64BitSupport ChecksumOffload DataRateSet

Virtual I/O Ethernet Adapter (l-lan) Specific Statistics:
---------------------------------------------------------
RQ Length: 4481
Trunk Adapter: True
  Priority: 1  Active: True
Filter MCast Mode: False
Filters: 255
  Enabled: 2  Queued: 0  Overflow: 0
LAN State: Operational

Hypervisor Send Failures: 172
  Receiver Failures: 172
  Send Errors: 0
Hypervisor Receive Failures: 0

Invalid VLAN ID Packets: 30

ILLAN Attributes: 0000000000003103 [0000000000003102]

Port VLAN ID:   833
VLAN Tag IDs:   831   830   835   834   832

Switch ID: ETHERNET00

Hypervisor Information
  Virtual Memory
    Total (KB)                 79
  I/O Memory
    VRM Minimum (KB)          100
    VRM Desired (KB)          100
    DMA Max Min (KB)          128

Transmit Information
  Transmit Buffers
    Buffer Size             65536
    Buffers                    32
    History
      No Buffers                0
  Virtual Memory
    Total (KB)               2048
  I/O Memory
    VRM Minimum (KB)         2176
    VRM Desired (KB)        16384
    DMA Max Min (KB)        16384

Receive Information
  Receive Buffers
    Buffer Type              Tiny    Small   Medium    Large     Huge
    Min Buffers               512      512      128       24       24
    Max Buffers              2048     2048      256       64       64
    Allocated                 512      512      128       24       24
    Registered                512      512      128       24       24
    History
      Max Allocated           512      512      128       24       24
      Lowest Registered       511      512      128       24       24
  Virtual Memory
    Minimum (KB)              256     1024     2048      768     1536
    Maximum (KB)             1024     4096     4096     2048     4096
  I/O Memory
    VRM Minimum (KB)         4096     4096     2560      864     1632
    VRM Desired (KB)        16384    16384     5120     2304     4352
    DMA Max Min (KB)        16384    16384     8192     4096     8192

I/O Memory Information
  Total VRM Minimum (KB)    15524
  Total VRM Desired (KB)    61028
  Total DMA Max Min (KB)    69760

--------------------------------------------------------------
Control Channel Adapter: ent5

ETHERNET STATISTICS (ent5) :
Device Type: Virtual I/O Ethernet Adapter (l-lan)
Hardware Address: 02:d9:70:00:40:13

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 5531                                 Packets: 11
Bytes: 1980098                                Bytes: 3938
Interrupts: 0                                 Interrupts: 10
Transmit Errors: 0                            Receive Errors: 0
Packets Dropped: 0                            Packets Dropped: 0
                                              Bad Packets: 0

Max Packets on S/W Transmit Queue: 0
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Broadcast Packets: 5531                       Broadcast Packets: 11
Multicast Packets: 0                          Multicast Packets: 0
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 0
Adapter Data Rate: 20000
Driver Flags: Up Broadcast Running
        Simplex 64BitSupport ChecksumOffload DataRateSet

Virtual I/O Ethernet Adapter (l-lan) Specific Statistics:
---------------------------------------------------------
RQ Length: 4481
Trunk Adapter: False
Filter MCast Mode: False
Filters: 255
  Enabled: 0  Queued: 0  Overflow: 0
LAN State: Operational

Hypervisor Send Failures: 0
  Receiver Failures: 0
  Send Errors: 0
Hypervisor Receive Failures: 0

Invalid VLAN ID Packets: 0

ILLAN Attributes: 0000000000003002 [0000000000003002]

Port VLAN ID:    99
VLAN Tag IDs:  None


Switch ID: ETHERNET00

Hypervisor Information
  Virtual Memory
    Total (KB)                 79
  I/O Memory
    VRM Minimum (KB)          100
    VRM Desired (KB)          100
    DMA Max Min (KB)          128

Transmit Information
  Transmit Buffers
    Buffer Size             65536
    Buffers                    32
    History
      No Buffers                0
  Virtual Memory
    Total (KB)               2048
  I/O Memory
    VRM Minimum (KB)         2176
    VRM Desired (KB)        16384
    DMA Max Min (KB)        16384

Receive Information
  Receive Buffers
    Buffer Type              Tiny    Small   Medium    Large     Huge
    Min Buffers               512      512      128       24       24
    Max Buffers              2048     2048      256       64       64
    Allocated                 512      512      128       24       24
    Registered                512      512      128       24       24
    History
      Max Allocated           512      512      128       24       24
      Lowest Registered       511      512      128       24       24
  Virtual Memory
    Minimum (KB)              256     1024     2048      768     1536
    Maximum (KB)             1024     4096     4096     2048     4096
  I/O Memory
    VRM Minimum (KB)         4096     4096     2560      864     1632
    VRM Desired (KB)        16384    16384     5120     2304     4352
    DMA Max Min (KB)        16384    16384     8192     4096     8192

I/O Memory Information
  Total VRM Minimum (KB)    15524
  Total VRM Desired (KB)    61028
  Total DMA Max Min (KB)    69760

root@viosctg1_1 #
root@viosctg1_1 # ./viose'
root@viosctg1_1 # ./visoe
root@viosctg1_1 # ./viosether.ksh












SEA=ent7
       ---> ctl_chan=ent5
            state_adapter=PRIMARY
            ha_mode=auto
            virtual _adapter=ent4
            Priority =     1
            Port_VLAN_ID=Port VLAN ID:   833
            VLAN_Tag_IDs=VLAN Tag IDs:   831   830   835   834   832
            real_adapter=ent6
            ETHERCHANNEL=ent6
               ---> primaryadapter=ent0
                    backupadapter=ent2
                    activechannel=primary  adapter
                    mode_etherchannel=standard
                    adress2ping=172.27.35.254
                    etherchannel_link_status:
                        ETHERNET STATISTICS (ent0) :
                        Link Status : Up
                        ETHERNET STATISTICS (ent2) :
                        Link Status : Up












SEA=ent11
       ---> ctl_chan=ent9
            state_adapter=BACKUP
            ha_mode=auto
            virtual _adapter=ent8
            Priority =     2
            Port_VLAN_ID=Port VLAN ID:   765
            VLAN_Tag_IDs=VLAN Tag IDs:    12
            real_adapter=ent10
            ETHERCHANNEL=ent10
               ---> primaryadapter=ent1
                    backupadapter=ent3
                    activechannel=primary  adapter
                    mode_etherchannel=standard
                    adress2ping=172.27.24.254
                    etherchannel_link_status:
                        ETHERNET STATISTICS (ent1) :
                        Link Status : Up
                        ETHERNET STATISTICS (ent3) :
                        Link Status : Up
root@viosctg1_1 # entstat -d ent7
-------------------------------------------------------------

ETHERNET STATISTICS (ent7) :
Device Type: Shared Ethernet Adapter
Hardware Address: 00:14:5e:d1:51:e2
Elapsed Time: 0 days 0 hours 37 minutes 43 seconds

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 19472                                Packets: 26798
Bytes: 1729902                                Bytes: 1961903
Interrupts: 0                                 Interrupts: 25328
Transmit Errors: 40                           Receive Errors: 0
Packets Dropped: 40                           Packets Dropped: 0
                                              Bad Packets: 0
Max Packets on S/W Transmit Queue: 28
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Elapsed Time: 0 days 0 hours 0 minutes 0 seconds
Broadcast Packets: 2579                       Broadcast Packets: 4798
Multicast Packets: 8257                       Multicast Packets: 16553
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 4
Adapter Data Rate: 0
Driver Flags: Up Broadcast Running
        Simplex 64BitSupport ChecksumOffload
        DataRateSet


--------------------------------------------------------------
Statistics for adapters in the Shared Ethernet Adapter ent7
--------------------------------------------------------------
Number of adapters: 2
SEA Flags: 00000021
    < THREAD >
    < ACCOUNTING >
VLAN Ids :
    ent4: 830 831 832 833 834 835
Real Side Statistics:
    Packets received: 15851
    Packets bridged: 10863
    Packets consumed: 15620
    Packets fragmented: 0
    Packets transmitted: 8528
    Packets dropped: 0
Virtual Side Statistics:
    Packets received: 0
    Packets bridged: 0
    Packets consumed: 0
    Packets fragmented: 0
    Packets transmitted: 10986
    Packets dropped: 0
Other Statistics:
    Output packets generated: 8531
    Output packets dropped: 0
    Device output failures: 3
    Memory allocation failures: 0
    ICMP error packets sent: 0
    Non IP packets larger than MTU: 0
    Thread queue overflow packets: 0
High Availability Statistics:
    Control Channel PVID: 99
    Control Packets in: 11
    Control Packets out: 7536
Type of Packets Received:
    Keep-Alive Packets: 8
    Recovery Packets: 0
    Notify Packets: 1
    Limbo Packets: 2
    State: PRIMARY
    Bridge Mode: All
    Number of Times Server became Backup: 0
    Number of Times Server became Primary: 1
    High Availability Mode: Auto
    Priority: 1
--------------------------------------------------------------
Real Adapter: ent6

ETHERNET STATISTICS (ent6) :
Device Type: EtherChannel
Hardware Address: 00:14:5e:d1:51:e2

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 8528                                 Packets: 26775
Bytes: 948152                                 Bytes: 1960075
Interrupts: 0                                 Interrupts: 25306
Transmit Errors: 0                            Receive Errors: 0
Packets Dropped: 0                            Packets Dropped: 0
                                              Bad Packets: 0

Max Packets on S/W Transmit Queue: 28
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Broadcast Packets: 103                        Broadcast Packets: 4790
Multicast Packets: 19                         Multicast Packets: 16537
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 4
Adapter Data Rate: 200
Driver Flags: Up Broadcast Running
        Simplex Promiscuous 64BitSupport
        ChecksumOffload LargeSend DataRateSet

========================= ========================= ===========
========================= ========================= ===========

Statistics for every adapter in the EtherChannel:
-------------------------------------------------

Number of adapters: 2
Active channel: primary channel
Operating mode: Network interface backup mode

-------------------------------------------------------------

ETHERNET STATISTICS (ent0) :
Device Type: 2-Port 10/100/1000 Base-TX PCI-X Adapter (14108902)
Hardware Address: 00:14:5e:d1:51:e2

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 8580                                 Packets: 15877
Bytes: 957704                                 Bytes: 1167523
Interrupts: 0                                 Interrupts: 14903
Transmit Errors: 0                            Receive Errors: 0
Packets Dropped: 0                            Packets Dropped: 0
                                              Bad Packets: 0
Max Packets on S/W Transmit Queue: 28
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Broadcast Packets: 76                         Broadcast Packets: 2373
Multicast Packets: 19                         Multicast Packets: 8260
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 1
Adapter Data Rate: 200
Driver Flags: Up Broadcast Running
        Simplex Promiscuous 64BitSupport
        ChecksumOffload LargeSend DataRateSet

2-Port 10/100/1000 Base-TX PCI-X Adapter (14108902) Specific Statistics:
------------------------------------------------------------------------
Link Status : Up
Media Speed Selected: Auto negotiation
Media Speed Running: 100 Mbps Full Duplex
PCI Mode: PCI-X (100-133)
PCI Bus Width: 64-bit
Latency Timer: 144
Cache Line Size: 128
Jumbo Frames: Disabled
TCP Segmentation Offload: Enabled
TCP Segmentation Offload Packets Transmitted: 0
TCP Segmentation Offload Packet Errors: 0
Transmit and Receive Flow Control Status: Disabled
Transmit and Receive Flow Control Threshold (High): 49152
Transmit and Receive Flow Control Threshold (Low): 24576
Transmit and Receive Storage Allocation (TX/RX): 8/56

-------------------------------------------------------------
Backup adapter - ent2:
======================

ETHERNET STATISTICS (ent2) :
Device Type: 2-Port 10/100/1000 Base-TX PCI-X Adapter (14108902)
Hardware Address: 00:14:5e:d1:51:e2

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 27                                   Packets: 10924
Bytes: 1718                                   Bytes: 794112
Interrupts: 0                                 Interrupts: 10418
Transmit Errors: 0                            Receive Errors: 0
Packets Dropped: 0                            Packets Dropped: 0
                                              Bad Packets: 0
Max Packets on S/W Transmit Queue: 0
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Broadcast Packets: 27                         Broadcast Packets: 2417
Multicast Packets: 0                          Multicast Packets: 8277
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 1
Adapter Data Rate: 200
Driver Flags: Up Broadcast Running
        Simplex Promiscuous 64BitSupport
        ChecksumOffload LargeSend DataRateSet

2-Port 10/100/1000 Base-TX PCI-X Adapter (14108902) Specific Statistics:
------------------------------------------------------------------------
Link Status : Up
Media Speed Selected: Auto negotiation
Media Speed Running: 100 Mbps Full Duplex
PCI Mode: PCI-X (100-133)
PCI Bus Width: 64-bit
Latency Timer: 144
Cache Line Size: 128
Jumbo Frames: Disabled
TCP Segmentation Offload: Enabled
TCP Segmentation Offload Packets Transmitted: 0
TCP Segmentation Offload Packet Errors: 0
Transmit and Receive Flow Control Status: Disabled
Transmit and Receive Flow Control Threshold (High): 49152
Transmit and Receive Flow Control Threshold (Low): 24576
Transmit and Receive Storage Allocation (TX/RX): 8/56

--------------------------------------------------------------
Virtual Adapter: ent4

ETHERNET STATISTICS (ent4) :
Device Type: Virtual I/O Ethernet Adapter (l-lan)
Hardware Address: 02:d9:70:00:40:0b

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 10946                                Packets: 24
Bytes: 782010                                 Bytes: 1888
Interrupts: 0                                 Interrupts: 23
Transmit Errors: 40                           Receive Errors: 0
Packets Dropped: 40                           Packets Dropped: 0
                                              Bad Packets: 0

Max Packets on S/W Transmit Queue: 0
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Broadcast Packets: 2476                       Broadcast Packets: 8
Multicast Packets: 8238                       Multicast Packets: 16
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 0
Adapter Data Rate: 20000
Driver Flags: Up Broadcast Running
        Simplex Promiscuous AllMulticast
        64BitSupport ChecksumOffload DataRateSet

Virtual I/O Ethernet Adapter (l-lan) Specific Statistics:
---------------------------------------------------------
RQ Length: 4481
Trunk Adapter: True
  Priority: 1  Active: True
Filter MCast Mode: False
Filters: 255
  Enabled: 2  Queued: 0  Overflow: 0
LAN State: Operational

Hypervisor Send Failures: 232
  Receiver Failures: 232
  Send Errors: 0
Hypervisor Receive Failures: 0

Invalid VLAN ID Packets: 40

ILLAN Attributes: 0000000000003103 [0000000000003102]

Port VLAN ID:   833
VLAN Tag IDs:   831   830   835   834   832

Switch ID: ETHERNET00

Hypervisor Information
  Virtual Memory
    Total (KB)                 79
  I/O Memory
    VRM Minimum (KB)          100
    VRM Desired (KB)          100
    DMA Max Min (KB)          128

Transmit Information
  Transmit Buffers
    Buffer Size             65536
    Buffers                    32
    History
      No Buffers                0
  Virtual Memory
    Total (KB)               2048
  I/O Memory
    VRM Minimum (KB)         2176
    VRM Desired (KB)        16384
    DMA Max Min (KB)        16384

Receive Information
  Receive Buffers
    Buffer Type              Tiny    Small   Medium    Large     Huge
    Min Buffers               512      512      128       24       24
    Max Buffers              2048     2048      256       64       64
    Allocated                 512      512      128       24       24
    Registered                512      512      128       24       24
    History
      Max Allocated           512      512      128       24       24
      Lowest Registered       511      512      128       24       24
  Virtual Memory
    Minimum (KB)              256     1024     2048      768     1536
    Maximum (KB)             1024     4096     4096     2048     4096
  I/O Memory
    VRM Minimum (KB)         4096     4096     2560      864     1632
    VRM Desired (KB)        16384    16384     5120     2304     4352
    DMA Max Min (KB)        16384    16384     8192     4096     8192

I/O Memory Information
  Total VRM Minimum (KB)    15524
  Total VRM Desired (KB)    61028
  Total DMA Max Min (KB)    69760

--------------------------------------------------------------
Control Channel Adapter: ent5

ETHERNET STATISTICS (ent5) :
Device Type: Virtual I/O Ethernet Adapter (l-lan)
Hardware Address: 02:d9:70:00:40:13

Transmit Statistics:                          Receive Statistics:
--------------------                          -------------------
Packets: 7536                                 Packets: 11
Bytes: 2697888                                Bytes: 3938
Interrupts: 0                                 Interrupts: 10
Transmit Errors: 0                            Receive Errors: 0
Packets Dropped: 0                            Packets Dropped: 0
                                              Bad Packets: 0

Max Packets on S/W Transmit Queue: 0
S/W Transmit Queue Overflow: 0
Current S/W+H/W Transmit Queue Length: 0

Broadcast Packets: 7536                       Broadcast Packets: 11
Multicast Packets: 0                          Multicast Packets: 0
No Carrier Sense: 0                           CRC Errors: 0
DMA Underrun: 0                               DMA Overrun: 0
Lost CTS Errors: 0                            Alignment Errors: 0
Max Collision Errors: 0                       No Resource Errors: 0
Late Collision Errors: 0                      Receive Collision Errors: 0
Deferred: 0                                   Packet Too Short Errors: 0
SQE Test: 0                                   Packet Too Long Errors: 0
Timeout Errors: 0                             Packets Discarded by Adapter: 0
Single Collision Count: 0                     Receiver Start Count: 0
Multiple Collision Count: 0
Current HW Transmit Queue Length: 0

General Statistics:
-------------------
No mbuf Errors: 0
Adapter Reset Count: 0
Adapter Data Rate: 20000
Driver Flags: Up Broadcast Running
        Simplex 64BitSupport ChecksumOffload DataRateSet

Virtual I/O Ethernet Adapter (l-lan) Specific Statistics:
---------------------------------------------------------
RQ Length: 4481
Trunk Adapter: False
Filter MCast Mode: False
Filters: 255
  Enabled: 0  Queued: 0  Overflow: 0
LAN State: Operational

Hypervisor Send Failures: 0
  Receiver Failures: 0
  Send Errors: 0
Hypervisor Receive Failures: 0

Invalid VLAN ID Packets: 0

ILLAN Attributes: 0000000000003002 [0000000000003002]

Port VLAN ID:    99
VLAN Tag IDs:  None


Switch ID: ETHERNET00

Hypervisor Information
  Virtual Memory
    Total (KB)                 79
  I/O Memory
    VRM Minimum (KB)          100
    VRM Desired (KB)          100
    DMA Max Min (KB)          128

Transmit Information
  Transmit Buffers
    Buffer Size             65536
    Buffers                    32
    History
      No Buffers                0
  Virtual Memory
    Total (KB)               2048
  I/O Memory
    VRM Minimum (KB)         2176
    VRM Desired (KB)        16384
    DMA Max Min (KB)        16384

Receive Information
  Receive Buffers
    Buffer Type              Tiny    Small   Medium    Large     Huge
    Min Buffers               512      512      128       24       24
    Max Buffers              2048     2048      256       64       64
    Allocated                 512      512      128       24       24
    Registered                512      512      128       24       24
    History
      Max Allocated           512      512      128       24       24
      Lowest Registered       511      512      128       24       24
  Virtual Memory
    Minimum (KB)              256     1024     2048      768     1536
    Maximum (KB)             1024     4096     4096     2048     4096
  I/O Memory
    VRM Minimum (KB)         4096     4096     2560      864     1632
    VRM Desired (KB)        16384    16384     5120     2304     4352
    DMA Max Min (KB)        16384    16384     8192     4096     8192

I/O Memory Information
  Total VRM Minimum (KB)    15524
  Total VRM Desired (KB)    61028
  Total DMA Max Min (KB)    69760

Open in new window

0
Comment
Question by:sminfo
3 Comments
 
LVL 74

Expert Comment

by:käµfm³d 👽
ID: 39253028
Try:

entstat -d ent7 | grep "ETHERNET STATISTICS.*|Media Speed Running.*"

Open in new window

0
 
LVL 68

Accepted Solution

by:
woolmilkporc earned 500 total points
ID: 39253111
Hi,

entstat -d ent7 |grep -E "ETHERNET STATISTICS|Media Speed Running" | awk '{if ($0~/ETHERNET STATISTICS/) E=$0; gsub("^ *","",E); if($0~/Media Speed Running/) print E "\n" $0}'

Open in new window

0
 

Author Closing Comment

by:sminfo
ID: 39253155
@kaufmed:

Your command didn't output nothing.

@wmp.. it worked fine!... thanks
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

When you do backups in the Solaris Operating System, the file system must be inactive. Otherwise, the output may be inconsistent. A file system is inactive when it's unmounted or it's write-locked by the operating system. Although the fssnap utility…
Java performance on Solaris - Managing CPUs There are various resource controls in operating system which directly/indirectly influence the performance of application. one of the most important resource controls is "CPU".   In a multithreaded…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now