Skip to main content

Posts

Network delay simulation

"tc" and "iptable" both can be used for network control. "iptable" is dangerous as one can accidently block ssh port. "tc" provide extra level of customization for traffic control. 1) for adding delay: tc qdisc add dev eth0 root netem delay 100ms   if "tc" command not found, then you can install it:   yum -y install tc   Note:name of device "eth0" can be found running "ifconfig" command The name eth0 can differ in various system.   for checking if delay is introduced or not, run: tc -s qdisc   for removing all "tc" rules, run this command: tc qdisc del dev eth0 root netem  and again verfiy : tc -s qdisc     2) for adding delay in statistically distributed fashion: tc qdisc add dev eth0 root netem delay 150ms 50ms distribution normal note: if it gives error "RTNETLINK answers: File exists" then run:  tc qdisc change dev eth0 r...
Recent posts

Retirement Pension calculation

Calculation of how much you need  to save for pension  is not magic. It can be expressed by a simple equation like this: Assuming 4% inflation* and your current monthly expenditure is 1 lakh. for calculating life expetency you can refer: https://twitter.com/srikundansingh/status/1147423727753187328 This is table for monthly saving you need: Current Age Retirement Age life expectancy Interest rate % Monthly saving needed 30 40 80 6 612216 30 40 80 8 443951 30 40 80 10 333052 30 40 80 12 255669 30 40 90 6 962869 30 40 90 8 690015 30 40 90 10 513540 30 40 90 12 391969 30 40 100 6 1487250 30 40 100 8 1056611 30 40 100 10 781885 30 40 100 12 594362 30 40 110 6 2272055 30 40 110 8 1603538 30 40 110 10 1181492 30 40 110 12 895401 30 45 80 6 331079 30 45 80 8 226990 30 45 80 10 160033 30 45 80 12 114896 30 45 90 6 527922 30 45 90 8 356871 30 45 90 10 249194 30 45 90 12 177667 30 45 100 6 821839 30 45 100 8 549996 30 45 100 10 38...