Guest_imported
New member
- Jan 1, 1970
- 0
Hi
I have a text file that looks like this
Link encap:Ethernet HWaddr 00:00:B4:44:E2:4B
inet addr:192.168.0.1 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::200:b4ff:fe44:e24b/10 Scope:Link
inet6 addr: fe80::b444:e24b/10 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:26336217 errors:0 dropped:166 overruns:0 frame:2554
TX packets:26793895 errors:0 dropped:0 overruns:0 carrier:0
collisions:70878 txqueuelen:100
RX bytes:981223126 (935.7 Mb) TX bytes:4191645335 (3997.4 Mb)
Interrupt:10 Base address:0x260
What is the diffrent between RX bytes and TX bytes ??
The next question is how to grep 2 values in the file
Line 9 looks like this
RX bytes:981223126 (935.7 Mb) TX bytes:4191645335 (3997.4 Mb)
How can I grep the RX bytes value 981223126, (yes it will be diffrent each time) and I also want to grep the TX bytes value 4191645335
It's just the long value I want to grep, not the (xxxx) value.
Thanks
//Fredrik
I have a text file that looks like this
Link encap:Ethernet HWaddr 00:00:B4:44:E2:4B
inet addr:192.168.0.1 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::200:b4ff:fe44:e24b/10 Scope:Link
inet6 addr: fe80::b444:e24b/10 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:26336217 errors:0 dropped:166 overruns:0 frame:2554
TX packets:26793895 errors:0 dropped:0 overruns:0 carrier:0
collisions:70878 txqueuelen:100
RX bytes:981223126 (935.7 Mb) TX bytes:4191645335 (3997.4 Mb)
Interrupt:10 Base address:0x260
What is the diffrent between RX bytes and TX bytes ??
The next question is how to grep 2 values in the file
Line 9 looks like this
RX bytes:981223126 (935.7 Mb) TX bytes:4191645335 (3997.4 Mb)
How can I grep the RX bytes value 981223126, (yes it will be diffrent each time) and I also want to grep the TX bytes value 4191645335
It's just the long value I want to grep, not the (xxxx) value.
Thanks
//Fredrik