from grep manual in debian. Output a zero byte (the ASCII NUL character) instead of the character that normally follows a file name $grep -Z FACK * proc.c SNMP_MIB_ITEM(“TCPFACKReorder”, LINUX_MIB_TCPFACKREORDER), sysctl_net_ipv4.c .ctl_name = NET_TCP_FACK, tcp_input.c * Packet counting of FACK is based on in-order assumptions, therefore TCP tcp_input.c mib_idx = LINUX_MIB_TCPFACKREORDER; tcp_input.c * A”. Its …
Category Archives: Uncategorized
Enable FACK congestion avoidance
$cat /proc/sys/net/ipv4/tcp_fack 1 $ tcp_fack Enable FACK congestion avoidance and fast retransmission. The value is not used, if tcp_sack is not enabled. http://www.psc.edu/networking/ftp/papers/Fack.9608.ps grepping through the linux kernel source 2.6.32 proc.c:210: SNMP_MIB_ITEM(“TCPFACKReorder”, LINUX_MIB_TCPFACKREORDER), sysctl_net_ipv4.c:475: .procname = “tcp_fack”, tcp_input.c:847: * Packet counting of FACK is based on in-order assumptions, therefore TCP tcp_input.c:1029: * A”. Its FACK …
explicit congestion notification
$cat /proc/sys/net/ipv4/tcp_ecn 2 $ The tcp_ecn variable turns on Explicit Congestion Notification in TCP connections. This is used to automatically tell the host when there are congestions in a route to a specific host or a network. This can be used to throttle the transmitters to send packets in a slower rate over that specific …
grep –color
$cat textdomain.c #include #include main() { char *textd; textd=textdomain(“iam happy”); printf(“\n %s \n”,textd); } $grep –color=auto hello textdomain.c $grep –color=auto happy textdomain.c textd=textdomain(“iam happy”); $
grep options and fgrep
$grep -V GNU grep 2.6.3 Copyright (C) 2009 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. $ GREP -F or fgrep $grep -F H hello.txt Hello $grep -F helloKello …
grep -n ,-v , -c, -i
$grep -n root /etc/passwd 1:root:x:0:0:root:/root:/bin/bash $ $cat hello.txt hello world $grep -v hello hello.txt world $ $cat hello.txt hello world helloo $grep -c hello hello.txt 2 $grep -c helloo hello.txt 1 $ $cat hello.txt hello world helloo Hello $grep hello hello.txt hello helloo $grep -i hello hello.txt hello helloo Hello $
grep ? (regex)
from grep info. GNU FDL `?’ The preceding item is optional and will be matched at most once. $cat bu.txt bugy buggy bugggy $ $grep -E bug\?y bu.txt bugy $grep -E bugg\?y bu.txt bugy buggy $grep -E buggg\?y bu.txt buggy bugggy $
grep * wildcard
to match repetitions of a character a star is used. $cat samsung id proof license copy check leaf 1 $grep *p* samsung $grep p* samsung id proof license copy check leaf 1 $grep p samsung id proof license copy $grep *p samsung $grep * samsung Binary file PCBSD8.0-x86-bootonly.iso matches $grep “*” samsung $grep “p*” samsung …
grep . wildcard
$cat samsung id proof license copy check leaf 1 $grep c.e samsung check leaf 1 $grep c.h samsung $
terminfo is a database of terminal capabilities
$cd /lib/terminfo/ $ls a c d E h l m p r s v w x $pwd /lib/terminfo $cd l/ $infocmp linux $infocmp linux # Reconstructed via infocmp from file: /lib/terminfo/l/linux linux|linux console, am, bce, ccc, eo, mir, msgr, xenl, xon, colors#8, it#8, ncv#18, pairs#64, Terminfo (formerly Termcap) is a database of terminal capabilities and …
Continue reading “terminfo is a database of terminal capabilities”