komut satırı araçlarını kullanarak, metin "HTTP" ayıklamak gerekir (veya protokol ne olursa olsun,) doğru anahtar kelime "Tespit protokol" den sonra,:Linux'ta belirli bir satır ve bir dosya sütunu nasıl çıkartılır?
Kısmi dosya içeriği:
Detected protocol:
HTTP 1254
Komple dosya içeriği:
nDPI Memory statistics:
nDPI Memory (once): 103.29 KB
Flow Memory (per flow): 1.91 KB
Actual Memory: 1.76 MB
Peak Memory: 1.76 MB
Traffic statistics:
Ethernet bytes: 1342 (includes ethernet CRC/IFC/trailer)
Discarded bytes: 0
IP packets: 10 of 10 packets total
IP bytes: 1102 (avg pkt size 110 bytes)
Detected protocols:
HTTP packets: 10 bytes: 1102 flows: 1
Protocol statistics:
Acceptable 1102 bytes
ben ediyorum çok satırlı 'sed' kullanmayı önerin - bkz. [here] (http://superuser.com/a/634848/438726) veya daha fazla kontrole ihtiyacınız varsa,' awk '. – urban
Az önce verdiğiniz bu örnek girdinin beklenen çıktısı ne olurdu? Daha iyi bir deneyime sahip olmak için [sor] 'u okumayı deneyin. – fedorqui